|
|
@ -50,13 +50,34 @@ bool UStateMachineSubsystem::ChangeState(const EGameState NewState)
|
|
|
|
switch(NewState)
|
|
|
|
switch(NewState)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
case EGameState::Battle:
|
|
|
|
case EGameState::Battle:
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("Entering BATTLE state from BATTLEMENU"))
|
|
|
|
UE_LOG(LogTemp, Display, TEXT("Entering BATTLE state from BATTLEMENU"))
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
default:
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("NewState is invalid from BATTLEMENU state: %hhd"), NewState)
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("NewState is invalid from BATTLEMENU state: %hhd"), NewState)
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case EGameState::GameOver:
|
|
|
|
|
|
|
|
switch(NewState)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
case EGameState::MainMenu:
|
|
|
|
|
|
|
|
UE_LOG(LogTemp, Display, TEXT("Entering MAINMENU state from GAMEOVER"))
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
default:
|
|
|
|
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("NewState is invalid from GAMEOVER: %hhd"), NewState)
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case EGameState::Victory:
|
|
|
|
|
|
|
|
switch(NewState)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
case EGameState::MainMenu:
|
|
|
|
|
|
|
|
UE_LOG(LogTemp, Display, TEXT("Entering MAINMENU state from VICTORY"))
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
default:
|
|
|
|
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("NewState is invalid from VICTORY: %hhd"), NewState)
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
}
|
|
|
|
default:
|
|
|
|
default:
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("Leaving unknown state, this is a problem"))
|
|
|
|
UE_LOG(LogTemp, Error, TEXT("Leaving unknown state, this is a problem"))
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|