View Single Post
Old 03-23-10, 04:33 PM   #2
keltos01
Silent Hunter
 
Join Date: Feb 2008
Location: Milan Italy
Posts: 4,999
Downloads: 114
Uploads: 18
Default

[QUOTE=peabody;1330657]If you need help, let us know, I'm sure there are several that would be available including myself.

Since you are familiar with some of this I will try a condensed version.

Set up a folder to make a MOD with Data folder inside. And I will list the files you need.

1. Find a sub that is similar in number of tubes, guns etc so it will be that much easier to do. I'll use Porpoise, you can follow the directions using any other sub. Create the same folder structure as where the files come from.

2. Data/Submarine/NSS_Porpoise....copy the entire folder.
3. Data/Roster/American/Submarine/SSPorpoise.cfg
4, Data/Menu/Data/SubmarineClasses/P_Class_01.dds
5. Data/UPCData/UPCUnitsData/Unitparts2Porpoise.upc
6. Data/Objects/Conning_P_01.dat, .sim, .val, .cam, .zon

That should do it for copying files.

Now editing:

One major thing to remember is the classname must match in each file they are in.

Start with Data/Roster/American/Submarine/SSPorpoise.cfg change the filename to SSCachalot.cfg

[UnitClass]
ClassName=SSCachalot Very Important
UnitType=200 200=submarine, leave it
AppearanceDate=19350815 change if necessary
DisappearanceDate=19451115
DisplayName=US Cachalot Change

[Texture 1]
TextureName=data/Submarine/NSS_Cachalot/NSS_Cachalotclass_T01.tga
LightmapTextureName=data/Submarine/NSS_Cachalot/NSS_Cachalot_O01.tga
StartDate=19350815
EndDate=19430512
Frequency=1

Change the info in green and continue if there is a second texture, reset dates as needed.
Below this is the names used for the subs in that class, you can have one or as many as you want.
[Unit 1]
Name=USS MYboat
DOC=19350815
DOD=19451115

[Unit 2]
Name=USS Pike
DOC=19351202
DOD=19451115

************************************************** *******
I have to leave for a while, will complete when I return
************************************************** ***

Ok, let's go to the Data/Menu/Data/SubmarineClasses/P_Class_01.dds
Change to Cachalot_Class_01.dds Later you can change the actual .dds image.

************************************************** ******
Next: Data/UPCData/UPCUnitsData/Unitparts2Porpoise.upc

change to Unitparts8Cachalot.upc You not only have to change the name you also have to change the number to the next number in line. Since the stock game has 7 I am using 8. NOTE: if you have other subs in there and get to high, 1 and 10 will conflict with each other so one sub will not have a tower.
Open the Unitparts8Cachalot.upc with notepad:

[UnitPart 1]
ID=CachalotClassConningEarlyWar
Type= CachalotClassConningTower
NameDisplayable= Start of war Conning Tower
UnitPartInterval=NULL, NULL
ExternalLinkName3D= data/objects/Conning_Cachalot_01
HullTextureNameOverride=data/Submarine/NSS_Cachalot/NSS_Cachalotclass_T01.tga
HullLightmapTextureNameOverride=data/Submarine/NSS_Cachalot/NSS_Cachalotclass_O01.tga
HullNormalmapTextureNameOverride= NULL
MenuSilhouetteTextureNameOverride= Cachalot_Class_01.tga

change the Porpoise and P to Cachalot.

Below that will be Compartments, you can rename the compartments ID using
Cachalot instead of Porpoise
[UnitPart 1.Compartment 1]
CompartmentType= 1
StatusActive= Yes
ID= CachalotConnWatch

This file may contain more than one tower, which the Porpoise does. If your tower will not change then delete the other towers which will be [UnitPart 2] etc.

************************************************** *************
Now Data/Objects/Conning_P_01.dat, .sim, .val, .cam, .zon
change filenames as before, replace the P with Cachalot for each file.

Now you need S3D.

1. Open the Conning_Cachalot_01.dat
2. Using the button at the top open the .sim, .val, .cam .zon on top of each other.
3. If we don't change the IDs of these entries they could conflict with others so we will remap them.
4. Go to the Menu/Tools/RemapIDs a window opens.
5. Click the "Random" button....only this one time DO NOT CLICK THE RANDOM BUTTON AGAIN.
6. Click OK
7. File SAVE
8. File Close
9. Now the .zon file will close and you are at another window.
10. Select Tools/RemapIDs DO NOT CLICK RANDOM.
11. Click OK
12 File Save
14 File close
repeat for each of the windows then close S3D. Remember ONLY CLICK RANDOM ON THE FIRST WINDOW.

************************************************** ****************
Now to Data/Submarine/NSS_Porpoise
Change the folder name. Then go inside and change the filenames.

Now since you just did it for the tower, we will do the .dat, .sim, .zon, .val, .cam, .dsd. Notice there is one more here the .dsd. It contains the sounds so you do not need it in the tower also.

Open .dat then use the buttons at the top right and open all of them.
1. Tools/RemapIds
2. Click Random
3 Click OK
4. File Save
5. File Close
6. Tools/RemapIDs
7. Do NOT click Random
8. Click OK
9. File Save
10. File close
Rinse and Repeat....Remembering to only click random the first time.
When you are done, close S3D.

Open the NSS_
Cachalot.cfg.

[Unit]
ClassName=SS
Cachalot
3DModelFileName=data/Submarine/NSS_Cachalot/NSS_Cachalot
HumanPlayable=YES
Interior=data/Interior/NSS_Porpoise/NSS_Porpoise
UnitType=200
MaxSpeed=19
MaxSpeedSubmerged=8
Length=91.7448
Width=7.601
RenownAwarded=130

Do not change the Interior since there is no Cachalot interior.

Change any necessary data. As you go down you will find data such as Surface depth and others. Remember that is in there since it will be in the Cachalot.sim file also, so they should match.

Save

Open the NSS_Cachalot.upc with notepad.

[UserPlayerUnit 1]
ID=Porpoise
NameDisplayable=Porpoise
UnitName= USS Porpoise
Type=Porpoise
UpgradeClass=1
UnitInterval= 1935-08-15, 1945-11-15
ExternalClassName=SSPorpoise
Nationality=American
CrewRanks=12
Evolution= Normal
Damage= 0
TextureName=data/Submarine/NSS_Porpoise/NSS_Pclass_T01.tga
LightmapTextureName=data/Submarine/NSS_Porpoise/NSS_Pclass_O01.tga
NormalmapTextureName= NULL
MenuSilhouetteTextureName= P_Class_01.tga

[UserPlayerUnit 1.UnitPartSlot 1]
ID=PorpoiseConningSlot
NameDisplayable=Conning Tower Slot
Type=NULL
AcceptedTypes=PClassConningTower
IDLinkUnitPartIntervalDefault1= NULL, 1942-07-31, PClassConningEarlyWar
IDLinkUnitPartIntervalDefault2= 1942-08-01, 1943-05-31, PClassConningHalfCut
IDLinkUnitPartIntervalDefault3= 1943-06-01, NULL, PClassConningLateWar

ExternalNodeName3D= Z01

Again change the names of Porpoise and P to Cachalot.

Notice the UnitPartSlot 1 is the tower and there are three listed with dates. If your sub only has one then delete the other two or put semicolons ; in front of the line so the computer will ignore them. (marked in yellow above)

Now you can continue down to the "Compartments" and change the IDs like you did in the tower.

[UserPlayerUnit 1.Compartment 1]
CompartmentType= 1
StatusActive= Yes
ID= CachalotSternTorpedo

Now if I didn't mess something up, you should have a working sub. Then you can go to the subs .dat file and put in your 3D model, and make other changes that may be necessary. Before doing any more changes though, enable the MOD and see if it works at least in a single mission.

The info Keltos gave here below shows how to add it to the Campaign.

Peabody
__________________
"Honorable Builder of Sinking Ships"


Last edited by keltos01; 03-24-10 at 08:23 AM.
keltos01 is offline   Reply With Quote