Age | Commit message (Collapse) | Author |
|
Previous patches that removed shifts of constant negative values
to eliminate UB were valid, but did not correct all places where
this engine was potentially bit shifting negative values. There is
no reason to not just use multiplication and division and let the
compiler make the right choice for optimisation for an
architecture, so that is what this patch does.
|
|
|
|
The bug was caused by a check introduced by me to avoid division-by-zero errors
when the source and dest x values are equal.
This had the side effect that it didn't work well in this case outlined in the
bug report, maybe also in other places.
I'm not sure how to handle a DBZ correctly here so I'm setting the x delta to
1.0 if it would normally be 0.0, which seems to work after walking around
in some scenes.
|
|
|
|
|
|
This might not be obvious to a C++ developer, but we use C's sin which is
*always* double. Thus, sin will return a double and therefore some compilers
might warn about this conversion.
|
|
|
|
|
|
|