37 lines
1.0 KiB
C#
37 lines
1.0 KiB
C#
using BlueWater.Interfaces;
|
|
|
|
namespace BlueWater.Npcs.Customers
|
|
{
|
|
public class UpsetState : IStateMachine<Customer>
|
|
{
|
|
public void EnterState(Customer character)
|
|
{
|
|
if (character.CustomerSkin == CustomerSkin.Cat)
|
|
{
|
|
character.SpineController.PlayAnimation(CatSpineAnimation.Upset, true);
|
|
}
|
|
else if (character.CustomerSkin == CustomerSkin.Witch)
|
|
{
|
|
character.SpineController.PlayAnimation(WitchSpineAnimation.Upset, true);
|
|
}
|
|
else
|
|
{
|
|
character.SpineController.PlayAnimation(CustomerSpineAnimation.Upset, true);
|
|
}
|
|
}
|
|
|
|
public void UpdateState(Customer character)
|
|
{
|
|
if (character.IsMoving)
|
|
{
|
|
character.StateMachineController.TransitionToState(character.WalkingState, character);
|
|
}
|
|
}
|
|
|
|
public void ExitState(Customer character)
|
|
{
|
|
|
|
}
|
|
}
|
|
}
|