Added gold count to the game

This commit is contained in:
Martin
2023-01-12 15:50:21 +01:00
parent b1153cd670
commit a8416732d7
4 changed files with 1124 additions and 642 deletions

View File

@@ -64,9 +64,8 @@ export class ItemManager extends Component {
if (!this.itemTypeToAction.has(item.ItemType)) throw new Error("Does not have behaviour set for " + item.ItemType);
this.pickupEffectManager.showEffect(item.node.worldPosition);
this.pickupEvent.trigger(item.ItemType);
this.itemTypeToAction.get(item.ItemType)();
this.pickupEvent.trigger(item.ItemType);
item.pickup();
}