Page 1 of 1

Change Ship Size (Dimensions)

Posted: Sun Feb 27, 2011 8:23 pm
by woody22075
I am new to oolite. How does one change a ships size (exterior dimensions) from an .oxp? sounds like cheating, but i am starting with modifying existing oxp's before designing my own. thank you for any input.

Re: Change Ship Size (Dimensions)

Posted: Sun Feb 27, 2011 8:28 pm
by Smivs
Hi woody22075, and welcome to the friendliest board this side of Riedquat.

I'm afraid you can't change the ship dimensions as they are dependent on the model used. You'd have to start from scratch and make a new model if you wanted a 'bigger' version of anything.

Re: Change Ship Size (Dimensions)

Posted: Sun Feb 27, 2011 8:38 pm
by woody22075
But couldn't I change the dimensions of a current model (from an add on oxp)? thanks again for your input. Also, what is the easiest way for a new ship designer to design a ship?

Re: Change Ship Size (Dimensions)

Posted: Sun Feb 27, 2011 8:53 pm
by Commander McLane
Hi, woody22075, and first of all welcome to the boards, and of course to this great game! :D
woody22075 wrote:
But couldn't I change the dimensions of a current model (from an add on oxp)? thanks again for your input. Also, what is the easiest way for a new ship designer to design a ship?
The answer to both questions is the same: you need a 3d-model design software, for instance Wings3D (many of our ship designers are using it, but others prefer other software).

With this software you can either design new ships from scratch, or take an existing ship model and modify it (e.g. by shrinking it).

You will also need a conversion tool, in order to convert from the format your 3d-software is using to the .dat-format used by Oolite and back.

The Elite Wiki has plenty of information about all this, but unfortunately it is currently off-line. We're waiting for it to get restored.

Re: Change Ship Size (Dimensions)

Posted: Sun Feb 27, 2011 9:11 pm
by dertien
Hi Woody and welcome,

Sure you can.

Resizing and making a model (the 3d part) is actually pretty easy. It is making a texture that is hard. Guiding you step by step through making a model here would be beyond the scope of my message.

A) Basically you need these programs. (google them for the link)

3D part

- Wings 3d (free)
- Python (free )
- Dat2ObjTex.py and Obj2dat.py (http://svn.berlios.de/svnroot/repos/ool ... onverters/) to convert between dat and obj files and vice versa.

Skinning part

- photoshop, paint dot net, the gimp etc...

B) very basic knowledge of:

- 3d creation (make a cube or a brick and import it ingame)
- UV-mapping (flattening 3d to 2d to put a texture or skin on the 3d object)
- creating batch files or knowledge of dos commands (to convert from obj to dat and vice versa)
- image manipulation

C) imagination, precision and willpower.

You will swear often if things dont turn out in the beginning, but that is part of the learning process.

And finally a few little tips:

1)
You can open .dat and .obj files with a text editor (notepad, alleycode, dreamweaver). Lets say you have made a brick and put a texture on it in wings to bring it ingame. Make sure that all faces have a texture on them, and delete the faces on the INSIDE of the brick you are not going to be visible ingame. The conversion script will NOT add any texture to the .dat file at all if you don't and the texture will NOT show ingame.

2)
If you add light effects to your brick, make sure that you export the model with "hemispherical lighting" set as shader in wings3d. It is normally the default activated shader when you install wings 3d but should you change it to view it differently in wings be sure to put it back to hemispherical lighting under the VIEWS>SHADERS menu in wings.
If you don't your lighting will not work at all ingame.

Hope this puts you underway

Steve

Re: Change Ship Size (Dimensions)

Posted: Mon Feb 28, 2011 8:40 am
by Griff
There's also the DatScale.py script found in the link that dertien posted above
running that script on a .dat file will generate a rescaled copy of it, here's Ahrumans post that explains it's usage
https://bb.oolite.space/viewtopic.php?f=4&t=8145
I used it ages ago to rescale my asteroid models, if i remember correctly in Ahrumans example

Code: Select all

DatScale.py foo.dat 4.2
the 4.2 on the end will scale up the model 4.2 times, so to shrink it down 50% you'd type

Code: Select all

DatScale.py foo.dat 0.5
at least i think that's how it works, the dimensions are written in the newly generated .dat it spits out so you could always open it in a text editor and check it's at the size you want

Re: Change Ship Size (Dimensions)

Posted: Mon Feb 28, 2011 11:33 am
by woody22075
Thank you everyone for the super-fast responses! I very much enjoy playing oolite and look forwards to designing a ship for myself.

Re: Change Ship Size (Dimensions)

Posted: Mon Feb 28, 2011 12:19 pm
by Smivs
...and we're looking forward to seeing it. :)

Re: Change Ship Size (Dimensions)

Posted: Mon Feb 28, 2011 1:05 pm
by dertien
Smivs wrote:
...and we're looking forward to seeing it. :)

Yes we are ! :D

Re: Change Ship Size (Dimensions)

Posted: Mon Feb 28, 2011 1:08 pm
by dertien
Griff wrote:
There's also the DatScale.py script found in the link that dertien posted above
running that script on a .dat file will generate a rescaled copy of it, here's Ahrumans post that explains it's usage
https://bb.oolite.space/viewtopic.php?f=4&t=8145
I used it ages ago to rescale my asteroid models, if i remember correctly in Ahrumans example

Code: Select all

DatScale.py foo.dat 4.2
the 4.2 on the end will scale up the model 4.2 times, so to shrink it down 50% you'd type

Code: Select all

DatScale.py foo.dat 0.5
at least i think that's how it works, the dimensions are written in the newly generated .dat it spits out so you could always open it in a text editor and check it's at the size you want

Thanks for that Griff, Didn't know that.