Hi there.
@Chaosmatt
What I do is divide the screen to know where we are. We can see that with an example and it works without the lines...they are just to show where we are...
`Dividing screen to know where we are.
do
ink rgb(40,40,40),1
box 0,0,640,480
ink rgb(200,255,0),1
`Vertical lines
for i= 0 to 640 step 24
line 0,i,640,i
next i
`Horizontal lines
for a= 0 to 640 step 32
line a,0,a,480
next i
ink rgb(0,255,0),0
set cursor 10,30
print "Go to area 35"
row=1+mousey()/24 `480/20=24
area=1+mousex()/32 `640/20=32
`20 row of areas
for colum= 1 to 19
if row>colum then area=area+20
next colum
ink rgb(200,255,0),1
set cursor 5,5
print area
`Cheking if we are into an area (zone)
if area=35
ink rgb(255,0,0),0
box 449,25,480,48
set cursor 400,50
print "Get out of here ¡¡ "
endif
sync
loop
As you comment, you can use a variable to disable mouse buttons...here another example...I hope it helps someone.
autocam off
sync on
make object box 1,2,1,2
make object box 2,20,0,20:color object 2,rgb(0,255,0)
position object 2,2,0,0
position camera -5,10,-10
point camera 0,0,0
do
set cursor 5,5
print "move by mouseclick"
`if we press mouse-left, we move our object, and just when we releaze mouse
`we'll be able to click mouse again.
if mouseclick()=1
run=run+1
if run=2 then move object 1,2
else run=0
endif
sync
loop
Cheers.
I'm not a grumpy grandpa
