Added basic build menu and placement
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
class_name CellData
|
||||
extends Resource
|
||||
|
||||
const BUILD = preload("res://data/interactions/build.tres")
|
||||
const GATHER = preload("res://data/interactions/gather.tres")
|
||||
const BUILD = preload("res://data/interactions/build/build.tres")
|
||||
const GATHER = preload("res://data/interactions/gather/gather.tres")
|
||||
|
||||
@export var layer_info: Dictionary = {
|
||||
Constants.TilemapLayers.CORRUPTION: false
|
||||
@@ -40,6 +40,12 @@ func is_corrupted() -> bool:
|
||||
func has_layer(layer: int) -> bool:
|
||||
return layer_info.has(layer)
|
||||
|
||||
func is_interactable() -> bool:
|
||||
return has_resource() or has_building()
|
||||
|
||||
func is_buildable() -> bool:
|
||||
return not has_resource() or not has_building()
|
||||
|
||||
func get_interaction_options() -> Array[Interaction]:
|
||||
var interactions: Array[Interaction] = []
|
||||
if has_resource():
|
||||
|
||||
Reference in New Issue
Block a user