mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-06-13 13:04:03 +00:00
Storage also records colors for analysis
This commit is contained in:
parent
26f7ccbe41
commit
fc0fd2eb49
@ -70,12 +70,9 @@ export class ProductionAnalytics extends BasicSerializableObject {
|
||||
* @param {number} count
|
||||
*/
|
||||
onItemDeliveredToStorage(uid, item, count) {
|
||||
if (item.getItemType() === enumItemType.shape) {
|
||||
const definition = /** @type {ShapeItem} */ (item).definition;
|
||||
const key = uid + "," + definition.getHash();
|
||||
const entry = this.history[enumAnalyticsDataSource.deliveredToStorage];
|
||||
entry[entry.length - 1][key] = (entry[entry.length - 1][key] || 0) + count;
|
||||
}
|
||||
const key = uid + "," + item.serialize();
|
||||
const entry = this.history[enumAnalyticsDataSource.deliveredToStorage];
|
||||
entry[entry.length - 1][key] = (entry[entry.length - 1][key] || 0) + count;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user