<!--This Document is generated by GameMaker, if you edit it by hand then you do so at your own risk!-->
<object>
  <spriteName>sTesterCannonM</spriteName>
  <solid>0</solid>
  <visible>-1</visible>
  <depth>2</depth>
  <persistent>0</persistent>
  <parentName>&lt;undefined&gt;</parentName>
  <maskName>&lt;undefined&gt;</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>canbeX = 0;
image_speed = 0;
open = 0;
type = 0;
last_frame = 0;
frame_speed = 0;
damaged = 0;
pproj = -4;
starthealth = 15;
//myhealth = starthealth;
myhealth = global.mod_testerHcannon;
shaking = 0;
flashing = 0;
offx = 0;
offy = 0;
canbehit = 0;
</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 (type == 3) {
    if (!damaged &amp;&amp; open) {
        prj = instance_create(x, y, oTesterSpazerBeam);
        prj.direction = image_angle;
        prj.image_angle = image_angle;
        prj.speed = 4;
        if (global.difficulty == 1) {
            prj = instance_create(x, y, oTesterSpazerBeam);
            prj.direction = image_angle + 40;
            prj.image_angle = image_angle + 40;
            prj.speed = 4;
            prj = instance_create(x, y, oTesterSpazerBeam);
            prj.direction = image_angle - 40;
            prj.image_angle = image_angle - 40;
            prj.speed = 4;
        }
        if (global.difficulty &gt;= 2) {
            prj = instance_create(x, y, oTesterSpazerBeam);
            prj.direction = image_angle + 30;
            prj.image_angle = image_angle + 30;
            prj.speed = 5;
            prj = instance_create(x, y, oTesterSpazerBeam);
            prj.direction = image_angle - 30;
            prj.image_angle = image_angle - 30;
            prj.speed = 5;
            prj = instance_create(x, y, oTesterSpazerBeam);
            prj.direction = image_angle + 60;
            prj.image_angle = image_angle + 60;
            prj.speed = 5;
            prj = instance_create(x, y, oTesterSpazerBeam);
            prj.direction = image_angle - 60;
            prj.image_angle = image_angle - 60;
            prj.speed = 5;
        }
        with (oTester) alarm[0] = 1;
    } // if (!damaged &amp;&amp; open)
    if (open) {
        if (global.difficulty &lt; 2) {
            alarm[0] = 16;
        } else alarm[0] = 10;
    }
} // if (type == 3)
if (type == 2) {
    if (!damaged &amp;&amp; open) {
        prj = instance_create(x, y, oTesterWaveBeam);
        prj.direction = image_angle;
        prj.image_angle = image_angle;
        prj.speed = 6;
        if (x &lt; 160) {
            prj.hspeed -= 6;
        } else prj.hspeed += 6;
        with (oTester) alarm[0] = 1;
    }
    if (open) alarm[0] = 8;
}
</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>switch (type) {
    case 0: {
        sprite_index = sTesterCannonM;
        last_frame = 4;
        frame_speed = 0.5;
        break;
    }
    case 1: {
        sprite_index = sTesterCannonI;
        last_frame = 2;
        frame_speed = 0.2;
        break;
    }
    case 2: {
        sprite_index = sTesterCannonW;
        last_frame = 2;
        frame_speed = 0.2;
        break;
    }
    case 3: {
        sprite_index = sTesterCannonS;
        last_frame = 2;
        frame_speed = 0.2;
        break;
    }
    case 4: {
        sprite_index = sTesterCannonP;
        last_frame = 2;
        frame_speed = 0.2;
        break;
    }
} // switch (type)
if (open == 0) {
    if (image_index &gt; 0.001) image_index -= frame_speed; // should be fixed
} else if (image_index &lt; last_frame) image_index += frame_speed;
if (instance_exists(pproj)) {
    pproj.image_angle = image_angle;
    pproj.x = x;
    pproj.y = y;
}
if (shaking &gt; 0) {
    shaking -= 1;
    offx = random_range(-1, 1);
    offy = random_range(-1, 1);
} else {
    offx = 0;
    offy = 0;
}
if (flashing &gt; 0) flashing -= 1;
if (oTester.target_coff &gt; (oTester.coffmax - 10)) {
    canbehit = 1;
} else canbehit = 0;
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="4" ename="oBomb2">
      <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>with (other) event_user(0);
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="4" ename="oMissile">
      <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 (damaged == 0 &amp;&amp; canbehit) {
    with (other) event_user(0);
    myhealth -= 5 * (1 + other.smissile * 2);
    event_user(1);
}
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="4" ename="oBeam">
      <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 (damaged == 0 &amp;&amp; canbehit) {
    with (other) {
        event_user(0);
        if (!pbeam) instance_destroy();
    }
    myhealth -= 2;
    event_user(1);
}
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="4" ename="oPBombExpl">
      <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 (damaged == 0 &amp;&amp; canbehit &amp;&amp; !flashing) {
    myhealth -= 3;
    event_user(1);
}
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="4" ename="oBombExpl">
      <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 (damaged == 0 &amp;&amp; canbehit &amp;&amp; !flashing) {
    myhealth -= 1;
    event_user(1);
}
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="7" enumb="12">
      <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>//myhealth = starthealth;
myhealth = global.mod_testerHcannon;
damaged = 0;
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="7" enumb="11">
      <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 (damaged == 0) {
    shaking = 8;
    flashing = 5;
    repeat (2) instance_create(x, y, oDebris);
    if (myhealth &lt;= 0) {
        damaged = 1;
        if (instance_exists(pproj)) with (pproj) instance_destroy();
        make_explosion1big(x, y);
        repeat (5) spawn_rnd_pickup_at(x + random_range(-10, 10), y + random_range(-10, 10), 100);
        repeat (8) instance_create(x, y, oDebris);
        sfx_play(sndRobotExpl);
    }
    if (myhealth &gt; 75) image_index = 0;
    if (myhealth &lt;= 75) image_index = 1;
    if (myhealth &lt;= 50) image_index = 2;
    if (myhealth &lt;= 25) image_index = 3;
    sfx_stop(sndRobotHit2);
    sfx_play(sndRobotHit2);
}
</string>
          </argument>
        </arguments>
      </action>
    </event>
    <event eventtype="7" enumb="10">
      <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>var numproj;
if (!damaged) {
    if (type == 0) {
        prj = instance_create(x, y, oTesterMissile);
        prj.direction = image_angle;
        prj.image_angle = image_angle;
        prj.speed = 2;
        with (oTester) alarm[1] = 1;
    }
    if (type == 1) {
        if (global.difficulty == 0) numproj = 1;
        if (global.difficulty == 1) numproj = 3;
        if (global.difficulty &gt;= 2) numproj = 5;
        i = 0;
        repeat (numproj) {
            prj = instance_create(x, y, oTesterIceBeam);
            prj.direction = image_angle;
            prj.image_angle = image_angle;
            prj.speed = 1 + i;
            i += 1;
        }
        with (oTester) alarm[2] = 1;
    }
    if (type == 4) {
        pproj = instance_create(x, y, oTesterPlasmaBeam);
        pproj.image_angle = image_angle;
    }
    if (type == 3 || type == 2) alarm[0] = 1;
} // if (!damaged)
</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>if (damaged == 0) {
    draw_sprite_ext(sprite_index, -1, x + offx, y + offy, 1, 1, image_angle, -1, 1);
    if (flashing) {
        draw_set_blend_mode(bm_add);
        repeat (2) draw_sprite_ext(sprite_index, -1, x + offx, y + offy, 1, 1, image_angle, -1, flashing / 5);
        draw_set_blend_mode(bm_normal);
    }
} else if (type == 0) {
    draw_sprite_ext(sTesterCannonDestr, 0, x + offx, y + offy, 1, 1, image_angle, -1, 1);
} else draw_sprite_ext(sTesterCannonDestr, 1, x + offx, y + offy, 1, 1, image_angle, -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>
