1 module monsterRobot is "monster" "Robot";
7 // setup actor animations
8 public void initializeAnim () {
10 animClearFrames("monster", "Robot", "sleep");
12 animAddFrame("monster", "Robot", "sleep", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/roboa2a1_mirrored.vga");
14 animAddFrame("monster", "Robot", "sleep", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/roboa2a1.vga");
16 animClearFrames("monster", "Robot", "go");
18 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/robod2d1_mirrored.vga");
19 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/robod2d1_mirrored.vga");
20 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboe2e1_mirrored.vga");
21 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboe2e1_mirrored.vga");
22 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robof2f1_mirrored.vga");
23 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robof2f1_mirrored.vga");
24 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robog2g1_mirrored.vga");
25 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robog2g1_mirrored.vga");
26 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboh2h1_mirrored.vga");
27 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboh2h1_mirrored.vga");
28 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboi2i1_mirrored.vga");
29 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboi2i1_mirrored.vga");
30 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboj2j1_mirrored.vga");
31 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboj2j1_mirrored.vga");
32 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robok2k1_mirrored.vga");
33 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robok2k1_mirrored.vga");
34 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robol2l1_mirrored.vga");
35 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robol2l1_mirrored.vga");
36 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/roboa2a1_mirrored.vga");
37 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/roboa2a1_mirrored.vga");
38 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robob2b1_mirrored.vga");
39 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/robob2b1_mirrored.vga");
40 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboc2c1_mirrored.vga");
41 animAddFrame("monster", "Robot", "go", ACTOR_DIR_LEFT, "monsters/robot/graphics/go/roboc2c1_mirrored.vga");
43 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/robod2d1.vga");
44 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/robod2d1.vga");
45 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboe2e1.vga");
46 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboe2e1.vga");
47 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robof2f1.vga");
48 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robof2f1.vga");
49 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robog2g1.vga");
50 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robog2g1.vga");
51 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboh2h1.vga");
52 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboh2h1.vga");
53 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboi2i1.vga");
54 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboi2i1.vga");
55 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboj2j1.vga");
56 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboj2j1.vga");
57 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robok2k1.vga");
58 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robok2k1.vga");
59 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robol2l1.vga");
60 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robol2l1.vga");
61 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/roboa2a1.vga");
62 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/roboa2a1.vga");
63 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robob2b1.vga");
64 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/robob2b1.vga");
65 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboc2c1.vga");
66 animAddFrame("monster", "Robot", "go", ACTOR_DIR_RIGHT, "monsters/robot/graphics/go/roboc2c1.vga");
68 animClearFrames("monster", "Robot", "pain");
70 animAddFrame("monster", "Robot", "pain", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/robod2d1_mirrored.vga");
72 animAddFrame("monster", "Robot", "pain", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/robod2d1.vga");
74 animClearFrames("monster", "Robot", "wait");
76 animAddFrame("monster", "Robot", "wait", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/robod2d1_mirrored.vga");
78 animAddFrame("monster", "Robot", "wait", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/robod2d1.vga");
80 animClearFrames("monster", "Robot", "attack");
82 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_LEFT, "monsters/robot/graphics/attack/roboo2o1_mirrored.vga");
83 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_LEFT, "monsters/robot/graphics/attack/roboo2o1_mirrored.vga");
84 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_LEFT, "monsters/robot/graphics/attack/robop2p1_mirrored.vga");
85 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_LEFT, "monsters/robot/graphics/attack/robop2p1_mirrored.vga");
86 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_LEFT, "monsters/robot/graphics/attack/roboq2q1_mirrored.vga");
87 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_LEFT, "monsters/robot/graphics/attack/roboq2q1_mirrored.vga");
89 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_RIGHT, "monsters/robot/graphics/attack/roboo2o1.vga");
90 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_RIGHT, "monsters/robot/graphics/attack/roboo2o1.vga");
91 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_RIGHT, "monsters/robot/graphics/attack/robop2p1.vga");
92 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_RIGHT, "monsters/robot/graphics/attack/robop2p1.vga");
93 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_RIGHT, "monsters/robot/graphics/attack/roboq2q1.vga");
94 animAddFrame("monster", "Robot", "attack", ACTOR_DIR_RIGHT, "monsters/robot/graphics/attack/roboq2q1.vga");
96 animClearFrames("monster", "Robot", "die");
98 animAddFrame("monster", "Robot", "die", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/robod2d1_mirrored.vga");
100 animAddFrame("monster", "Robot", "die", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/robod2d1.vga");
102 animClearFrames("monster", "Robot", "slop");
106 animClearFrames("monster", "Robot", "dead");
108 animAddFrame("monster", "Robot", "dead", ACTOR_DIR_LEFT, "monsters/robot/graphics/shared/robod2d1_mirrored.vga");
110 animAddFrame("monster", "Robot", "dead", ACTOR_DIR_RIGHT, "monsters/robot/graphics/shared/robod2d1.vga");
112 animClearFrames("monster", "Robot", "mess");
118 // change actor animation
119 public void setAnim (Actor me, string state) {
122 case "sleep": me.animname = "sleep"; me.animstr = "A"; break;
123 case "go": me.animname = "go"; me.animstr = "DDEEFFGGHHIIJJKKLLAABBCC"; break;
124 case "pain": me.animname = "pain"; me.animstr = "D"; break;
125 case "wait": me.animname = "wait"; me.animstr = "D"; break;
126 case "attack": me.animname = "attack"; me.animstr = "OOPPQQ"; break;
127 case "die": me.animname = "die"; me.animstr = "D"; break;
128 case "slop": me.animname = "slop"; me.animstr = ""; break;
129 case "dead": me.animname = "dead"; me.animstr = "D"; break;
130 case "mess": me.animname = "mess"; me.animstr = ""; break;
131 case "run": me.animname = "go"; me.animstr = "DDEEFFGGHHIIJJKKLLAABBCC"; break;
132 case "climb": me.animname = "go"; me.animstr = "DDEEFFGGHHIIJJKKLLAABBCC"; break;
133 case "runout": me.animname = "go"; me.animstr = "DDEEFFGGHHIIJJKKLLAABBCC"; break;
134 case "shoot": me.animname = "attack"; me.animstr = "OOPPQQ"; break;
135 case "revive": me.animname = "revive"; me.animstr = "D"; break;
136 default: me.animname = "sleep"; me.animstr = "A"; break;
138 me.actorSetAnimation(state);
142 // setup actor properties
143 public void initialize (Actor me) {
144 // `classname` and `classtype` will be set by the engine
145 //me.classname = "Robot";
146 //me.classtype = "monster";
149 me.hitpoints = me.life = 20;
161 public void think (Actor me) {