Bug with factories is an endian bug. It happens when saving game. In defines I had to swap some values from char to int because chars were swapped when saving on big endian machines. Make sure defines_BE.h is used in defines.h. I have finished GDI and have not had this kind of bug.