changeset 297:2844edb6c1cc

Hook up maneki, kaneda2 and the fishmonger who were hiding in limbo (i.e. not in game.json).
author Simon Cross <hodgestar@gmail.com>
date Fri, 08 Apr 2011 22:36:03 +0200
parents 15b2be883a40
children 95335c86b683
files data/game.json data/npcs/fishmonger.json data/npcs/kaneda2.json data/npcs/maneki.json skaapsteker/sprites/items.py skaapsteker/sprites/npcs.py
diffstat 6 files changed, 39 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/data/game.json	Fri Apr 08 22:29:49 2011 +0200
+++ b/data/game.json	Fri Apr 08 22:36:03 2011 +0200
@@ -16,6 +16,8 @@
         "masks_destroyed": false,
         "fire_started_on_road": false,
         "cannon_destroyed": false,
+        "all_fishmonger_demons_dead": false,
+        "kanedas_agreement_disrupted": false,
         "final_battle_lost": false,
         "final_battle_won": false
     },
@@ -24,15 +26,20 @@
         "teacup": { "type": "TeaCup", "level": "temple", "pos": [18, 10] },
         "teapot": { "type": "TeaPot", "level": "temple", "pos": [13, 2], "brewed": false },
         "teacupfull": { "type": "TeaCupFull", "level": "_limbo", "pos": [0, 0] },
-        "vase": { "type": "Vase", "level": "geisha_room", "pos": [1, 3], "broken": false }
+        "vase": { "type": "Vase", "level": "geisha_room", "pos": [1, 3], "broken": false },
+        "salmon": { "type": "Salmon", "level": "fishmonger_house", "pos": [1, 3] }
     },
     "npcs": {
         "monk": { "type": "Monk", "level": "temple", "pos": [15, 16], "dsm": "npcs/monk.json", "state": "start" },
         "guard": { "type": "Guard", "level": "temple_grounds", "pos": [10, 3], "dsm": "npcs/guard.json", "state": "start" },
         "hattori": { "type": "Hattori", "level": "road", "pos": [10, 3], "dsm": "npcs/hattori.json", "state": "start" },
         "ichiro": { "type": "Ichiro", "level": "road", "pos": [11, 3], "dsm": "npcs/ichiro.json", "state": "start" },
-        "kaneda": { "type": "Kaneda", "level": "tea_house", "pos": [10, 3], "dsm": "npcs/kaneda.json", "state": "start" },
+        "kaneda2": { "type": "Kaneda", "level": "tea_house", "pos": [10, 10], "dsm": "npcs/kaneda2.json", "state": "start" },
+        "tetsuo": { "type": "Tetsuo", "level": "tea_house", "pos": [11, 10], "dsm": "npcs/tetsuo.json", "state": "start" },
+        "kaneda": { "type": "Kaneda", "level": "geisha_house", "pos": [10, 3], "dsm": "npcs/kaneda.json", "state": "start" },
         "kumiko": { "type": "Kumiko", "level": "geisha_room", "pos": [11, 3], "dsm": "npcs/kumiko.json", "state": "start" },
+        "maneki": { "type": "Maneki", "level": "market", "pos": [10, 10], "dsm": "npcs/maneki.json", "state": "start" },
+        "fishmonger": { "type": "FishMonger", "level": "fishmonger_house", "pos": [10, 10], "dsm": "npcs/fishmonger.json", "state": "start" },
         "actor": { "type": "Actor", "level": "theatre", "pos": [8, 3], "dsm": "npcs/actor.json", "state": "start" },
         "sasuke": { "type": "Sasuke", "level": "road", "pos": [9, 3], "dsm": "npcs/sasuke.json", "state": "start" },
         "kitsune": { "type": "Kitsune", "level": "celestial_plane", "pos": [10, 3], "dsm": "npcs/kitsune.json", "state": "start" }
--- a/data/npcs/fishmonger.json	Fri Apr 08 22:29:49 2011 +0200
+++ b/data/npcs/fishmonger.json	Fri Apr 08 22:36:03 2011 +0200
@@ -1,7 +1,7 @@
 {
     "start" : {
         "events" : [
-            { "matches" : "world.all_fishmonger_demons_dead", "next": "state.saved" }
+            { "matches" : "world.missions.all_fishmonger_demons_dead", "next": "state.saved" }
         ]
     },
     "saved" : {
--- a/data/npcs/kaneda2.json	Fri Apr 08 22:29:49 2011 +0200
+++ b/data/npcs/kaneda2.json	Fri Apr 08 22:36:03 2011 +0200
@@ -17,7 +17,7 @@
     },
     "inspecting" : {
         "events" : [
-            { "matches" : "world.agreement_disrupted", "next": "state.preposterous" }
+            { "matches" : "world.missions.kanedas_agreement_disrupted", "next": "state.preposterous" }
         ]
     },
     "preposterous" : {
--- a/data/npcs/maneki.json	Fri Apr 08 22:29:49 2011 +0200
+++ b/data/npcs/maneki.json	Fri Apr 08 22:36:03 2011 +0200
@@ -1,10 +1,10 @@
 {
     "start" : {
         "text" : "Greetings, fox. Ah, but you are no ordinary fox, are you?",
-        "events" : [
-            { "matches" : "I am a kitsune.", "next": "state.thoughtasmuch" },
-            { "matches" : "I’m perfectly normal.", "next": "state.sure" },
-            { "matches" : "You’re not even a real cat!", "next": "state.unkind" }
+        "choices" : [
+            { "text" : "I am a kitsune.", "next": "state.thoughtasmuch" },
+            { "text" : "I’m perfectly normal.", "next": "state.sure" },
+            { "text" : "You’re not even a real cat!", "next": "state.unkind" }
         ]
     },
     "thoughtasmuch" : {
@@ -25,7 +25,7 @@
     },
     "waiting" : {
         "events" : [
-            { "matches" : "world.got_salmon", "next": "state.goodjob" }
+            { "matches" : "world.fox.item == 'salmon'", "next": "state.goodjob" }
         ]
     },
     "goodjob" : {
--- a/skaapsteker/sprites/items.py	Fri Apr 08 22:29:49 2011 +0200
+++ b/skaapsteker/sprites/items.py	Fri Apr 08 22:36:03 2011 +0200
@@ -42,3 +42,7 @@
     def setup(self, broken, **opts):
         super(Vase, self).setup(**opts)
         self.broken = broken
+
+
+class Salmon(Item):
+    image_file = 'dummy.png'
--- a/skaapsteker/sprites/npcs.py	Fri Apr 08 22:29:49 2011 +0200
+++ b/skaapsteker/sprites/npcs.py	Fri Apr 08 22:36:03 2011 +0200
@@ -24,16 +24,35 @@
     image_dir = 'sprites/kaneda'
 
 
+class Tetsuo(NPC):
+    image_dir = 'sprites/tetsuo'
+
+
 class Kumiko(NPC):
     image_dir = 'sprites/geisha'
 
 
+class FishMonger(NPC):
+    image_dir = 'sprites/fishmonger'
+    animation_regexes = [
+        ("standing", r"^.*_standing.png$"),
+    ]
+
+
+class Maneki(NPC):
+    image_dir = 'sprites/'
+    animation_regexes = [
+        ("manekiing", "dummy.png"),
+    ]
+
+
 class Actor(NPC):
     image_dir = 'sprites'
     animation_regexes = [
         ("noh", "dummy.png"),
     ]
 
+
 class Sasuke(NPC):
     image_dir = 'sprites/sasuke'