Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#3 AI is ultra-stupid on amd64

open
nobody
None
5
2012-09-15
2004-09-24
Ari Pollak
No

The only bug that seems to happen only on an amd64
architecture is that bots refuse to turn. Conveniently,
this is due to the only long int in the program. The
following patch fixes this, since long on amd64 is
64-bit but int is still 32-bit.

--- gltron-0.70final.orig/src/include/game/game_data.h
+++ gltron-0.70final/src/include/game/game_data.h
@@ -71,7 +71,7 @@
typedef struct AI {
int active;
int tdiff;
- long lasttime;
+ unsigned int lasttime;
segment2 left, right, front, backleft;
} AI;

Discussion