SPEC-6590 Implemented network entities instantiation by network spawnable asset ID

This commit is contained in:
pereslav
2021-05-05 00:00:06 +01:00
parent dfb262c572
commit e414cc151d
7 changed files with 121 additions and 63 deletions
@@ -60,6 +60,9 @@ namespace AzFramework
void Barrier(EntitySpawnTicket& spawnInfo, BarrierCallback completionCallback) override;
void AddOnSpawnedHandler(AZ::Event<AZ::Data::Asset<Spawnable>>::Handler& handler) override;
void AddOnDespawnedHandler(AZ::Event<AZ::Data::Asset<Spawnable>>::Handler& handler) override;
//
// The following function is thread safe but intended to be run from the main thread.
//
@@ -156,5 +159,8 @@ namespace AzFramework
AZStd::deque<Requests> m_delayedQueue; //!< Requests that were processed before, but couldn't be completed.
AZStd::queue<Requests> m_pendingRequestQueue;
AZStd::mutex m_pendingRequestQueueMutex;
AZ::Event<AZ::Data::Asset<Spawnable>> m_onSpawnedEvent;
AZ::Event<AZ::Data::Asset<Spawnable>> m_onDespawnedEvent;
};
} // namespace AzFramework