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 / HELP HELP HELP

Author
Message
Stevie
User Banned
Posted: 28th Jul 2004 07:00
I have just recently posted a question re moving an object in 3d space. I noticed that when i placed an object on the screen, i had only to increment its position a little bit before it went off the screen.

I was told that this is due to the fact that the auto camera homed in on my object - that made sense.

Anyway - the anwers on the forumn to my question told me to use autocam off and then manually position the camera. Put when i tried to position my object at something like 500,50,500 r whatever and then position the camera at the same coord - the object didnt apear - why???????????

This whole 3d space thing really really confuses me and i can program 2d and make simple games, but the concept of moving within confuses me totally. What is the grid size of this space - if i position an object in it - how do i set it up - so it takes more to increment it before it moves off screen///
Rye
21
Years of Service
User Offline
Joined: 30th May 2003
Location: United Kingdom, Blackrod
Posted: 28th Jul 2004 07:11 Edited at: 28th Jul 2004 07:14
from your 3rd paragraph it sounds to me like your positioning the camera inside the object. try:

sync on
sync rate 30
autocam off

make object cube 1,5
position object,10
position camera 0,0,0

do
sync
loop

as for the grid size it is infinitly small, you could move an object 0.000000000001 but you wouldn't see the difference.

If you move an object too far or too close then it will leave the range of the camera. to change this look up this command "set camera range"
Yart
20
Years of Service
User Offline
Joined: 23rd Jun 2004
Location: Turkey Sandwich
Posted: 28th Jul 2004 07:12 Edited at: 28th Jul 2004 07:12
Ok first of all, you can't put the camera inside of the object, just like what you did and thats why it's not showing. So try maybe 0,0,10 for the camera position and put your object on like 0,0,0 so it'll be right infront of the camera. Remember, X,Y,Z those are the axises. If looking at the default direction of the camera, X will be right and left, Y will be foward and back and Z will be up and down.

Now for the increment, lets say you wanna place a cube as your object, use the sync commands to change the speed or whatever so it don't go too fast and therefore 1 increment ain't too much!

check out code



Something like that would be ok

EDIT: Dang! Ryan beat me to it!

Pie!
CattleRustler
Retired Moderator
21
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 28th Jul 2004 07:14
Quote: "Ok first of all, you can't put the camera inside of the object"


sure you can, and its a common beginners mistake here.


DBP_NETLIB_v1.4.3 - 65 FREE Functions * Click Logo
Yart
20
Years of Service
User Offline
Joined: 23rd Jun 2004
Location: Turkey Sandwich
Posted: 28th Jul 2004 07:17 Edited at: 28th Jul 2004 07:17
well ok you can put it inside... just it won't show the object... and Ryan's incorrect... unless he is talking about DBC... unless it's wrong there too. It ain't make object cube, but rather make object box

EDIT: Wasn't his name Ryan a while ago?

Pie!
Rye
21
Years of Service
User Offline
Joined: 30th May 2003
Location: United Kingdom, Blackrod
Posted: 28th Jul 2004 07:25
ryan rye not much difference, rye goes better with my avatar tho

Oh and im not incorrect, they both work, make object cube only requires 2 params and creates a perfect cube, could just use make object box obj,x,x,x (x=constant) it doesnt make any noticable difference.
DLS
20
Years of Service
User Offline
Joined: 6th Jul 2004
Location: Wet And Windy Britain
Posted: 28th Jul 2004 07:53
Bet u done exactly what i did.

i got a 3D shooter game up and running (ish) and i found out that it don't work on pixel position like 1024x768 but 3D location.

so in effect moving an object by 1 3D unit and not one pixel.

try using (if u want it to go left)

move object left object_number,0.01
(where object_number is the number of ya object)

it should at least move slower and not dissapear. as u'll see it uses real numbers (part numbers) and not whole numbers like 1,2,3 etc

oh and u don't need to manualy position the camera

its hard to explane being a n00b at 3D but i hope i shed some light on the problem

Login to post a reply

Server time is: 2024-11-27 02:22:57
Your offset time is: 2024-11-27 02:22:57