Reduce coupling in the unreal side

This commit is contained in:
2026-02-25 14:48:14 -05:00
parent 948de31f71
commit b149714f20
13 changed files with 161 additions and 162 deletions

View File

@@ -20,7 +20,6 @@ using namespace LpxCommonTypes;
ALuprexGameModeBase::ALuprexGameModeBase()
{
TangibleManager = nullptr;
AssetLookup = nullptr;
PlayerId = 0;
EngineSeconds = 0.0;
MustCallLookAtChanged = false;
@@ -71,11 +70,6 @@ void ALuprexGameModeBase::ResetToInitialState()
TangibleManager = nullptr;
}
if (AssetLookup != nullptr) {
AssetLookup->ConditionalBeginDestroy();
AssetLookup = nullptr;
}
// Stop the tick functions.
FWorldDelegates::OnWorldPreActorTick.Remove(OnWorldPreActorTickHandle);
FWorldDelegates::OnWorldPostActorTick.Remove(OnWorldPostActorTickHandle);
@@ -274,10 +268,6 @@ void ALuprexGameModeBase::InitializeGlobalState()
OnWorldPostActorTickHandle = FWorldDelegates::OnWorldPostActorTick.AddUObject(this, &ALuprexGameModeBase::OnWorldPostActorTick);
}
// Initialize the asset lookup table.
AssetLookup = NewObject<UlxAssetLookup>(this);
AssetLookup->RebuildIndex();
// Initialize the tangible manager.
TangibleManager = NewObject<UlxTangibleManager>(this);
TangibleManager->Init(this);