feat: Oier does not speak to Eneko at startup, now the game has no story and is very boring

fix: remember picked items to avoid appering in scene again
fix: counting potatoes
This commit is contained in:
2023-10-06 00:08:33 +02:00
parent a857d326ce
commit d1fc5995d4
16 changed files with 32 additions and 138 deletions

View File

@@ -5,19 +5,18 @@ class_name ESCItemCountManager
func add(global_id: String, value:= 1) -> void:
var item = get_item(global_id)
item.count = item.count + value
updateSprite(item)
set(global_id, item.count + value)
func remove(global_id: String, value:= 1) -> void:
var item = get_item(global_id)
item.count = item.count - value
updateSprite(item)
set(global_id, item.count - value)
func set(global_id: String, value: int) -> void:
var item = get_item(global_id)
item.count = value
escoria.globals_manager.set_global("count/%s" % global_id, value)
updateSprite(item)