mirror of
https://github.com/Ed94/Cog.git
synced 2026-08-07 08:08:48 +00:00
fix crash at launch
This commit is contained in:
@@ -58,6 +58,12 @@ void UCogEngineWindow_Selection::PostInitProperties()
|
|||||||
//--------------------------------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------------------------------
|
||||||
void UCogEngineWindow_Selection::TryReapplySelection() const
|
void UCogEngineWindow_Selection::TryReapplySelection() const
|
||||||
{
|
{
|
||||||
|
UWorld* World = GetWorld();
|
||||||
|
if (World == nullptr)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (bReapplySelection == false)
|
if (bReapplySelection == false)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
@@ -75,7 +81,7 @@ void UCogEngineWindow_Selection::TryReapplySelection() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
TArray<AActor*> Actors;
|
TArray<AActor*> Actors;
|
||||||
for (TActorIterator<AActor> It(GetWorld(), SelectedClass); It; ++It)
|
for (TActorIterator<AActor> It(World, SelectedClass); It; ++It)
|
||||||
{
|
{
|
||||||
AActor* Actor = *It;
|
AActor* Actor = *It;
|
||||||
if (GetNameSafe(Actor) == SelectionName)
|
if (GetNameSafe(Actor) == SelectionName)
|
||||||
|
|||||||
Reference in New Issue
Block a user