Ok, thanks for the update
Below is the part of my code where I originally ran into this issue. I eventually arrived at the above example while painstakingly debugging it:
Without that CAST, it just gives the wrong answer since all the PEEK results are UBYTE.
In the above expression, did I put the CAST in the correct location?
Below is the part of my code where I originally ran into this issue. I eventually arrived at the above example while painstakingly debugging it:
Code:
castleIntactAttr=(64*CAST(UINTEGER, PEEK (n+4))+8*skyCol+PEEK (n+5)+64*PEEK (n+6)+8*skyCol+PEEK (n+7))*2
Without that CAST, it just gives the wrong answer since all the PEEK results are UBYTE.
In the above expression, did I put the CAST in the correct location?