Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Object disappears

Author
Message
AuzingLG
22
Years of Service
User Offline
Joined: 19th Sep 2003
Location:
Posted: 26th Sep 2003 00:05
Hello! I started a racing game and tried to add first moving. But after some 360° rotations, the object disappers. When I rotate back, it's visible again! And the object is an animated model from DarkMATTER, but the animations are not working... here's my code:


Please wait. Loading Signature...
dugzilla
22
Years of Service
User Offline
Joined: 5th Aug 2003
Location:
Posted: 26th Sep 2003 16:18
I've never had any luck using the ".3ds" file. It won't even load on
either of my computers I have. Try using the ".x" file. If that
doesn't help look over the code again.I had the same problem before
not knowing how to write the set camera to follow command.you don't
have the wrapvalue set in to your rotate. I'm still a little fuzzy
on this but the code I wrote does work.
Hope this helps...
Dugzilla
P.S. I wrote two object charactors in this code.
dugzilla
22
Years of Service
User Offline
Joined: 5th Aug 2003
Location:
Posted: 26th Sep 2003 16:21
x=upkey()
xl=leftkey()
xr=rightkey()
f=keystate(33)
c=keystate(46)
v=keystate(47)
rem f=up,c=left,v=right
if f=1 then loop object 2 : move object up 2,-.3
if f=0 then stop object 2
if c=1
yrotate object 2,wrapvalue(object angle y(2)-4)
loop object 2
endif
if v=1
yrotate object 2,wrapvalue(object angle y(2)+4)
loop object 2
endif
if x=0 then loop object 1,1,9000
if x=1 then move object up 1,-.3 : loop object 1,26900,32300
if xr=1
yrotate object 1,wrapvalue(object angle y(1)+4)
loop object 1,26900,32300
endif
if xl=1
yrotate object 1,wrapvalue(object angle y(1)-4)
loop object 1,26900,32300
endif
x#=object position x(1)
y#=object position y(1)
z#=object position z(1)
a#=object angle y(1)
d#=28.0
h#=20.0
s#=20.0
set camera to follow x#,y#,z#,a#,d#,h#,s#,1

Login to post a reply

Server time is: 2026-07-25 07:00:46
Your offset time is: 2026-07-25 07:00:46