Turing Help
Posted: Tue Mar 16, 2004 9:17 am
I'm suppose to be doing a dice game during this break but there's something wrong with my program. See, I have a problem with my code. When you choose the play button, it loads the screen instantly but then it goes right to the procedure that tells you how to play and then goes to the next procedure. How do you make it so that the procedure is only active when you choose it? I tried putting it in the conditional loop but there was an error when I did that. If anybody can help me I'll be really happy.
Code: Select all
loop
if Mouse.ButtonMoved ("up") then
Mouse.ButtonWait ("down", x, y, buttonnumber, buttonupdown)
if x >= 220 and x <= 300 and y >= 100 and y <= 130 then
delay (300)
cls
Pic.ScreenLoad ("chess-game-carpet600.jpg", 0, 0, picXor)
exit
elsif x < 220 and x > 300 and y < 100 and y > 130 then
return % goes back to the beginning if out of range of button
end if
if x >= 320 and x <= 400 and y >= 100 and y <= 130 then
exit
elsif x < 320 and x > 400 and y < 100 and y > 130 then
return
end if
if x >= 420 and x <= 500 and y >= 100 and y <= 130 then
delay (400)
Window.Select (helpWindow)
elsif x < 420 and x > 500 and y < 100 and y < 130 then
return
end if
end if
end loop
drawfillbox (maxx, 0, 600, maxy, grey)
Font.Draw ("Menu", 550, 600, button, 0)
include "proc howtoplay.t"
include "N ame.t"
[code]
[color=#888888][size=85]Archived topic from Iceteks, old topic ID:2147, old post ID:18257[/size][/color]