Merge remote-tracking branch 'origin/Turn-Based-Combat' into dev
This commit is contained in:
commit
ce78e1d53b
@ -42,17 +42,16 @@ void ATurnBaseCombatV2::StartCombat(AActor* Enemy)
|
|||||||
IronResource = 10;
|
IronResource = 10;
|
||||||
SulfurResource = 10;
|
SulfurResource = 10;
|
||||||
|
|
||||||
if (APlayerController* PC = Cast<APlayerController>(GetWorld()->GetFirstPlayerController()))
|
|
||||||
{
|
|
||||||
PC->bShowMouseCursor = true;
|
|
||||||
PC->bEnableClickEvents = true;
|
|
||||||
PC->bEnableMouseOverEvents = true;
|
|
||||||
}
|
|
||||||
//Disable Character Movement
|
//Disable Character Movement
|
||||||
if (ACharacter* PlayerCharacter = Cast<ACharacter>(GetWorld()->GetFirstPlayerController()->GetPawn()))
|
if (ACharacter* PlayerCharacter = Cast<ACharacter>(GetWorld()->GetFirstPlayerController()->GetPawn()))
|
||||||
{
|
{
|
||||||
PlayerCharacter->DisableInput(GetWorld()->GetFirstPlayerController());
|
PlayerCharacter->DisableInput(GetWorld()->GetFirstPlayerController());
|
||||||
}
|
}
|
||||||
|
//Set to UI Mode Only
|
||||||
|
APlayerController* PlayerController = GetWorld()->GetFirstPlayerController();
|
||||||
|
PlayerController->SetInputMode(FInputModeUIOnly());
|
||||||
|
PlayerController->bShowMouseCursor = true;
|
||||||
|
|
||||||
CurrentComboString = "";
|
CurrentComboString = "";
|
||||||
UpdateComboString(CurrentComboString);
|
UpdateComboString(CurrentComboString);
|
||||||
RevertActionPoints();
|
RevertActionPoints();
|
||||||
@ -73,17 +72,10 @@ void ATurnBaseCombatV2::EndCombat()
|
|||||||
{
|
{
|
||||||
PlayerCharacter->EnableInput(GetWorld()->GetFirstPlayerController());
|
PlayerCharacter->EnableInput(GetWorld()->GetFirstPlayerController());
|
||||||
}
|
}
|
||||||
if (APlayerController* PC = Cast<APlayerController>(GetWorld()->GetFirstPlayerController()))
|
//Set to Game Mode Only
|
||||||
{
|
APlayerController* PlayerController = GetWorld()->GetFirstPlayerController();
|
||||||
PC->bShowMouseCursor = false;
|
PlayerController->SetInputMode(FInputModeGameOnly());
|
||||||
PC->bEnableClickEvents = false;
|
PlayerController->bShowMouseCursor = false;
|
||||||
PC->bEnableMouseOverEvents = false;
|
|
||||||
}
|
|
||||||
GetWorld()->GetFirstPlayerController()->SetIgnoreLookInput(false);
|
|
||||||
GetWorld()->GetFirstPlayerController()->SetIgnoreMoveInput(false);
|
|
||||||
GetWorld()->GetFirstPlayerController()->bShowMouseCursor = false;
|
|
||||||
GetWorld()->GetFirstPlayerController()->bEnableClickEvents = false;
|
|
||||||
GetWorld()->GetFirstPlayerController()->bEnableMouseOverEvents = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ATurnBaseCombatV2::FKeyPressed()
|
void ATurnBaseCombatV2::FKeyPressed()
|
||||||
|
Loading…
Reference in New Issue
Block a user