Well here's the full code- if u cud fix it then thanx
Rem Project: Alien
Rem Created: 30/08/2003 09:26:01
Rem ***** Main Source File *****
set splash number of files 3
x=splash screen on("alienware_logo_black_on_white.bmp",JUST_CURRENTFILE || USE_TRIANGLE,100,100)
load music "alien track.mp3",1
load object "alien.x",1
load image "alien_gn.bmp",1
texture object 1,1
prepareoff:
sync on
sync rate 60
open to read 1,"settings.dat"
read word 1,w
read word 1,h
read word 1,d
set display mode w,h,d
read word 1,gr
read word 1,gg
read word 1,gb
if gr>0 or gg>0 or gb>0 then set gamma gr,gg,gb
read word 1,mv
read word 1,sv
close file 1
hw=screen width()/2
set music volume 1,mv
loop music 1
x=splash screen off()
prepareon:
color backdrop rgb(0,0,0)
set object speed 1,300
position object 1,0,-100,0
scale object 1,50,50,50
loop object 1,670,720
position camera 0,0,-200
set camera to object orientation 1
set text size 30
set text font "comic sans ms"
menu:
sync on
sync rate 30
open to read 2,"savegame.dat"
read string 2,str$(saves)
close file 2
do
if saves=0
if centerclick(hw,100,"New Game")=1 then goto newgame
if centerclick(hw,200,"Settings")=1 then goto settings
if centerclick(hw,300,"Quit")=1 then gosub quit
endif
if saves=>1
if centerclick(hw,100,"New Game") then goto newgame
if centerclick(hw,200,"Continue Game") then goto continue
if centerclick(hw,300,"Settings") then goto settings
if centerclick(hw,400,"Quit") then gosub quit
endif
sync
loop
newgame:
hide object 1
`load object "Man.X",2
`load object "Woman.x",3
`hide object 2
`hide object 3
cls
do
text 10,10,"Name:"
set cursor 40,10
input name$
center text hw,50,"Select your character"
`show object 2
`show object 3
goto lvl1load
loop
continue:
open to read 2,"savegame.txt"
read string 2,str$(am)
for ss = 1 to am
read string 2,str$(ss)
next ss
close file 2
settings:
hide object 1
delete object 1
cls
wait 1000
size$=str$(w)+","+str$(h)
do
if textclick(10,50,"Screen Size") then gosub screensize
if textclick(300,50,size$) then gosub screensize
if textclick(10,100,"Screen Depth") then gosub depth
if textclick(300,100,str$(d)) then gosub depth
if textclick(10,150,"Gamma") then gosub gamma
if textclick(250,150,"Red") then gosub gamma
if textclick(300,150,str$(gr)) then gosub gamma
if textclick(250,175,"Green") then gosub gamma
if textclick(300,175,str$(gg)) then gosub gamma
if textclick(250,200,"Blue") then gosub gamma
if textclick(300,200,str$(gb)) then gosub gamma
if textclick(10,250,"Volume") then gosub volume
if textclick(250,250,"Music") then gosub volume
if textclick(300,250,str$(mv)) then gosub volume
if textclick(250,300,"Sound") then gosub volume
if textclick(300,300,str$(sv)) then gosub volume
if centerclick(hw,550,"Back")=1 then goto prepareoff
loop
screensize:
center text hw,350,"Screen Size"
do
size(800,600,w/3)
size(1024,768,(w/3)*2)
loop
depth:
center text hw,350,"Screen Depth"
do
depth(16,w/4)
depth(24,w/2)
depth(32,(w/4)*3)
loop
gamma:
center text hw,350,"Gamma"
volume:
center text hw,350,"Volume"
quit:
end
lvl1load:
cls
show object 1
`load object "tree.x",3
position object 1,0,0,0
`position object 2,0,100,0
point object 1,0,0,0
position camera 0,0,0
circx#=300
circz#=300
position object 1,circx#,circy#,0
for t=5 to 125
clone object 1,t
position object t,circx#+(cos((t-4)*3)*300),0,circz#+(sin((t-4)*3)*300)
if sqrt(((object position x(T)-circx#)^2)+((object position z(T)-circz#)^2))<300 then delete object t
sync
next t
gosub time
gosub tokens
time:
mins#=2
secs#=59
wait 1000
secs#=secs#-1
if secs#=0
secs#=59
mins#=mins#-1
endif
if secs#=0 and mins#=0
goto result
endif
tokens:
score#=0
result:
text 10,50,"Score: "
text 10,100,"Time Bonus: "
text 10,150,"Stealth Bonus: "
text 10,200,"Total Score: "
function centerclick(x,y,ctext$)
center text x,y,ctext$
htw=text width (ctext$)/2
hth=text height (ctext$)/2
if click(x-htw,y-hth,x+htw,y+hth)
clicked=1
else
clicked=0
endif
endfunction clicked
function textclick(x,y,textc$)
center text x,y,textc$
htw=text width (textc$)/2
hth=text height (textc$)/2
if click(x-htw,y-hth,x+htw,y+hth)
clicked=1
else
clicked=0
endif
endfunction clicked
function depth(de,pl)
if de=d
set text to bolditalic
center text pl,400,str$(de)
set text to normal
else
center text pl,400,str$(de)
endif
if click(pl-30,325,pl+30,375)
if check display mode (w,h,de)=1
set display mode w,h,de
save=on
return
endif
else center text hw,400,"Screen depth not available, please select another."
endif
endfunction deep
function size(x,y,pl)
if x=w and y=h
set text to bolditalic
center text pl,400,str$(x)+" by "+str$(y)
set text to normal
else
center text pl,400,str$(x)+" by "+str$(y)
endif
if click(pl-30,325,pl+30,375)
if check display mode (x,y,d)=1
set display mode x,y,d
save=on
return
endif
else center text hw,400,"Screen size not available, please select another."
endif
endfunction display
function click(x1,y1,x2,y2)
clicked=0
if mouseclick()=1
if mousex()>x1 and mousex()<x2
if mousey()>y1 and mousey()<y2
clicked=1
endif
if mouseclick()=2
clicked=2
endif
endif
endif
endfunction clicked
www.tinnedhead.tk watch this space for the first ever calculator to show the working out. also look out for our first game- ww.exor-mk1.tk