After great efforts, and trying to understand syntax of Sparky's sliding collision, I couldn't solve my problem.
I made simple program where character in first person walks inside room. I cannot make him not to walk thtough walls. Here is my code:
sync on : sync rate 0 : hide mouse
load image "C:\Documents and Settings\Boran VELIKI\Desktop\Moje\Dark Basic Pro\textura.bmp",1
make light 1 : position light 1,0,110,0
make object box 1,500,5,500 : position object 1,0,-50,0
make object box 2,500,5,500 : position object 2,0,220,0
make object box 3,5,500,500 : position object 3,-250,0,0
make object box 4,5,500,500 : position object 4,250,0,0
make object box 5,500,500,5 : position object 5,0,0,250
make object box 6,500,500,5 : position object 6,0,0,-250
make object sphere 7,50 : position object 7,0,0,0 : hide object 7
set object collision to spheres 7
for x=1 to 6
texture object x,1
set object collision to boxes x
next x
position camera 0,0,0
do
opx#=object position x(7) : opy#=0,opz#=object position z(7)
text 20,20,str$(opz#)
text 20,40,str$(opx#)
text 20,60,str$(opy#)
position camera object position x(7),opy#,object position z(7)
if keystate(17)=1 then move object 7,0.5
if keystate(31)=1 then move object 7,-0.5
if keystate(30)=1 then move object left 7,0.3
if keystate(32)=1 then move object right 7,0.3
x#=object position x(7) : y#=object position y(7) : z#=object position z(7)
cx#=cx#+mousemovey()*0.1
cy#=cy#+mousemovex()*0.1
if cx#>90 then cx#=90
if cx#<-90 then cx#=-90
yrotate camera cy#
xrotate camera cx#
xrotate object 7,cx#
yrotate object 7,cy#
sync
loop
Can anyone modify this code to make my character stay inside room? I use Sparky's dll for collision...
Thank you...