mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-26 22:01:50 +00:00
Fix build, fix segfault.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1228 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
027032a304
commit
8a57ab9bc6
1 changed files with 8 additions and 4 deletions
|
@ -1290,6 +1290,7 @@ extern int mousecursor_x, mousecursor_y;
|
|||
void IN_Move (usercmd_t *cmd, int pnum)
|
||||
{
|
||||
float mx, my;
|
||||
float mouse_deltadist;
|
||||
|
||||
if (!mouse_avail)
|
||||
{
|
||||
|
@ -1347,10 +1348,13 @@ void IN_Move (usercmd_t *cmd, int pnum)
|
|||
cl.viewangles[pnum][PITCH] += m_pitch.value * mouse_y;
|
||||
CL_ClampPitch(pnum);
|
||||
} else {
|
||||
if ((in_strafe.state[pnum] & 1) && noclip_anglehack)
|
||||
cmd->upmove -= m_forward.value * mouse_y;
|
||||
else
|
||||
cmd->forwardmove -= m_forward.value * mouse_y;
|
||||
if (cmd)
|
||||
{
|
||||
if ((in_strafe.state[pnum] & 1) && noclip_anglehack)
|
||||
cmd->upmove -= m_forward.value * mouse_y;
|
||||
else
|
||||
cmd->forwardmove -= m_forward.value * mouse_y;
|
||||
}
|
||||
}
|
||||
mouse_x = mouse_y = 0.0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue