//keeping this since the side doesn't matter public void CollideWithItem(ICollidable collidable) { Debug.WriteLine("mario is colliding with an item"); OnItemCollected((ItemModel)collidable); if (collidable is FireFlowerModel) { CurrentPowerupState.FireTransition(null); this.points += 1000; } else if (collidable is RedMushroomModel) { if (CurrentPowerupState is MarioStandardState) { CurrentPowerupState.SuperTransition(null); } this.points += 1000; } else if (collidable is GreenMushroomModel) { this.points += 1000; LifeOneUP(); } else if (collidable is SuperStarModel) { this.points += 1000; //Mario gets invincibility for a bit } else if (collidable is CoinModel) { CollectCoin(); } }
public void Fire() { //this.powerupState = FireState.Instance; CurrentPowerupState.FireTransition(null); }