Add Saiki
authorMegaBrutal <code+git@megabrutal.com>
Thu, 13 Sep 2018 21:55:00 +0000 (23:55 +0200)
committerMegaBrutal <code+git@megabrutal.com>
Thu, 13 Sep 2018 21:55:00 +0000 (23:55 +0200)
modified:   tilemap.json
modified:   tilemap.tmx
modified:   wgj58.js

tilemap.json
tilemap.tmx
wgj58.js

index a8f175532f6b23ce8c070ab18c38d98d48818f7c..445b630d8ebf2383fe42297070f135de07b21d32 100644 (file)
                  "width":64,
                  "x":1600,
                  "y":1728
+                }, 
+                {
+                 "gid":51,
+                 "height":64,
+                 "id":32,
+                 "name":"saiki",
+                 "rotation":0,
+                 "type":"spawnpoint",
+                 "visible":true,
+                 "width":64,
+                 "x":2336,
+                 "y":1408
                 }],
          "opacity":1,
          "type":"objectgroup",
          "x":0,
          "y":0
         }],
- "nextobjectid":32,
+ "nextobjectid":33,
  "orientation":"orthogonal",
  "renderorder":"right-down",
  "tiledversion":"1.1.6",
index be58aadbdd0a6e88e2495e9496d5712c13c73582..634f76d5826c71c160f8eb99fa796a386f0dfa23 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<map version="1.0" tiledversion="1.1.6" orientation="orthogonal" renderorder="right-down" width="45" height="40" tilewidth="64" tileheight="64" infinite="0" nextobjectid="32">
+<map version="1.0" tiledversion="1.1.6" orientation="orthogonal" renderorder="right-down" width="45" height="40" tilewidth="64" tileheight="64" infinite="0" nextobjectid="33">
  <tileset firstgid="1" name="tileset" tilewidth="64" tileheight="64" tilecount="50" columns="10">
   <image source="tileset.png" width="640" height="320"/>
  </tileset>
     <property name="longpanel" type="bool" value="true"/>
    </properties>
   </object>
+  <object id="32" name="saiki" type="spawnpoint" gid="51" x="2336" y="1408" width="64" height="64"/>
  </objectgroup>
 </map>
index 5b5929a73cb46963c3b51d5a10075663392fcb9f..2183a22bb06ca18cc155e25e6ecb4ad4d161494b 100644 (file)
--- a/wgj58.js
+++ b/wgj58.js
@@ -383,6 +383,13 @@ class NPC_Carlos extends GameNPC {
        }
 }
 
+class NPC_Saiki extends GameNPC {
+       actionTalk() {
+               super.actionTalk();
+               logic.endTalk();
+       }
+}
+
 
 class GameInterface extends Phaser.Group {
        constructor(game, parent) {
@@ -579,6 +586,10 @@ class GameLogic {
                                newChar = new NPC_Carlos(object.x, object.y, 'carlos', "Carlos", "Carlos Elbacalper", 150);
                                this.carlos = newChar;
                                break;
+                       case 'saiki':
+                               newChar = new NPC_Saiki(object.x, object.y, 'saiki', "Saiki", "Saiki Ytpme", 200);
+                               this.saiki = newChar;
+                               break;
                        default:
                                console.error("Unknown character:", object);
                }