|
We're
going to export our engine now, but before we do, we need to get
rid of the Blueprint cube. Select the BluePrint cube
and hit the DELETE key on the keyboard.
Now,
export the engine by going to File on the menu bar and select
Export. Save the .3DS file to your myloco directory
as myloco2000.3DS (Hit yes to preserving the MAX texture
coordinates) and quit out of 3DSMAX.
When
3DSMAX asks if you want to save your project, hit NO. - we
already saved it before with the Blueprint cube still intact.
To convert
the .3ds file to a MSTS .s file, we'll need to modify our batch
file from the previous tutroials.
Find
the myloco directory, right-click on convertmyloco.bat
and select Edit. Replace any occurrence of Dash9
or testtex with myloco.
Your
convertmyloco.bat file should look like this:
conv3ds
myloco.s myloco2000.3ds
txt2uni
myloco.s
makeace
myloco.tga myloco.ace -trans
Save
the convertmyloco.bat file, close the text editor, then double
click on convertmyloco.bat to convert the loco.
Let's
copy some more temporary files into the myloco
directory. From the GP38 directory, copy gp38.eng,
gp38.sd, the Cabview folder and the Sound folder
to the myloco directory.
In later
tutorials we'll learn how to alias the Sound and Cabview folders
so we won't have to copy them.
Also,
from the Dash9 directory, copy the us2dash9.ace to the
myloco directory.
In the
myloco directory rename us2dash9.ace to us2dsh9.ace
(you are just eliminating the a in the name. )
Also,
in the myloco directory, rename gp38.eng to myloco.eng
and rename gp38.sd to myloco.sd
To make
the engine visible in the engine lists as well as the consist editor,
we'll have to do some editing to the .eng and .sd
files.
Let's
edit the .eng first. Use Wordpad to open the myloco.eng.
When you open the file, in the first several lines, change gp38
to myloco (see the example below - but don't copy and paste
from the example below)
Wagon
( myloco
..............Type
( Engine )
..............WagonShape
( myloco.s )
Also,
use Find(under Edit in Wordpad) to search for this
Wagon ( GP38 ) and change to Wagon ( myloco )
Use Find
again for this Engine ( gp38 and change to Engine ( myloco
And finally,
use Find to search for ("GP38-2") and change it to
("My First Loco")
Save
the file now. MSTS will now recognise our new loco.
Open
myloco.sd in WordPad. Change
shape
(Gp38.s in the first line to shape ( myloco.s
Save
this file now. The .sd file contains information about the bounding
box of our new locomotive. This bounding box size is important for
detecting coupling.
One last
thing, we need to make a consist for our new loco. We could
do this in the consist editor, but we'll do it manually this
time.
Go to
the Microsoft Train Simulator root directory. Go to the TRAINS
directory. Go to the CONSISTS directory.
Let's
make a copy of an existing consist. Right-click on
and drag the file, gp38-2 lumber.con . Let the mouse
button go and select Copy Here in the pop-up menu.
Rename
the file, Copy of gp38-2 lumber.con to myloco lumber.con
Open
the myloco lumber.con in Wordpad.
Change
this TrainCfg ( "GP38-2 lumber" to this TrainCfg ( "myloco
lumber"
Also
look down about 7 lines and
change
this EngineData ( GP38 GP38 ) to this EngineData ( myloco
myloco ) Save this file now. Our new loco should now be selectable
in MSTS in any explore route.
Go ahead
and run MSTS. Go to the Locomotive drop-down list.
Scroll down to where the M's are and look for My First Loco
and go ahead and run your new engine!!!
Part
three of this tutorial will concentrate on creating our own bogies
and wheels as well as giving our engine an interior. We'll also
customize the engine physics a little bit more.
Also,
We'd like to make a special request - If you find these tutorials
are useful and you end up making locomotives and posting them so
others can use them, please direct people, in your post to www.trainartisan.com
This
isn't really for credit so much as, if people look at your work
and like it, they might want to try creating a locomotive too -
show them where to get the info. We make these tutorials because
we want to share - help us in sharing this knowledge with others!
Thanks,
from the Trainartisan team.
|