Replaced all ints with intptr_t, hopefully should work on 64 bit now?