summary refs log tree commit diff stats
path: root/randomizer/randomizer.gd
diff options
context:
space:
mode:
Diffstat (limited to 'randomizer/randomizer.gd')
-rw-r--r--randomizer/randomizer.gd26
1 files changed, 26 insertions, 0 deletions
diff --git a/randomizer/randomizer.gd b/randomizer/randomizer.gd new file mode 100644 index 0000000..ff558a3 --- /dev/null +++ b/randomizer/randomizer.gd
@@ -0,0 +1,26 @@
1extends Node
2
3const my_version = "0.1.0"
4
5var SCRIPT_generator
6
7var generator
8
9signal finished_randomizing
10signal randomizer_status
11
12
13func start(gen_seed = ""):
14 generator = SCRIPT_generator.new($GeneratedPuzzles)
15 generator.connect("generator_status", self, "statusUpdate")
16 generator.generate(gen_seed)
17
18 emit_signal("finished_randomizing")
19
20
21func statusUpdate(text):
22 emit_signal("randomizer_status", text)
23
24
25func getSaveFileName():
26 return "zzRN_%d" % generator.gen_seed