ok I have the basics of what you might need all I have coded is the object selection nothing happens yet if you click on anything.
The objects will be replaced with green 7's objects
it is quite chunky but it works well.
sync on : sync rate 60
rem colours
red=rgb(150,0,0)
white=rgb(255,255,255)
gold=rgb(221,221,0)
rem make and set the orientation of the base(Table)
make object plain 6,7,5
xrotate object 6,90
fix object pivot 6
position object 6,0,-0.2,0
rem make the other objects
`object 1 (Load game)
make object box 2,1.6,0.01,1
position object 2,-1.7,0,-1
`object 2 (start new game)
make object box 3,0.9,0.7,1.5
position object 3,-2,0,1.5
yrotate object 3,40
`object 3 (Options)
make object sphere 4,1
position object 4,2,0,1.5
`object 4 (Quit)
make object box 5,0.9,0.07,1.5
position object 5,1.5,0,-1
yrotate object 5,20
rem setup the backdrop
color backdrop 0
set ambient light 50
main:
rem set the orientation of the camera
position camera 0,3,-2.3
point camera 0,0,0
rem main loop
do
set text font "American Uncial"
set text size 30
ink gold,0
if mousex()=>51 and mousex()=<226 and mousey()=>71 and mousey()=<205
color object 3,red
selection=1
center text 320,220,"START NEW GAME"
else color object 3,white
endif
if mousex()=>19 and mousex()=<206 and mousey()=>285 and mousey()=<406
color object 2,red
selection=2
center text 320,220,"LOAD GAME"
else color object 2,white
endif
if mousex()=>444 and mousex()=<539 and mousey()=>91 and mousey()=<179
color object 4,red
selection=3
center text 320,220,"OPTIONS"
else color object 4,white
endif
if mousex()=>433 and mousex()=<571 and mousey()=>250 and mousey()=<463
color object 5,red
selection=4
center text 320,220,"EXIT"
else color object 5,white
endif
if selection=1 and mouseclick()=1 then goto start
if selection=2 and mouseclick()=1 then goto load
if selection=3 and mouseclick()=1 then goto options
if selection=4 and mouseclick()=1 then goto quit
sync
loop
start:
do
set camera to follow object position x(3),object position y(3),object position z(3),120,-2,2,10,0
center text 320,160,"Press 1 For A Single Player Game"
center text 320,200,"Press 2 For A Multiplayer Game"
center text 320,240,"Press Return To Back Out"
if returnkey()=1 then goto main
sync
loop
load:
do
set camera to follow object position x(2), object position y(2), object position z(2),120,-2,2,10,0
Center text 320,200,"Load function to be written"
center text 320,240, "Press Return To Back Out"
if returnkey()=1 then goto main
sync
loop
options:
do
set camera to follow object position x(4),object position y(4), object position z(4),220,-2,2,10,0
center text 320,240,"Press return to back out"
if returnkey()=1 then goto main
sync
loop
quit:
do
set cursor 0,0
print mousex()
print mousey()
set camera to follow object position x(5), object position y(5), object position z(5),220,-2,2,10,0
center text 320,240,"Are You Sure?"
center text 320,280,"Yes No"
if mousex()=>266 and mousex()=<315 and mousey()=>288 and mousey()=<303 and mouseclick()=1 then end
if mousex()=>336 and mousex()=<376 and mousey()=>288 and mousey()=<303 and mouseclick()=1 then goto main
sync
loop
Just bare in mind this is just to show how I wish it to look the code might be changed later.
tell me what you think I can add and then I will try to add it.
cheers
BM
Our aim is to keep the loo's clean, your aim can help.