More progress on anim queue

This commit is contained in:
2023-09-15 01:08:19 -04:00
parent 1bdaf47b23
commit 40881ec284
3 changed files with 20 additions and 4 deletions

Binary file not shown.

View File

@@ -122,6 +122,19 @@ void AIntegrationGameModeBase::UpdateTangibles() {
UTangible* t = TangibleManager.GetTangible(tanid); UTangible* t = TangibleManager.GetTangible(tanid);
check(t != nullptr); check(t != nullptr);
t->AnimTracker.Update(aqueue); t->AnimTracker.Update(aqueue);
TArray<uint64> aborted = t->AnimTracker.GetAborted();
for (uint64 hash : aborted) {
ITangibleInterface::Execute_AbortAnimation(t->Actor, hash);
}
if (t->AnimTracker.AnyUnstarted()) {
FAnimStoredStep step = t->AnimTracker.GetUnstarted();
bool started = ITangibleInterface::Execute_StartAnimation(t->Actor, step.Hash, step.Body.size());
if (started) {
t->AnimTracker.Started(step.Hash);
}
}
} }
} }

View File

@@ -22,6 +22,9 @@ class INTEGRATION_API ITangibleInterface
// Add interface functions to this class. This is the class that will be inherited to implement this interface. // Add interface functions to this class. This is the class that will be inherited to implement this interface.
public: public:
UFUNCTION(BlueprintCallable, BlueprintImplementableEvent, Category = "Tangible Functionality") UFUNCTION(BlueprintImplementableEvent, Category = "Tangible Functionality")
void TurnFromCXX(); bool AbortAnimation(int64 hash);
UFUNCTION(BlueprintImplementableEvent, Category = "Tangible Functionality")
bool StartAnimation(int64 hash, int StrLen);
}; };