diff options
Diffstat (limited to 'client/player')
| -rw-r--r-- | client/player/character/character.gd | 4 | ||||
| -rw-r--r-- | client/player/player.gd | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/client/player/character/character.gd b/client/player/character/character.gd index cd41e7ff..82e5c849 100644 --- a/client/player/character/character.gd +++ b/client/player/character/character.gd @@ -44,7 +44,7 @@ var current_animation := "idle" const NUM_COLORS = 5; const NUM_HAIRS = 3; @onready var hairstyles := [$Main/HeadDefault/Hair, $Main/HeadDefault/Hair2, $Main/HeadDefault/Hair3] -var colors = [ +const COLORS: Array[Color] = [ Color(0.204, 0.361, 0.624), Color(0.568, 0.256, 0.602), Color(0.575, 0.341, 0.117), @@ -111,7 +111,7 @@ func set_style(id: int): head_default.visible = not p.robot for h in hairstyles: h.hide() hairstyles[p.hair].show() - $Main.get_active_material(0).albedo_color = Color(0.349, 0.349, 0.349) if p.robot else colors[p.color] + $Main.get_active_material(0).albedo_color = Color(0.349, 0.349, 0.349) if p.robot else COLORS[p.color] func play_animation(name_: String): current_animation = name_ diff --git a/client/player/player.gd b/client/player/player.gd index 2c8cabf3..1ca7a37f 100644 --- a/client/player/player.gd +++ b/client/player/player.gd @@ -157,9 +157,9 @@ func item_message(item_name: String, timeout_initial: float, timeout_remaining: clear_timer.start(timeout_remaining) current_item_message = item_name -func text_message(m: String, _timeout_initial: float, timeout_remaining: float): - chat_bubble.set_text(m) - clear_timer.start(timeout_remaining) +func text_message(message: Game.TextMessage): + chat_bubble.set_text(message.text) + clear_timer.start(message.timeout_remaining) func effect_message(effect_name: String): effect.set_effect(effect_name) |