checheche/Robo-Bus-A31-HMI/Modules/buttonItem.gd

13 lines
260 B
GDScript3
Raw Normal View History

2024-12-13 02:12:00 +08:00
extends BaseControl
@export var SelectTexture :Texture2D
@export var UnSelectTexture : Texture2D
var IsSelect = false:
set(value):
IsSelect = value
if IsSelect:
$TextureRect2.texture = SelectTexture
else:
$TextureRect2.texture = UnSelectTexture