summaryrefslogtreecommitdiff
path: root/UI
diff options
context:
space:
mode:
Diffstat (limited to 'UI')
-rw-r--r--UI/HUD/LevelMapCell.gd11
-rw-r--r--UI/LevelSelectCell.gd11
2 files changed, 4 insertions, 18 deletions
diff --git a/UI/HUD/LevelMapCell.gd b/UI/HUD/LevelMapCell.gd
index f66c8c3..d8790dd 100644
--- a/UI/HUD/LevelMapCell.gd
+++ b/UI/HUD/LevelMapCell.gd
@@ -7,16 +7,9 @@ var level_idx = 0
func _ready():
var level = Global.get_level(self.level_idx)
- $ClearMark.text = ""
- if level.cleared_by.idx == Enum.PLAYER.FIRST:
- $ClearMark.text = "X"
- elif level.cleared_by.idx == Enum.PLAYER.SECOND:
- $ClearMark.text = "O"
- elif level.cleared_by.idx == Enum.PLAYER.THIRD:
- $ClearMark.text = "P"
-
+ $ClearMark.text = level.cleared_by.player.symbol
$Time.text = str(level.time) + "s"
- $Name.text = level.cleared_by.name
+ $Name.text = level.cleared_by.player.name
func set_rect_size(x, y):
diff --git a/UI/LevelSelectCell.gd b/UI/LevelSelectCell.gd
index cd59593..63380f6 100644
--- a/UI/LevelSelectCell.gd
+++ b/UI/LevelSelectCell.gd
@@ -13,16 +13,9 @@ func _ready():
stylebox = self.get("theme_override_styles/panel")
- $ClearMark.text = ""
- if level.cleared_by.idx == Enum.PLAYER.FIRST:
- $ClearMark.text = "X"
- elif level.cleared_by.idx == Enum.PLAYER.SECOND:
- $ClearMark.text = "O"
- elif level.cleared_by.idx == Enum.PLAYER.THIRD:
- $ClearMark.text = "P"
-
+ $ClearMark.text = level.cleared_by.player.symbol
$Time.text = str(level.time) + "s"
- $Name.text = level.cleared_by.name
+ $Name.text = level.cleared_by.player.name
func set_rect_size(x, y):