View Single Post
Old 12-05-18, 11:02 AM   #89
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,214
Downloads: 793
Uploads: 10
Default

Interesting thread Jeff, I am following it

Quote:
Originally Posted by ArnoldR View Post
Thank you for the reply! So,you mean that both ships (original and cloned) are exactly the same (AA guns, hitpoints.....), except for the texture?
I don't have SH4, could you send me the files, or show me a screenshot?
This is an example taken from SH5, but it works the same in SHIV and probably also in SHIII (never tried in the latter game but I trust what Jeff says )

File: data\Sea\NAMC_Patroclus\NAMC_Patroclus.cfg:


Code:
[Unit]
ClassName=AMCPatroclus
3DModelFileName=data/Sea/NAMC_Rawalpindi/NAMC_Rawalpindi
UnitType=13
MaxSpeed=15
Length=165.89
Width=21.39
Mast=39.69
Draft=9.00
Displacement=11198
DisplacementVariation=10
RenownAwarded=220
CrewComplement=40
SurvivalRate=70
SurvivalPercentage=40
RecManualCategory=TroopTransport
BowShape=Plumb
Funnels=2
ShowInRecognitionManual=No;it is a clone. the player will identify it as another single ship
;*********** THE END ************
Note the line marked in orange: the Patroclus has not 3D model of her own, but her cfg file is pointing to Rawalpindi 3D model (dat file, or gr2 file in this case, since we are talking about SH5).

Other files found in the same folder (besides the above cfg file):

NAMC_Patroclus_sil.dds
NAMC_Patroclus.eqp
NAMC_Patroclus.sns

All other (sim, zon, val, dsd, etc.) files are shared with the Rawalpindi. The two ships have most features in common, but textures, armaments and sensor outfits can be customized.

The external look of two ships having the same 3D model can be customized as well, to some extent: all you need to do is removing parts you want to customize from the main model, edit them in two or more variants, and storing them in an external library file whose content can be linked to the units sharing the said model through equipemnt nodes/bones and .eqp files. There are not examples of this type of advanced technique in stock SH5, but there is at least one in SHIV.

In general, this method is very useful for dealing with sister ships, similar ship classes and aircraft variants. We refer to it as "proxy-cloning" as opposed to simple "cloning" where you duplicate an unit with all her binary files
__________________
_____________________
|May the Force be with you!|
...\/
gap is offline   Reply With Quote