Send player FOV across the network as floatig point.
This commit is contained in:
parent
2a291165ee
commit
c885b6aa35
4 changed files with 10 additions and 10 deletions
|
|
@ -399,19 +399,19 @@ CUSTOM_CVAR (Int, dmflags, 0, CVAR_SERVERINFO)
|
|||
// If nofov is set, force everybody to the arbitrator's FOV.
|
||||
if ((self & DF_NO_FOV) && consoleplayer == Net_Arbitrator)
|
||||
{
|
||||
uint8_t fov;
|
||||
double fov;
|
||||
|
||||
Net_WriteByte (DEM_FOV);
|
||||
|
||||
// If the game is started with DF_NO_FOV set, the arbitrator's
|
||||
// DesiredFOV will not be set when this callback is run, so
|
||||
// be sure not to transmit a 0 FOV.
|
||||
fov = (uint8_t)players[consoleplayer].DesiredFOV;
|
||||
fov = players[consoleplayer].DesiredFOV;
|
||||
if (fov == 0)
|
||||
{
|
||||
fov = 90;
|
||||
}
|
||||
Net_WriteByte (fov);
|
||||
Net_WriteFloat (fov);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue