forked from enlightenment/efl
examples/sphere_hunter: fix another instance of floating point incorrectness
I missed this one yesterday. Also change it to use floating point values instead of casting which does not make much sense for hard-coded values. CID: 1327343
This commit is contained in:
parent
d1fd0e34a4
commit
3a334ecd4d
|
@ -404,7 +404,7 @@ _key_down(void *data,
|
|||
if (camera_y > 26.5)
|
||||
{
|
||||
camera_y -= 0.5;
|
||||
camera_z -= 0.5 * (7 / 4);
|
||||
camera_z -= 0.5 * (7.0 / 4.0);
|
||||
}
|
||||
}
|
||||
if (!strcmp(ev->key, "Down"))
|
||||
|
@ -412,7 +412,7 @@ _key_down(void *data,
|
|||
if (camera_y < 100.0)
|
||||
{
|
||||
camera_y += 0.5;
|
||||
camera_z += 0.5 * (7 / (double)4);
|
||||
camera_z += 0.5 * (7.0 / 4.0);
|
||||
}
|
||||
}
|
||||
if (!strcmp(ev->key, "n"))
|
||||
|
|
Loading…
Reference in New Issue