Made particles emit from resource
This commit is contained in:
@@ -29,7 +29,7 @@ func change_building(data: BuildingBase) -> void:
|
||||
layer_info[Constants.TilemapLayers.BUILDINGS] = data
|
||||
|
||||
func get_resource() -> GameResource:
|
||||
return layer_info[Constants.TilemapLayers.ENVIRONMENT] as GameResource
|
||||
return layer_info[Constants.TilemapLayerss.ENVIRONMENT] as GameResource
|
||||
|
||||
func has_resource() -> bool:
|
||||
return has_layer(Constants.TilemapLayers.ENVIRONMENT)
|
||||
|
||||
@@ -14,6 +14,7 @@ func _ready() -> void:
|
||||
|
||||
func _cleanup_gather() -> void:
|
||||
interaction_finished.emit()
|
||||
#TODO add the interaction for buildings
|
||||
var res: GameResource = Grid.get_location_data(grid_position).get_resource()
|
||||
ResourceManager.pickup(res)
|
||||
self.queue_free()
|
||||
|
||||
Reference in New Issue
Block a user