Change platform RequestExit from Generic to Windows

This commit is contained in:
Louis Hobbs 2023-02-06 01:30:57 +00:00
parent 8e59d1a8b7
commit 5c18442131
1 changed files with 5 additions and 2 deletions

View File

@ -121,7 +121,7 @@ void APlayerCharacter::SetupPlayerInputComponent(UInputComponent* PlayerInputCom
if (QuitAction) if (QuitAction)
{ {
Input->BindAction(QuitAction, ETriggerEvent::Started, this, &APlayerCharacter::QuitCallback); Input->BindAction(QuitAction, ETriggerEvent::Completed, this, &APlayerCharacter::QuitCallback);
} }
if (SprintAction) if (SprintAction)
@ -198,7 +198,10 @@ void APlayerCharacter::EndFireCallback(const FInputActionInstance& Instance)
void APlayerCharacter::QuitCallback(const FInputActionInstance& Instance) void APlayerCharacter::QuitCallback(const FInputActionInstance& Instance)
{ {
FGenericPlatformMisc::RequestExit(true); // TODO: Add platform specific Exit requests
// This is not a bit deal for the moment as we are only building for windows
// For some reason the generic version does not work the same as FWindowsPlatformMisc
FWindowsPlatformMisc::RequestExit(false);
} }
void APlayerCharacter::SetSprintingCallback(const FInputActionInstance& Instance) void APlayerCharacter::SetSprintingCallback(const FInputActionInstance& Instance)