Hi,
I am currently in the process of creating a FPS game that is set back along time ago when they used swords and bows. I am having trouble with walking up scaffolding, stairs and such.
I am sorta a noob because I dont know how to do alot of things in DBC, but I have had it for almost 2 years now (just havent had alot of time to spend learning because of school), so bear with me!
Here's my code:
`Setup
sync on
sync rate 0
`set camera range 1,10000
`Loading Screen
text Screen Width()/2,Screen Height()/2,"LOADING"
`Load Objects
load object "Castle.x",1
load image "Floor.jpg",1
load image "Roof.jpg",2
load image "Wall1.jpg",3
load image "Wall2.jpg",4
load image "Wood.jpg",5
make object cube 2,10
`Texture Castle With Textures
texture object 1,3
`Scale Castle to correct Size
scale object 1,20,20,20
`Position Castle
position object 1,0,0,0
`Set object collision
set object collision on 1
set object collision on 2
set global collision on
draw to front
`Main Program
do
`Detect object collision
if object collision(1,2) = 1
text 0,0,"HIT"
else
text 0,0,"MISS"
endif
if inkey$()= "w" then x#=newxvalue(x#,camera angle y(),1.0) : z#=newzvalue(z#,camera angle y(),1.0)
if inkey$()="s" then x#=newxvalue(x#,camera angle y(),-1.0) : z#=newzvalue(z#,camera angle y(),-1.0)
position mouse 320,240 : hide mouse
yrotate camera wrapvalue(camera angle y()+mousemovex())
xrotate camera wrapvalue(camera angle x()+mousemovey())
`Now add strafing
if inkey$()="a" then x#=newxvalue(x#,camera angle y()+90.0,-1.0) : z#=newzvalue(z#,camera angle y()+90.0,-1.0)
if inkey$()="d" then x#=newxvalue(x#,camera angle y()+90.0,1.0) : z#=newzvalue(z#,camera angle y()+90.0,1.0)
`Update camera position
position camera x#,50,z#
position object 2,x#,20,z#
sync
loop
and the media is attached.
also my castle level that i built using DeleD LITE is soppossed to be textured all differently (i.e. the ground is dirt texture, walls are brick texture, etc...) but i am not able to texture certain things differently than other things because the whole level is one object.
I would greatly appreciate an help!
Thanks!
-Captain-

Cheers,
Capt. America