blob: d04deb82c79700abec875904153218d337e9c6fc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
class_name MapRoom
extends ColorRect
@export var inactive_color: Color
@export var active_color: Color
@onready var pi: TextureRect = $PlayerIcon;
func _ready():
unhighlight()
pi.position = get_rect().size / 2 - pi.get_rect().size / 2 - Vector2(0, 1.1)
func highlight():
color = active_color
$PlayerIcon.visible = true
func unhighlight():
color = inactive_color
$PlayerIcon.visible = false
|