• New Horizons on Maelstrom
    Maelstrom New Horizons


    Visit our website www.piratehorizons.com to quickly find download links for the newest versions of our New Horizons mods Beyond New Horizons and Maelstrom New Horizons!

creating new ship status help!!!

Well, if you have skin, I assume that you took a model from RESOURCE\TEXTURES\SHIPS\ directory and simply repainted (reskined) existing ship. To place her in game you should make a copy of directory from RESOURCE\MODELS\SHIPS and name that directory as the unique model name in the game (i.e. let we name it for purpose 'frigate4'), as well as rename all parts containg previous name of files present there to name of your model (ie. 'frigate1.gm' to 'frigate4.gm', 'frigate1_mast1.gm' to 'frigate4_mast1.gm' and so on). Then, you should edit file RESOURCE\MODELS\SHIPS\frigate4\frigate4.gm file with a HEX editor and replace name of previous .tga.tx file from RESOURCE\TEXTURES\SHIPS\ to your texture file, but your name <i>must</i> have exactly the same length (for instance, if you modified file RESOURCE\TEXTURES\SHIPS\bortoutfrigate1.tga.tx, you should put that file in directory RESOURCE\TEXTURES\SHIPS\ under name bortoutfrigate4.tga.tx - you must find text 'bortoutfrigate1.tga' in said HEX editor and overwrite that text with 'bortoutfrigate4.tga'). The last thing to do is to open file PROGRAM\SHIPS\ships_init.c and add entry for that ship after last one, but <i>above</i> line with text:
<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec--> //---DO NOT ADD BELOW THIS LINE--- <!--QuoteEnd--></div><!--QuoteEEnd--> - you can simply copy and paste entry of ship you based on and modify her stats - but don't make to much; i.e. when you didn't add or removed new locators for guns in *.gm file, don't alter refShip.CannonsQuantity attribute. However, there are changes you must do: modify refShip.Name attribute to point to your model. You should also add (or change if that attribute exist) refShip.All attribute to point to your <i>base</i> ship. I put the example here.

Original entry:
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->//-------------------------------------------------------------------------
// Frigate1
//-------------------------------------------------------------------------
    // PS -->
    makeref(refShip,ShipsTypes[n]);
    n++;
    // PS <-- makeref(refShip,ShipsTypes[SHIP_FRIGATE_FRANCE]);
    refShip.Name            = "Frigate1";
    refShip.id                = refShip.Name; // PS
    ////curid = refShip.id; ShipLookupTable.id.(curid) = n-1; // PS
    refShip.Class           = 2;
    refShip.Cannon            = CANNON_TYPE_LONG_LBS18;
    refShip.MaxCaliber        = 18;
    refShip.Weight            = Tonnes2CWT(1000);
    refShip.Capacity        = 2500;
    refShip.CannonsQuantity = 42; // KNB fix cannon qty
    // NK cannon qtys 05-04-18 -->
    refShip.Cannons.Borts.cannonf.qty = 2;
    refShip.Cannons.Borts.cannonb.qty = 4;
    // NK <--
    refShip.MaxCrew         = 400;
    refShip.MinCrew         = 80;
    refShip.SpeedRate       = 13;
    refShip.TurnRate        = 30;
    refShip.Price           = 150000;
    refShip.HP              = 6000;
    refShip.SP              = 100;
    refShip.AbordageLocation = "BOARDING_CORVETTE";

    refShip.Type.Trade = false;
    refShip.Type.War = true;

    refShip.WaterLine = 0.3;
    refShip.SpeedDependWeight = 0.3;
    refShip.SubSeaDependWeight = 1.0;
    //refShip.TurnDependWeight = 0.8;

    refShip.InertiaAccelerationX    = 0.2;    refShip.InertiaBrakingX        = 2.0;
    refShip.InertiaAccelerationY    = 10;    refShip.InertiaBrakingY        = 4;
    refShip.InertiaAccelerationZ    = 4.0;    refShip.InertiaBrakingZ        = 2.0;

    refShip.Height.Bombs.Y            = 1.0;    refShip.Height.Bombs.DY        = 0.5;
    refShip.Height.Grapes.Y            = 2.0;    refShip.Height.Grapes.DY    = 1.0;
    refShip.Height.Knippels.Y        = 10.0;    refShip.Height.Knippels.DY    = 8.0;
    refShip.Height.Balls.Y            = 1.0;    refShip.Height.Balls.DY        = 0.5;

    refShip.GeraldSails.rey_b2    = 1;
    refShip.GeraldSails.rey_b3    = 1;<!--c2--></div><!--ec2-->
Code after change:
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->//-------------------------------------------------------------------------
// Frigate4
//-------------------------------------------------------------------------
    // PS -->
    makeref(refShip,ShipsTypes[n]);
    n++;
    // PS <-- makeref(refShip,ShipsTypes[SHIP_FRIGATE_FRANCE]);
    refShip.Name            = "Frigate4";
    refShip.id                = refShip.Name; // PS
    refShip.All            = "Frigate1";
    ////curid = refShip.id; ShipLookupTable.id.(curid) = n-1; // PS
    refShip.Class           = 2;
    refShip.Cannon            = CANNON_TYPE_LONG_LBS18;
    refShip.MaxCaliber        = 18;
    refShip.Weight            = Tonnes2CWT(1000);
    refShip.Capacity        = 2500;
    refShip.CannonsQuantity = 42; // KNB fix cannon qty
    // NK cannon qtys 05-04-18 -->
    refShip.Cannons.Borts.cannonf.qty = 2;
    refShip.Cannons.Borts.cannonb.qty = 4;
    // NK <--
    refShip.MaxCrew         = 400;
    refShip.MinCrew         = 80;
    refShip.SpeedRate       = 13;
    refShip.TurnRate        = 30;
    refShip.Price           = 150000;
    refShip.HP              = 6000;
    refShip.SP              = 100;
    refShip.AbordageLocation = "BOARDING_CORVETTE";

    refShip.Type.Trade = false;
    refShip.Type.War = true;

    refShip.WaterLine = 0.3;
    refShip.SpeedDependWeight = 0.3;
    refShip.SubSeaDependWeight = 1.0;
    //refShip.TurnDependWeight = 0.8;

    refShip.InertiaAccelerationX    = 0.2;    refShip.InertiaBrakingX        = 2.0;
    refShip.InertiaAccelerationY    = 10;    refShip.InertiaBrakingY        = 4;
    refShip.InertiaAccelerationZ    = 4.0;    refShip.InertiaBrakingZ        = 2.0;

    refShip.Height.Bombs.Y            = 1.0;    refShip.Height.Bombs.DY        = 0.5;
    refShip.Height.Grapes.Y            = 2.0;    refShip.Height.Grapes.DY    = 1.0;
    refShip.Height.Knippels.Y        = 10.0;    refShip.Height.Knippels.DY    = 8.0;
    refShip.Height.Balls.Y            = 1.0;    refShip.Height.Balls.DY        = 0.5;

    refShip.GeraldSails.rey_b2    = 1;
    refShip.GeraldSails.rey_b3    = 1;<!--c2--></div><!--ec2-->

After all that changes your ship should appear in the game.

There's also a tutorial in PotC Wiki about adding ships - check pinned Modding thread and look there.

I hope I explained everything clearly - if you didn't understand something post here some more specific questions.

pirate_kk
 
Black Pearl is unique. So, the base for your ship, I think, should be lineship. Just do everything I described, but instead of frigate1 use lineship model.

If you have trouble, upload your files to PA! ftp in zip file. I'll be able download it, setup it for you and publish it back on ftp.

pirate_kk
 
Back
Top