public override void explode(List<Platform> plats,WizardWars game) { Platform p=Ground.get(); for (int i = 0; i < plats.Count; i++) { if (pos.X>plats[i].pos.X && pos.X+dim.X<plats[i].pos.X+plats[i].dim.X && plats[i].pos.Y < p.pos.Y) p = plats[i]; } Vector2 impactPt = new Vector2(getCenter().X, p.pos.Y - p.maxHeight((int)pos.X, (int)(pos.X + dim.X))); game.lightningDim = new Vector2(100, impactPt.Y); game.lightningPos = new Vector2(impactPt.X - game.lightningDim.X * .1818f, impactPt.Y - game.lightningDim.Y * .992f); game.drawLightning = true; p.dmg((int)pos.X - 10, (int)(pos.X + dim.X + 10), (int)power); for (int i = 0; i < game.players.Length; i++) if (!(game.players[i] is AirWizard)) game.players[i].Stun((power / Math.Max(StationarySprite.distance (impactPt,game.players[i].getCenter()),20)*800)); base.explode(plats,game); }
public virtual void explode(List<Platform> plats,WizardWars game) { die(); }
public virtual void explode(WizardWars game) { die(); }
public virtual void explode(WizardWars game,Platform p) { die(); }
public static void setGame(WizardWars g) { game = g; }
public override void explode(WizardWars game) { game.portals[game.earlierPortal()] = new PortalArea(DateTime.Now, getCenter(), new Vector2(power/5,power/5)); base.explode(game); }