public void Execute() { Mario.marioCanTransition = false; Mario.marioCanTransitionLeftPipe = false; if (Mario is StarMario) { Koopa.KillKoopa(); Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.LowRumble, Game.RumbleHelper.LowRumble, Game.RumbleHelper.QuickRumble); } else { if (Koopa.Health == KoopaStateMachine.KoopaHealth.Shelled) { if (!Koopa.Physics.IsMovingX()) { MarioSoundBoard.Instance.PlayMarioKick(); Koopa.Physics.XVelocity = Koopa.Physics.XMinVelocity; Vector2 loc = Koopa.Location; loc.X -= Side.Collision.Width; Koopa.SetPosition(loc); Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.LowRumble, Game.RumbleHelper.LowRumble, Game.RumbleHelper.QuickRumble); } else { Mario.TakeDamage(); Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.MidRumble, Game.RumbleHelper.MidRumble, Game.RumbleHelper.ShortRumble); } } else { Mario.TakeDamage(); Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.MidRumble, Game.RumbleHelper.MidRumble, Game.RumbleHelper.ShortRumble); } } }
public void Execute() { Mario.marioCanTransition = false; Mario.marioCanTransitionLeftPipe = false; if (Mario is StarMario) { Koopa.KillKoopa(); } else { if (!Koopa.Physics.IsMovingX() && Koopa.Health == KoopaStateMachine.KoopaHealth.Shelled) { MarioSoundBoard.Instance.PlayMarioKick(); Koopa.Physics.XVelocity = Koopa.Physics.XMinVelocity; } else { Koopa.BeShelled(); MarioSoundBoard.Instance.PlayMarioStomp(); } Mario.SetPosition(new Vector2(Mario.Location.X, Mario.Location.Y - Side.Collision.Height)); Mario.Physics.YVelocity = PhysicsUtilites.PlayerBumpVelocityY; } Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.LowRumble, Game.RumbleHelper.LowRumble, Game.RumbleHelper.QuickRumble); Game.st.KoopaStomp(); ScoreAssignments sa = new ScoreAssignments(); Game.UI.DisplayScore(sa.KoopaStomp, Koopa.Location); }
public void Execute() { if (block.State.BumpingBlock) { koopa.KillKoopa(); Game.st.KoopaStomp(); ScoreAssignments sa = new ScoreAssignments(); Game.UI.DisplayScore(sa.KoopaStomp, koopa.Location); return; } koopa.Physics.YVelocity = 0; MoveKoopa(); }
public void Execute() { if (side.TopOrLeft is Fireball) { Fireball fb = (Fireball)side.TopOrLeft; fb.collisionEnemy = true; koopa.KillKoopa(); Game.st.KoopaFire(); ScoreAssignments sa = new ScoreAssignments(); Game.UI.DisplayScore(sa.KoopaFire, koopa.Location); } else if (side.BottomOrRight is Fireball) { Fireball fb = (Fireball)side.BottomOrRight; fb.collisionEnemy = true; koopa.KillKoopa(); Game.st.KoopaFire(); ScoreAssignments sa = new ScoreAssignments(); Game.UI.DisplayScore(sa.KoopaFire, koopa.Location); } koopa.Physics.YVelocity = 0; Movekoopa(); }
public void Execute() { Mario.marioCanTransition = false; Mario.marioCanTransitionLeftPipe = false; if (Mario is StarMario) { koopa.KillKoopa(); Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.LowRumble, Game.RumbleHelper.LowRumble, Game.RumbleHelper.QuickRumble); } else { Mario.TakeDamage(); Game.RumbleHelper.Rumble(PlayerIndex.One, Game.RumbleHelper.MidRumble, Game.RumbleHelper.MidRumble, Game.RumbleHelper.ShortRumble); } }
private bool checkForDeadKoopa() { if (deadlyShell(koopaOne) && !deadlyShell(koopaTwo)) { koopaTwo.KillKoopa(); Game.st.KoopaStomp(); ScoreAssignments sa = new ScoreAssignments(); Game.UI.DisplayScore(sa.KoopaStomp, koopaTwo.Location); return(true); } else if (deadlyShell(koopaTwo) && !deadlyShell(koopaOne)) { koopaOne.KillKoopa(); Game.st.KoopaStomp(); ScoreAssignments sa = new ScoreAssignments(); Game.UI.DisplayScore(sa.KoopaStomp, koopaOne.Location); return(true); } return(false); }