Fix: tried to fix compiling errors in esc_item_with_tooltip.gd
This commit is contained in:
@@ -28,6 +28,11 @@ export(Array) var target_when_selected_action_is_in = []
|
||||
# If item is countable (E.g. money) marks the quantity
|
||||
export(int) var count = 0
|
||||
|
||||
# ESCItemComponents children of this node
|
||||
var components: Dictionary = {}
|
||||
|
||||
var custom_data: Dictionary = {}
|
||||
|
||||
# If item is countable (E.g. money) marks which texture to use depending of count value.
|
||||
# Each element is a Dictionary with start and texture keys:
|
||||
# [
|
||||
@@ -96,13 +101,13 @@ func _input(event):
|
||||
if(!active):
|
||||
highlight(false)
|
||||
|
||||
func has_component(key: String)->bool:
|
||||
return components.has(key)
|
||||
func has_component(key: String)->bool:
|
||||
return components.has(key)
|
||||
|
||||
func get_component(key: String):
|
||||
if(has_component(key)):
|
||||
return components[key]
|
||||
return null
|
||||
func get_component(key: String):
|
||||
if(has_component(key)):
|
||||
return components[key]
|
||||
return null
|
||||
|
||||
func register_components():
|
||||
for child in get_children():
|
||||
@@ -110,4 +115,3 @@ func register_components():
|
||||
child = child as ESCItemComponent
|
||||
components[child.get_component_type()] = child
|
||||
child.register(custom_data)
|
||||
|
||||
Reference in New Issue
Block a user