- Eliminate getincanglebam().

This commit is contained in:
Mitchell Richters 2022-08-27 23:18:09 +10:00 committed by Christoph Oelckers
parent c25493762b
commit dd55569915

View file

@ -6,14 +6,9 @@
#include "gamestruct.h" #include "gamestruct.h"
#include "packet.h" #include "packet.h"
inline constexpr binangle getincanglebam(binangle a, binangle na)
{
return na-a;
}
inline constexpr int getincangle(int a, int na) inline constexpr int getincangle(int a, int na)
{ {
return getincanglebam(buildang(a), buildang(na)).signedbuild(); return int(unsigned(na << 21) - unsigned(a << 21)) >> 21;
} }
struct PlayerHorizon struct PlayerHorizon