Skip to content

Commit

Permalink
Allow users to skip a scene, and reset savedata.json
Browse files Browse the repository at this point in the history
  • Loading branch information
DiddiLeija committed Mar 4, 2024
1 parent 75806b0 commit 0912b98
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion savedata.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"level": "one"
"level": "intro"
}
5 changes: 5 additions & 0 deletions src/scenes.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ def update(self):
self.next = "menu"
elif self.finished:
self.next = self.nextseq
if pyxel.btnp(pyxel.KEY_DELETE):
self.finished = True
self.next = self.nextseq
return
if pyxel.btnp(pyxel.KEY_SPACE):
self.sno += 1
if self.sno >= len(self.scenes):
Expand All @@ -66,6 +70,7 @@ def draw(self):
pyxel.rect(0, 80, 128, 50, self.boxcol1)
pyxel.rect(0, 79, 128, 1, self.boxcol2)
draw_text(st[2], 1, 81)
draw_text("DELETE: skip\nSPACE: continue", 1, 112)
draw_text(">>", 120, 120)


Expand Down

0 comments on commit 0912b98

Please sign in to comment.