You've already forked AM2R-Community-Updates
mirror of
https://github.com/izzy2lost/AM2R-Community-Updates.git
synced 2026-03-10 11:23:35 -07:00
175 lines
4.8 KiB
XML
175 lines
4.8 KiB
XML
<!--This Document is generated by GameMaker, if you edit it by hand then you do so at your own risk!-->
|
|
<object>
|
|
<spriteName>sA4RepairBot</spriteName>
|
|
<solid>0</solid>
|
|
<visible>-1</visible>
|
|
<depth>50</depth>
|
|
<persistent>0</persistent>
|
|
<parentName><undefined></parentName>
|
|
<maskName><undefined></maskName>
|
|
<events>
|
|
<event eventtype="0" enumb="0">
|
|
<action>
|
|
<libid>1</libid>
|
|
<id>603</id>
|
|
<kind>7</kind>
|
|
<userelative>0</userelative>
|
|
<isquestion>0</isquestion>
|
|
<useapplyto>-1</useapplyto>
|
|
<exetype>2</exetype>
|
|
<functionname></functionname>
|
|
<codestring></codestring>
|
|
<whoName>self</whoName>
|
|
<relative>0</relative>
|
|
<isnot>0</isnot>
|
|
<arguments>
|
|
<argument>
|
|
<kind>1</kind>
|
|
<string>if (global.event[200] == 0) instance_destroy();
|
|
state = 0;
|
|
statetime = 0;
|
|
targetx = x;
|
|
targety = y;
|
|
facing = 1;
|
|
idle_time = 60;
|
|
solder_time = 600;
|
|
</string>
|
|
</argument>
|
|
</arguments>
|
|
</action>
|
|
</event>
|
|
<event eventtype="2" enumb="0">
|
|
<action>
|
|
<libid>1</libid>
|
|
<id>603</id>
|
|
<kind>7</kind>
|
|
<userelative>0</userelative>
|
|
<isquestion>0</isquestion>
|
|
<useapplyto>-1</useapplyto>
|
|
<exetype>2</exetype>
|
|
<functionname></functionname>
|
|
<codestring></codestring>
|
|
<whoName>self</whoName>
|
|
<relative>0</relative>
|
|
<isnot>0</isnot>
|
|
<arguments>
|
|
<argument>
|
|
<kind>1</kind>
|
|
<string>if (state == 2) {
|
|
instance_create(x + 18 * facing, y + 9, oA4RepairBotSpark);
|
|
alarm[0] = 10;
|
|
}
|
|
</string>
|
|
</argument>
|
|
</arguments>
|
|
</action>
|
|
</event>
|
|
<event eventtype="3" enumb="0">
|
|
<action>
|
|
<libid>1</libid>
|
|
<id>603</id>
|
|
<kind>7</kind>
|
|
<userelative>0</userelative>
|
|
<isquestion>0</isquestion>
|
|
<useapplyto>-1</useapplyto>
|
|
<exetype>2</exetype>
|
|
<functionname></functionname>
|
|
<codestring></codestring>
|
|
<whoName>self</whoName>
|
|
<relative>0</relative>
|
|
<isnot>0</isnot>
|
|
<arguments>
|
|
<argument>
|
|
<kind>1</kind>
|
|
<string>if (state == 0) {
|
|
speed = 0;
|
|
gravity = 0;
|
|
image_index = 0;
|
|
image_speed = 0;
|
|
if (statetime == idle_time) {
|
|
state = 1;
|
|
statetime = 0;
|
|
}
|
|
}
|
|
if (state == 1) {
|
|
gravity_direction = point_direction(x + 20 * facing, y + 8, targetx, targety);
|
|
gravity = 0.1;
|
|
speed = min(speed, 3);
|
|
if (abs(hspeed > 0.1)) {
|
|
if (hspeed > 0) {
|
|
facing = 1;
|
|
} else facing = -1;
|
|
}
|
|
if (distance_to_point(targetx, targety) < 16) {
|
|
state = 2;
|
|
statetime = 0;
|
|
}
|
|
}
|
|
if (state == 2) {
|
|
if (statetime == 0) {
|
|
gravity = 0;
|
|
speed = 0;
|
|
}
|
|
if (image_index < 6) image_index += 0.25;
|
|
if (x + 20 * facing < targetx) x += 1;
|
|
if (x + 20 * facing > targetx) x -= 1;
|
|
if (y + 8 < targety) y += 1;
|
|
if (y + 8 > targety) y -= 1;
|
|
if (statetime == 30) alarm[0] = 1;
|
|
if (statetime == solder_time) {
|
|
state = 3;
|
|
statetime = 0;
|
|
}
|
|
}
|
|
if (state == 3) {
|
|
if (statetime == 0) {
|
|
gravity_direction = 90;
|
|
gravity = 0.1;
|
|
}
|
|
if (image_index > 0) image_index -= 0.5;
|
|
if (y < view_yview[0] - 32) instance_destroy();
|
|
}
|
|
statetime += 1;
|
|
</string>
|
|
</argument>
|
|
</arguments>
|
|
</action>
|
|
</event>
|
|
<event eventtype="8" enumb="0">
|
|
<action>
|
|
<libid>1</libid>
|
|
<id>603</id>
|
|
<kind>7</kind>
|
|
<userelative>0</userelative>
|
|
<isquestion>0</isquestion>
|
|
<useapplyto>-1</useapplyto>
|
|
<exetype>2</exetype>
|
|
<functionname></functionname>
|
|
<codestring></codestring>
|
|
<whoName>self</whoName>
|
|
<relative>0</relative>
|
|
<isnot>0</isnot>
|
|
<arguments>
|
|
<argument>
|
|
<kind>1</kind>
|
|
<string>draw_sprite_ext(sprite_index, -1, x, y, facing, 1, 0, -1, 1);
|
|
</string>
|
|
</argument>
|
|
</arguments>
|
|
</action>
|
|
</event>
|
|
</events>
|
|
<PhysicsObject>0</PhysicsObject>
|
|
<PhysicsObjectSensor>0</PhysicsObjectSensor>
|
|
<PhysicsObjectShape>0</PhysicsObjectShape>
|
|
<PhysicsObjectDensity>0.5</PhysicsObjectDensity>
|
|
<PhysicsObjectRestitution>0.100000001490116</PhysicsObjectRestitution>
|
|
<PhysicsObjectGroup>0</PhysicsObjectGroup>
|
|
<PhysicsObjectLinearDamping>0.100000001490116</PhysicsObjectLinearDamping>
|
|
<PhysicsObjectAngularDamping>0.100000001490116</PhysicsObjectAngularDamping>
|
|
<PhysicsObjectFriction>0.200000002980232</PhysicsObjectFriction>
|
|
<PhysicsObjectAwake>-1</PhysicsObjectAwake>
|
|
<PhysicsObjectKinematic>-1</PhysicsObjectKinematic>
|
|
<PhysicsShapePoints/>
|
|
</object>
|