PR feedback addressing
This commit is contained in:
@@ -33,10 +33,10 @@ namespace Multiplayer
|
||||
AzNetworking::IConnection* GetConnection() const override;
|
||||
EntityReplicationManager& GetReplicationManager() override;
|
||||
void Update(AZ::TimeMs serverGameTimeMs) override;
|
||||
bool CanSendUpdates() const override;
|
||||
void SetCanSendUpdates(bool canSendUpdates) override;
|
||||
//! @}
|
||||
|
||||
bool CanSendUpdates();
|
||||
|
||||
private:
|
||||
EntityReplicationManager m_entityReplicationManager;
|
||||
AzNetworking::IConnection* m_connection = nullptr;
|
||||
|
||||
@@ -12,8 +12,13 @@
|
||||
|
||||
namespace Multiplayer
|
||||
{
|
||||
inline bool ClientToServerConnectionData::CanSendUpdates()
|
||||
inline bool ClientToServerConnectionData::CanSendUpdates() const
|
||||
{
|
||||
return m_canSendUpdates;
|
||||
}
|
||||
|
||||
inline void ClientToServerConnectionData::SetCanSendUpdates(bool canSendUpdates)
|
||||
{
|
||||
m_canSendUpdates = canSendUpdates;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -44,5 +44,13 @@ namespace Multiplayer
|
||||
//! Creates and manages sending updates to the remote endpoint.
|
||||
//! @param serverGameTimeMs current server game time in milliseconds
|
||||
virtual void Update(AZ::TimeMs serverGameTimeMs) = 0;
|
||||
|
||||
//! Returns whether update messages can be sent to the connection.
|
||||
//! @return true if update messages can be sent
|
||||
virtual bool CanSendUpdates() const = 0;
|
||||
|
||||
//! Sets the state of connection whether update messages can be sent or not.
|
||||
//! @param canSendUpdates the state value
|
||||
virtual void SetCanSendUpdates(bool canSendUpdates) = 0;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -34,11 +34,10 @@ namespace Multiplayer
|
||||
AzNetworking::IConnection* GetConnection() const override;
|
||||
EntityReplicationManager& GetReplicationManager() override;
|
||||
void Update(AZ::TimeMs serverGameTimeMs) override;
|
||||
bool CanSendUpdates() const override;
|
||||
void SetCanSendUpdates(bool canSendUpdates) override;
|
||||
//! @}
|
||||
|
||||
bool CanSendUpdates() const;
|
||||
void SetCanSendUpdates(bool canSendUpdates);
|
||||
|
||||
NetworkEntityHandle GetPrimaryPlayerEntity();
|
||||
const NetworkEntityHandle& GetPrimaryPlayerEntity() const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user