hi,
basicly i have started to write a monopoly game, have drawn the board in paintshop and is 660x660
for testing sprite movement i have used up/down/left/right and the sprite moves perfectly from square to square by changing the xpos/ypos by either +66 or -66 (66 being one move)
but in order to get my dice making the moves i need some code to make the sprite move around the board and not go off the screen.
i tried to do this by just using the leftkey() to simulate the dice moves and managed to get the sprite from 'go' to 'just visiting' and to 'free parking' using the code below.
but cant seem to make the sprite continue around the board back to 'go'
have been trying now for the last two nights so any help would be great.
xpos=660
ypos=660
do
if leftkey()=1 then xpos=xpos-66
this line below makes my sprite continue up the board to 'free parking'
if xpos=<-10 and ypos=<660 then ypos=ypos-66:xpos=0
but i have tried different variations of above line and nothing works
board layout below if it helps you to help me
top left (xpos=0/ypos=0)
top right (xpos=660/ypos=0)
bottom left (xpos=0/ypos=660)
bottom right (xpos=660/ypos=660)
thanks
ash