|
|
|
|
|
by ObnoxiousJul
5025 days ago
|
|
You really want to play with physics/math with ECMA 262? O_O (hint JS knows nothing of integers)
Floats are way to slow (and faulty when div/mul are called) compared to int to do anything serious.
All 3D engines tricks are about doing complex math with integers (EDIT: or other tricks http://en.wikipedia.org/wiki/Fast_inverse_square_root#Overvi...) |
|
Your assumptions about speed might be true for something like a Nintendo DS which doesn't have a floating point unit but a 3DS does, a vectorised one no less. Also in Javascript integers that can fit into 32 bits are actually integers nowadays.
All in all, I believe your information is outdated.