generated from Persson-dev/Godot-Xmake
network: send player velocity
This commit is contained in:
@@ -32,7 +32,7 @@ void ClientWorld::UpdatePlayerPos() {
|
||||
Player* player = GetPlayerById(get_multiplayer()->get_unique_id());
|
||||
if (player) {
|
||||
m_NetworkInterface->BroadcastPacket(protocol::packets::PlayerPositionAndRotation(
|
||||
{get_multiplayer()->get_unique_id(), player->get_position(), player->GetCameraRotation()}));
|
||||
{get_multiplayer()->get_unique_id(), player->get_position(), player->GetCameraRotation(), player->get_velocity()}));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user