Godot interaction system init
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
extends CanvasLayer
|
||||
class_name Crosshair
|
||||
|
||||
@export var normalTexture: Texture2D
|
||||
@export var hoverTexture: Texture2D
|
||||
|
||||
@onready var normal = $NormalCrosshair
|
||||
@onready var hover = $HoverCrosshair
|
||||
|
||||
func _ready():
|
||||
normal.texture = normalTexture
|
||||
hover.texture = hoverTexture
|
||||
hover.visible = false
|
||||
|
||||
func setHover(active: bool):
|
||||
normal.visible = !active
|
||||
hover.visible = active
|
||||
Reference in New Issue
Block a user