Hey there,
I have been having some difficulty today, being the christmas holidays and all I have had some drink, not being a pro drinker I seem to have lost most if not all of my brain-cells. It took me a while to get more than one box to appear on the screen and now I cant figure out how to make my count variable increase by one per click and not a bazillion if you have you fingure on the mouse for more than a second. Hope you understand what I mean. hopefully the code follows below;
dim left(100) : dim top(100) : dim right(100) : dim bottom(100)
count=0
`-------------------------------------------------------------------------------------------------------------------`
REPEAT
box 0,0,500,500,rgb(0,255,0),rgb(255,255,255),rgb(255,255,255),rgb(0,255,0)
for y=0 to 500 step 10
for x=0 to 500 step 10
dot x,y,0
if mX>x and mX<x+11
if mY>y and mY<y+11
box x,y,x+11,y+11
if mouseclick()=1 : count=count+1
left(count)=x : top(count)=y : right(count)=x+11 : bottom(count)=y+11
endif
endif
endif
next x
next y
for x=1 to count
box left(x),top(x),right(x),bottom(x)
next x
text 0,450,""+str$(count)
sync
UNTIL escapekey()=1
end
I hope you get the idea, thanks in advance
Squids.
Edit: I can add a sleep 100 to make the boxes appear slower but I am not sure what to do about the fact that if you keep clicked for more than the sleeps length you will increase the count :/ sorry,.
.Arf..