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 / loading custom 3d models

Author
Message
game master 07
17
Years of Service
User Offline
Joined: 26th Feb 2007
Location: Maryland
Posted: 21st Mar 2007 04:13 Edited at: 21st Mar 2007 04:15
I need help with a big problem im having. I can not find a single tutorial or code for loading a 3d model and putting the camera and contols on it. The only thing i have found were tutorials and codes that have dark basic create its own 3d models and control them. Here is the part of the codes I am having trouble with. make object box. What i want to know is what code should i type in place of make object
box,sphere etc, in order to load my own model? ALso what is the code in order to have the texture loaded onto the model?

gm07
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 21st Mar 2007 05:26 Edited at: 21st Mar 2007 05:26
the command to load your own is

load object "filename",objectnumber

if the model has already been uv mapped and the texture is in the same folder as the model
it will load itself.

otherwise you might need to deploy
texture object objectnumber,texturenumber

game master 07
17
Years of Service
User Offline
Joined: 26th Feb 2007
Location: Maryland
Posted: 21st Mar 2007 17:36 Edited at: 21st Mar 2007 19:54
Thanks that helped allot. One more question though. What files can dbp load and what files cant it load. I use the .x format to play it safe because that is the most game friendly format there is. Can dbp load files such as .max, .lwo, maya files, and .3ds files?

gm07
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 21st Mar 2007 18:19
.dbo and .x are your safest bets

game master 07
17
Years of Service
User Offline
Joined: 26th Feb 2007
Location: Maryland
Posted: 21st Mar 2007 19:50 Edited at: 21st Mar 2007 19:51
ok i will just stick with them. Also do you know were an x to dbo file object converter is?

gm07
Scorpyo
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: italy
Posted: 21st Mar 2007 22:39
You can use DBP itself
laod it as .x and save it like:

save object "myobject.dbo",objnum
game master 07
17
Years of Service
User Offline
Joined: 26th Feb 2007
Location: Maryland
Posted: 21st Mar 2007 23:00 Edited at: 21st Mar 2007 23:31
I Have on more problem. How to I make my model so its not backwards. This is the code that i made. Im not sure how to do the code snippet thing so i am just typing it here.



I am using a viper model from Battlestar Galactica for my model.
When I run the game the model is backwards.
Also I did the texture code but the textures still wont show.
Here is a pic

gm07

Attachments

Login to view attachments
TDK
Retired Moderator
21
Years of Service
User Offline
Joined: 19th Nov 2002
Location: UK
Posted: 21st Mar 2007 23:14
Quote: "Im not sure how to do the code snippet thing so i am just typing it here"


1. Edit your post via the Edit link (bottom left of post)

2. Highlight the entire code snippet with the mouse

3. Click on the Code button (far right button at the top of the box you see your code in)

Quote: "How to I make my model so its not backwards"


Rotate it. You can rotate on the X, Y or Z axis, so which you use depends on what you mean by 'backwards'.

For example, if you have a character model loaded and he is upright, but facing towards you, then to have him face away from you to walk, you would rotate it 180 degrees on the Y axis with YRotate Object.

Once this is done, using Fix Object Pivot will set that object so that it's X, Y, Z angles are all zeroed, (as if it was loaded in pointing in the right direction in the first place).

TDK_Man

Dracula
18
Years of Service
User Offline
Joined: 7th Aug 2006
Location: DBP Recreation of Castle Csejthe
Posted: 21st Mar 2007 23:24
Quote: "Also I did the texture code but the textures still wont show."

I would do what indi suggested and have it mapped and textured before hand. Then have both the .x or .dbo and the texture file in the same folder. This way it will load with the object and you won't have to code it.

Quote: "How to I make my model so its not backwards"

Of course, TDK is right, but if you want to avoid the coding part, just reorient your model in your modeling program, then re-export it.



D
game master 07
17
Years of Service
User Offline
Joined: 26th Feb 2007
Location: Maryland
Posted: 21st Mar 2007 23:32
Alright i have it working now. And I also put the code in the snippet box on my old post. I am done needing help now but thanks everyone.

gm07
Kieran
18
Years of Service
User Offline
Joined: 6th Aug 2006
Location: Hamilton, New Zealand
Posted: 22nd Mar 2007 20:35
the supported files are .x .dbo .md1 .md2 .md3

i reccomend .x and .dbo


RPG Engine Work in progress!

Login to post a reply

Server time is: 2024-09-25 19:14:19
Your offset time is: 2024-09-25 19:14:19