summaryrefslogtreecommitdiff
path: root/UI/LevelSelectCell.gd
diff options
context:
space:
mode:
authorDaniel Weipert <code@drogueronin.de>2021-01-02 14:54:57 +0100
committerDaniel Weipert <code@drogueronin.de>2021-01-02 14:54:57 +0100
commitebae6d04ffc95c6648e863d3de71835f6cd4be96 (patch)
tree58ce9119a65ccd6925d661f12aab98a057dfb53d /UI/LevelSelectCell.gd
parentfb64f15e22acfc1c03c7c5357dd66077454adbcf (diff)
Initial working commit
Diffstat (limited to 'UI/LevelSelectCell.gd')
-rw-r--r--UI/LevelSelectCell.gd7
1 files changed, 4 insertions, 3 deletions
diff --git a/UI/LevelSelectCell.gd b/UI/LevelSelectCell.gd
index 1bd1366..16ff961 100644
--- a/UI/LevelSelectCell.gd
+++ b/UI/LevelSelectCell.gd
@@ -8,12 +8,13 @@ func _ready():
var level = Global.get_level(self.level_idx)
$ClearMark.text = ""
- if level.cleared_by == Enum.PLAYER.FIRST:
+ if level.cleared_by.idx == Enum.PLAYER.FIRST:
$ClearMark.text = "X"
- elif level.cleared_by == Enum.PLAYER.SECOND:
+ elif level.cleared_by.idx == Enum.PLAYER.SECOND:
$ClearMark.text = "O"
- $Time.text = String(level.time) + "s"
+ $Time.text = str(level.time) + "s"
+ $Name.text = level.cleared_by.name
func set_rect_size(x, y):