Compare commits

...

3 Commits

Author SHA1 Message Date
Ishaan Bhardwaj
a972c31d9a
Merge pull request #73 from aur9ra/feat-show-invis-in-replay-option
show invis in replay
2023-07-15 01:59:07 -04:00
aur9ra
02f314997d Removed unnecessary change 2023-07-14 22:55:10 -07:00
aur9ra
4769daedf4 Added show invis support to replays. 2023-07-14 22:50:16 -07:00

View File

@ -37,6 +37,7 @@ function ReplayScene:new(replay, game_mode, ruleset)
self.replay = deepcopy(replay)
self.replay_index = 1
self.replay_speed = 1
self.show_invisible = false
DiscordRPC:update({
details = "Viewing a replay",
state = self.game.name,
@ -92,6 +93,12 @@ function ReplayScene:render()
else
love.graphics.printf("?? PAUSES (--:--.--)", 0, pauses_y_coordinate, 635, "right")
end
if self.show_invisible then
self.game.grid:draw()
love.graphics.setColor(1, 1, 1, 1)
love.graphics.setFont(font_3x5_3)
love.graphics.printf("SHOW INVIS", 64, 60, 160, "center")
end
end
function ReplayScene:onInputPress(e)
@ -124,6 +131,8 @@ function ReplayScene:onInputPress(e)
if self.replay_speed > 99 then
self.replay_speed = 99
end
elseif e.input == "hold" then
self.show_invisible = not self.show_invisible
end
end