Fixed faster camera rotation
This commit is contained in:
parent
702fb312a7
commit
efc84f691c
|
@ -212,8 +212,8 @@ bool update()
|
||||||
case SDL_MOUSEMOTION:
|
case SDL_MOUSEMOTION:
|
||||||
{
|
{
|
||||||
if(!(event.motion.state & SDL_BUTTON_LMASK)) break;
|
if(!(event.motion.state & SDL_BUTTON_LMASK)) break;
|
||||||
camera_rotation.y += event.motion.xrel / 10.0f;
|
camera_rotation.y += event.motion.xrel / 5.0f;
|
||||||
camera_rotation.x += event.motion.yrel / 10.0f;
|
camera_rotation.x += event.motion.yrel / 5.0f;
|
||||||
|
|
||||||
if(camera_rotation.x > 90)
|
if(camera_rotation.x > 90)
|
||||||
camera_rotation.x = 90;
|
camera_rotation.x = 90;
|
||||||
|
|
Loading…
Reference in New Issue