1
Fork 0
mirror of https://github.com/Steffo99/nanogolf.git synced 2024-11-21 23:54:21 +00:00
algodist-steffo-nanogolf/scenes/player_label.gd

8 lines
238 B
GDScript

extends Label
class_name PlayerLabel
func update_from_tracker(tracker: SinglePlayerTracker):
text = tracker.player_name
add_theme_color_override("font_color", tracker.player_color)
modulate.a = 1.0 if tracker.peer_connected else 0.3