Exemplo n.º 1
0
 public override void BecomeWalk(Facing orientation)
 {
     Context.Orientation       = orientation;
     Context.Velocity          = orientation == Facing.Left ? new Vector2(-BowserObject.BowserMovementSpeed, 0) : new Vector2(BowserObject.BowserMovementSpeed, 0);
     Context.ActionStateBowser = new BowserWalk(Context);
     Context.Sprite            = MovingEnemySpriteFactory.Create(EnemyType.BowserWalk);
 }
Exemplo n.º 2
0
 public override void BecomeAlive()
 {
     Context.PowerupState = new PiranhaReveal(Context);
     Context.IsDead       = false;
     Context.Sprite       = MovingEnemySpriteFactory.Create(EnemyType.Piranha);
     Context.BoundingBox  = null;
     Context.Gravity      = false;
 }
Exemplo n.º 3
0
 public BowserAlive(BowserObject context) : base(context)
 {
     if (Context.Orientation == Facing.Right)
     {
         Context.Velocity = new Vector2(1f, Context.Velocity.Y);
     }
     else if (Context.Orientation == Facing.Left)
     {
         Context.Velocity = new Vector2(-1f, Context.Velocity.Y);
     }
     Context.Sprite = MovingEnemySpriteFactory.Create(EnemyType.BowserIdle);
 }
Exemplo n.º 4
0
        public KoopaAlive(AbstractEnemy context) : base(context)
        {
            if (Context.Orientation == Facing.Right)
            {
                Context.Velocity = new Vector2(1f, Context.Velocity.Y);
            }
            else if (Context.Orientation == Facing.Left)
            {
                Context.Velocity = new Vector2(-1f, Context.Velocity.Y);
            }

            Context.Sprite = MovingEnemySpriteFactory.Create(EnemyType.GreenKoopa);
        }
Exemplo n.º 5
0
 public override void BreatheFire()
 {
     Context.ActionStateBowser = new BowserFireBreathing(Context);
     Context.Sprite            = MovingEnemySpriteFactory.Create(EnemyType.BowserFire);
     Context.BowserFireballPool.GetAndRelease(Context);
 }
Exemplo n.º 6
0
 public override void BecomeIdle()
 {
     Context.ActionStateBowser = new BowserIdle(Context);
     Context.Sprite            = MovingEnemySpriteFactory.Create(EnemyType.BowserIdle);
 }