home *** CD-ROM | disk | FTP | other *** search
- function step()
- {
- _X = _X + vx;
- _Y = _Y + vy;
- body._rotation += rate;
- if(boundaryTimer-- < 0)
- {
- boundaryTimer = 50;
- if(_X < xmin || _X > xmax || _Y < ymin || _Y > ymax)
- {
- destroy();
- }
- }
- _parent._parent.testHitDragon(this);
- }
- function takeDamage(amt, xp, yp)
- {
- _parent._parent.addScore(50,_X,_Y);
- var _loc2_ = _parent._parent.addObj("explosion_pow",_parent._parent.debris_layer,_parent._parent.getNextDebrisLevel());
- _loc2_._x = _X;
- _loc2_._y = _Y;
- _loc2_._rotation = random(360);
- _loc2_._xscale = _loc2_._yscale = _xscale * 1.5;
- destroy();
- }
- function destroy()
- {
- _parent._parent.removeEnemy(this);
- }
- m_type = "steel";
- rate = 11;
- xmax = _parent._parent.g_width + 50;
- xmin = -50;
- ymin = -50;
- ymax = _parent._parent.g_ground + 50;
- boundaryTimer = 50;
-