mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-14 03:02:22 +01:00
quite a bit
llamas, fix some ltm specific stuff, add auto bus start for auto restart, work in progress lategame on 1.11, fix a crash, performance
This commit is contained in:
@@ -30,4 +30,15 @@ static inline void LoopMutators(std::function<void(AFortAthenaMutator*)> Callbac
|
||||
}
|
||||
|
||||
AllMutators.Free();
|
||||
}
|
||||
|
||||
template <typename MutatorType = AFortAthenaMutator>
|
||||
static inline MutatorType* FindFirstMutator(UClass* MutatorClass = MutatorType::StaticClass())
|
||||
{
|
||||
auto AllMutators = UGameplayStatics::GetAllActorsOfClass(GetWorld(), MutatorClass);
|
||||
auto FirstMutator = AllMutators.Num() >= 1 ? AllMutators.at(0) : nullptr;
|
||||
|
||||
AllMutators.Free();
|
||||
|
||||
return (MutatorType*)FirstMutator;
|
||||
}
|
||||
Reference in New Issue
Block a user