mirror of
https://github.com/sinbad/StevesUEHelpers.git
synced 2025-02-23 17:45:23 +00:00
Safety checks over PlayerController on shutdown in MenuStack
This commit is contained in:
parent
793e56051d
commit
0baefab436
@ -68,7 +68,11 @@ void UMenuStack::SavePreviousInputMousePauseState()
|
|||||||
|
|
||||||
void UMenuStack::ApplyInputModeChange(EInputModeChange Change) const
|
void UMenuStack::ApplyInputModeChange(EInputModeChange Change) const
|
||||||
{
|
{
|
||||||
auto PC = GetOwningPlayer();
|
auto PC = GetOwningPlayer();
|
||||||
|
|
||||||
|
if (!PC) // possible during shutdown
|
||||||
|
return;
|
||||||
|
|
||||||
switch (Change)
|
switch (Change)
|
||||||
{
|
{
|
||||||
case EInputModeChange::DoNotChange:
|
case EInputModeChange::DoNotChange:
|
||||||
@ -91,6 +95,10 @@ void UMenuStack::ApplyInputModeChange(EInputModeChange Change) const
|
|||||||
void UMenuStack::ApplyMousePointerVisibility(EMousePointerVisibilityChange Change) const
|
void UMenuStack::ApplyMousePointerVisibility(EMousePointerVisibilityChange Change) const
|
||||||
{
|
{
|
||||||
auto PC = GetOwningPlayer();
|
auto PC = GetOwningPlayer();
|
||||||
|
|
||||||
|
if (!PC) // possible during shutdown
|
||||||
|
return;
|
||||||
|
|
||||||
switch (Change)
|
switch (Change)
|
||||||
{
|
{
|
||||||
case EMousePointerVisibilityChange::DoNotChange:
|
case EMousePointerVisibilityChange::DoNotChange:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user