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.

Newcomers DBPro Corner / 3D Camera Command

Author
Message
James Bond
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location:
Posted: 26th Jul 2004 16:43
i want to do this that when i rotate my car the camera always show the back side of the car ..... for this purpose i must use which command?? . position camera , rotate camera what?
David T
Retired Moderator
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: England
Posted: 26th Jul 2004 18:04
Well, if the camera is positioned behind the car, just not pointing at it, then you can use point camera.

If the camera isn't positioned behind the car yet, use position camera first.

Get 15 new commands, all the date / time commands left out of DBPro for free!
DOWNLOAD PLUGINS HERE: http://www.davidtattersall.me.uk/ and select "DarkBasic"
James Bond
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location:
Posted: 26th Jul 2004 18:43
i dont know how to use this command .... i tried it but can't ..... plz edit the point camera command for me

sync on
sync rate 30
hide mouse
for x = 1 to 10
make object cube x,100
position object x,rnd(2000),0,rnd(2000)
next x
load object "c:\cube.x",1
do
if rightkey()=1
y=wrapvalue(y+5)
angley#=wrapvalue(angley#+10.0)
xrotate camera 0
yrotate camera angley#
zrotate camera 0
point camera angle#,angle#,0
endif
if leftkey()=1
y=wrapvalue(y-5)
angley#=wrapvalue(angley#-10.0)
xrotate camera 0.0
yrotate camera angley#
zrotate camera 0.0
point camera angle#,angle#,0
endif
if upkey()=1
move camera 10.0
move object 1,10
endif
if downkey()=1
move object 1,-10
move camera -10.0
endif
yrotate object 1,y
sync
loop

Login to post a reply

Server time is: 2024-11-27 02:45:50
Your offset time is: 2024-11-27 02:45:50