summaryrefslogtreecommitdiff
path: root/script.rpy
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2020-12-23 16:13:24 -0300
committerJesusaves <cpntb1@ymail.com>2020-12-23 16:13:24 -0300
commitc9eadeb54626ab92498616086b828c7f8d71d629 (patch)
treebe03a58991e124f27dac1adfe7301e5957550b85 /script.rpy
parente4dbacca7a444a7575776ab59eb13c531f01b5aa (diff)
downloadsdk-c9eadeb54626ab92498616086b828c7f8d71d629.tar.gz
sdk-c9eadeb54626ab92498616086b828c7f8d71d629.tar.bz2
sdk-c9eadeb54626ab92498616086b828c7f8d71d629.tar.xz
sdk-c9eadeb54626ab92498616086b828c7f8d71d629.zip
Save support
Diffstat (limited to 'script.rpy')
-rw-r--r--script.rpy21
1 files changed, 19 insertions, 2 deletions
diff --git a/script.rpy b/script.rpy
index 95339b4..c990dfb 100644
--- a/script.rpy
+++ b/script.rpy
@@ -5,9 +5,26 @@ label start:
scene black
centered "Click to load game data"
$ GAME_LOADER()
+
+label loop:
menu:
"Quest editor":
- call quest_editors
+ jump quest_editors
"Quit":
return
- return
+
+label restore:
+ menu:
+ "Save changes":
+ python:
+ f=open(get_path("editor.json"), "r")
+ alltquests["Main"]=json.load(f)
+ f.close()
+ f=open(get_path("quests.json"), "w")
+ json.dump(alltquests, f, indent=1, separators=(',', ': '))
+ f.close()
+ pass
+ "Discard changes":
+ pass
+ jump loop
+