protected override void OnCollisionResponse(IProjectile projectile, CollisionSide side) { if (projectile is KoopaShellProjectile) { currentState = KoopaShellStates.Idle; } }
protected override void OnCollisionResponse(IPlayer player, CollisionSide side) { if (currentState != KoopaShellStates.Sliding) { if (side.Equals(CollisionSide.Right)) { isMovingRight = false; } else if (side.Equals(CollisionSide.Left)) { isMovingRight = true; } SoundEffectFactory.Instance.PlayKick(); CorrectPosition(side, player); } hitCount++; if (hitCount >= 1) { currentState = KoopaShellStates.Sliding; isKicked = true; } }
public override void DestroyShell() { currentState = KoopaShellStates.Gone; CurrentSprite = null; }