LargeScreen/Modules/ButtonItem.gd

20 lines
330 B
GDScript3
Raw Normal View History

2024-12-17 18:21:12 +08:00
extends BaseControl
@export var TextureNormal:Texture2D
@export var TextureSelected:Texture2D
var is_select:bool=false:
set(value):
if value:
$TextureRect.texture=TextureSelected
else:
$TextureRect.texture=TextureNormal
is_select=value
func _ready() -> void:
super._ready()
self.focus_mode=Control.FOCUS_NONE