For levels I would either suggest looking into the advanced terrain feature of DBPro or using a modeller like 3D World Studio to model the levels.
You'd also probably need sparky's collision dll for the coliding stuff (much faster than native DBPro collisions)
I've heard tell of people using FPSC to create levels for DBPro projects, but I've never tried and dunno how hard it would be to pull off.
[Edit]
I also had to make the some changes to your code to make it run... I had some problems with a couple of the sound files being corrupt so I remmed them out. You were trying to load the music (as an MP3 file) with the sound commands, which only load wavs.
Thats all I can think of off the top of my head.
Here is my modified code. I had to change all the path names coz it was easier than putting all the media in the proper folders. Maybe next time try zipping it all up before you email?
Rem Project: Blightys Best
Rem Created: 8/4/2009 8:30:06 AM
Rem Author : John W Capon
Rem Version: 1.0.0.1
Rem ***** Main Source File *****
Sync on
sync rate 100
`Backdrop off
Hide mouse
Set text font "arial"
Set text size 16
Set text to bold
`Set text transparent
Sync
center text Screen width()/2,Screen height()/2,"LOADING"
Sync
Gosub LoadGame
`wait key
Gosub setupGame
Do
Gosub ControlPlayer
Gosub ControlGunandbullet
Gosub ControlEnemies
Sync
Loop
End
LoadGame:
`load bsp "world\dm_avalon_b1.pk3","dm_avalon_b1.bsp"
text 0,0,"Loading world":sync
`load bsp "","dm_avalon_b1.bsp"
text 0,20,"Loading objects":sync
SkyObj=1 : load object "sky02.x",SkyObj
GunObj=2 : load object "H-MP40-Static.x",GunObj
EneObj=11
for ene=EneObj to EneObj+4
load object "H-German-idle.x",ene
append object "H-German-Die.x",ene,total object frames(ene)+1
loop object ene,0,25
next ene
GunSnd=1 : load sound "Automatic loop.wav",GunSnd
ImpactSnd=2 : load sound "hit.wav",ImpactSnd
DieSnd=3 : load sound "moan.wav",DieSnd
`EnemySnd=11 : load 3dsound "PREL_TRAILER BED_SP01.36.wav",11 <----- this wav doesn't play in WMP, corrupt?
`EnemygunSnd=12 : load 3dsound "machgun.wav",EnemygunSnd <---- this wav plays ok in wmp, but refuese to load in DBP
EnemydieSnd=13 : load 3dsound "scream1.wav",EnemydieSnd
`MusicSnd=101 : load sound "music misty room.mp3",MusicSnd <--- This file needs to be a .wav to be loaded as a sound
load music "music misty room.mp3",1
`loop sound MusicSnd : set sound volume MusicSnd,80 <-------- due to changing
play music 1
Return
SetupGame:
set camera range 0.1,5000
autocam off
set object SkyObj,1,0,0,0,0,0,0
scale object SkyObj,20,20,20
lock object on GunObj
scale object GunObj,2,2,4
rotate object GunObj,270,0,0
position object GunObj,0.5,-1,2
disable object zdepth GunObj
BulletObj=3 : make object cube BulletObj,0.1
rem sprite1,320-16,240-16,CrossHairImg
set current bitmap 0
set sprite 1,0,1
offset sprite 1,16,16
draw to back
enemiesleft=0
`restore enemyposdata
for ene=EneObj to EneObj+4
read ex#,ey#,ez#
set bsp object collision 3+(ene-EneObj),ene,0.75,0
yrotate object ene,180
fix object pivot ene
inc enemiesleft
next ene
`loop sound EnemySnd
scale listener 0.1
Restart=1
Return
ControlPlayer:
rotate camera camera angle x(0)+(mousemovey()/2.0),camera angle y(0)+(mousemovex()/2.0),0
cx#=camera angle x(0)
cy#=camera angle y(0)
if upkey()=1
xrotate camera 0,0
move camera 0,0.2
xrotate camera 0,cx#
endif
if downkey()=1
xrotate camera 0,0
move camera 0,0.2
xrotate camera 0,cx#
endif
if leftkey()=1
yrotate camera 0,cy#-90
move camera 0.2
yrotate camera 0,cy#
endif
if rightkey()=1
yrotate camera 0,cy#+90
move camera 0.2
yrotate camera 0,cy#
endif
if wrapvalue(camera angle x(0))>40 and wrapvalue(camera angle x(0))<180
xrotate camera 0,40
endif
if wrapvalue(camera angle x(0))>180 and wrapvalue(camera angle x(0))<280
xrotate camera 0,280
endif
position camera camera position x(),camera position y()-0.1,camera position z()
position object SkyObj, camera position x(),camera position y(),camera position z()
position listener camera position x(),camera position y(), camera position z()
if restart=1
restart=0
set bsp collision off 1
rotate camera 0,0,0
position camera 2,2,2
set bsp camera collision 1,0,0.75,0
endif
Return
ControlGunandbullet:
if mouseclick()=1 and bullet=-50
bullet=100
play sound GunSnd
position object BulletObj,camera position x(0),camera position y(0),camera position z(0)
rotate object BulletObj,camera angle x(0),camera angle y(0),0
set bsp object collision 2,BulletObj,0.1,0
move object BulletObj,0.2
if particles exist(1)=1
delete particles 1
endif
make particles 1,FireImg,50,0.5
set particle emissions 1,10
set particle speed 1,0.01
endif
if bullet=0
if bsp collision hit(2)=1
position sound ImpactSnd,object position x(BulletObj),object position y(BulletObj),object position z(BulletObj)
play sound ImpactSnd
bulletimpact=0
bullet=0
else
dec bullet
move object BulletObj,0.5
endif
endif
`set particle emissions 1,1+(bullet/10)
`rotate particles 1,90-object angle x(BulletObj),object angle y(BulletObj)+180,0
`position particles 1,object position x(BulletObj),object position y(BulletObj),object position z(BulletObj)
if bullet=0
set particle emissions 1,0
set bsp collision off 2
endif
Return
ControlEnemies:
cdist#=9999.99
for ene=EneObj to EneObj+4
if object visible (ene)=1
killenemy=0
position object (ene),object position x(ene),object position y(ene)-0.01,object position z(ene)
dx#=camera position x(0)-object position x(ene)
dy#=camera position y(0)-object position y(ene)
dz#=camera position z(0)-object position z(ene)
dist#=abs (sqrt(abs(dx#*dx#)+abs(dy#*dy#)+abs(dz#*dz#)))
viewa#=wrapvalue(atanfull(dx#,dx#))
obja#=wrapvalue(object angle y(ene))
if viewa#>180
viewa#=viewa#-360
endif
if obja#>180
obja#=obja#-360
endif
if abs (viewa#-obja#)<10.0 and abs (dy#)<5.0 and dist#<30.0
if object angle z(ene)<>2
play sound EnemySnd
rotate object ene,0,viewa#,2
set object speed ene,200
else
set object speed ene,100
endif
endif
if bullet>0
if object collision(BulletObj,ene)>0
play sound EnemydieSnd
play object ene,26,26+50
set object speed ene,100
bulletimpact=1
endif
endif
if dist#<cdist#
cdist#=dist#
`position sound EnemySnd,object position x(ene),object position y(ene),object position z(ene)
`position sound EnemygunSnd,object position x(ene),object position y(ene),object position z(ene)
`position sound EnemydieSnd,object position x(ene),object position y(ene),object position z(ene)
endif
if object frame(ene)>26+25 and object visible(ene)=1
killenemy=1
endif
if killenemy=1
set bsp collision off 3+(ene-EneObj)
hide object ene
dec enemiesleft
killenemy=0
endif
endif
next ene
Return
Controlstats:
if enemiesleft>0
text 20,screen height()-40,"DISTANCE READING:"+str$(abs(cdist#*100))
endif
s$=str$(enemiesleft)+"ENEMIES LEFT"
if enemiesleft=0
s$="LEVEL COMPLETE"
stop sound EnemySnd
endif
text 640-20-text width(s$),screen height()-40,s$
Return
This code will compile (once you sort the paths of the media out again); but it doesn't work as I think u intend it to do.
But just so you can see how well you've done
Without Music or Love the world would be a very empty place... Thank god I still have music.. --'-<@