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 Discussion / Animated player on matrix

Author
Message
EddieB
20
Years of Service
User Offline
Joined: 29th Sep 2004
Location: United Kingdom
Posted: 10th Oct 2004 07:05 Edited at: 10th Oct 2004 07:17
hi im using dbc. Heres my code


Can some 1 help me so that the cam follows the player and so i can walk on the matrix. For example a car when i press upkey the car moves and the wheels spin

200GB HARD DRIVE 1GB RAM 256MB GRAPHICS CARD
<img src="http://www.freewebs.com/warhammered/image2.jpg">
GameKit
22
Years of Service
User Offline
Joined: 6th Mar 2003
Location: USA, Staring Blankly at a Computer
Posted: 14th Oct 2004 08:22
To get the camera to follow the object you could use simple code like this...

Position Camera Object Position X(1),Object Position Y(1),Object Position Z(1)
Y Rotate Camera a#
Move Camera -20
Position Camera Camera Position X(),Camera Position Y()+15,Camera Position Z()

...This is a really simple way of getting the camera to follow an object. I'm too lazy to type out the maths to make it work smoothly. As for the character walking at the height of the matrix...

Position Object 1,Object Position X(1), Get Ground Height(1,Object Position X(1),Object Position Z(1)),Object Position Z(1)

...that should do it.
Well... I hope I helped...


The computer isn't an addiction, its more of a mental and social dependancy.

Login to post a reply

Server time is: 2025-05-24 17:09:54
Your offset time is: 2025-05-24 17:09:54