• 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!

Included in Build New PotC Film Navy Characters

Question @Andouce about this section of code:
Code:
  if (GetMySimpleName(PChar) == "James Norrington")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if (pchar.model == "Groves_EITC")
   {
     GiveModel2Player("Eitc_lt3_47",false);
     GiveModel2Player("Eitc_lt2_47",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if (pchar.model == "GrovesCpt_EITC")
   {
     GiveModel2Player("Eitc_lt3_47",false);
     GiveModel2Player("Eitc_lt2_47",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if (pchar.model == "Groves")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if (pchar.model == "GrovesCpt")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if (pchar.model == "GrovesC")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if (pchar.model == "GrovesA")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }

   if  (pchar.model == "Gillette")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }
   if (pchar.model == "GilletteCpt")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }
   if (pchar.model == "GilletteC")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }
   if (pchar.model == "GilletteA")
   {
     GiveModel2Player("brtlut3_18",false);
     GiveModel2Player("brtlut2_18",false);
     GiveModel2Player("brtlut1_18",false);
     GiveModel2Player("brtmds1_18",false);
     GiveModel2Player("brtmds2_18",false);
     GiveModel2Player("brtmds3_18",false);
     GiveModel2Player("brtmds4_18",false);
     GiveModel2Player("brtoffic18",false);
     GiveModel2Player("BrtSol18_2",false);
     GiveModel2Player("BrtSol18_5",false);
   }
What is your intention with that?
I wonder if the same can be accomplished with some simplified code.
For example, by giving ALL navy uniforms to ALL navy players so they can change hired officers into apparent navy ones?
We can use HasSubStr(pchar.model, "EITC") to give additional EITC models to those characters.

Also, sections of code like this:
Code:
    if (pchar.model == "Groves")
           {
           PlayerModel = "GrovesCpt";
           }
           if (pchar.model == "Gillette")
           {
           PlayerModel = "GilletteCpt";
           }
           if (pchar.model == "Groves_EITC")
           {
           PlayerModel = "GrovesCpt_EITC";
           }
Are much shorter like this:
Code:
          switch(pchar.model)
           {
             case "Groves":     PlayerModel = "GrovesCpt";   break;
             case "Gillette":   PlayerModel = "GilletteCpt";   break;
             case "Groves_EITC":   PlayerModel = "GrovesCpt_EITC";   break;
           }
:doff

For the model-changes, this should work as well and fits in a bit better with the code that is already there:
Code:
        case 6: // Post Captain
           switch(GetMySimpleName(PChar))
           {
             case "Jack Sparrow":
               PlayerModel = "47_Cptsparrow";
             break;
             case "James Norrington":
               PlayerModel = "Cpnorrington";
             break;
             case "Andrew Gillette":
               PlayerModel = "GilletteCpt";
             break;
             case "Theodore Groves":
               if (PChar.model == "Groves")   PlayerModel = "GrovesCpt";
               else               PlayerModel = "GrovesCpt_EITC";
             break;
See attached for some suggestions of mine. :doff


By all means use the easier code haha. I never could get the game to load but that is me!

My intention for that part in the storyline.c was basically for them however. I think it could be expanded so basically when you reach the appropriate naval rank, you receive all the uniforms of that rank as opposed to one random one. As for the soldier uniforms I think you should receive them when you reach lieutenant perhaps. It could be added to the promotion in NK.c as opposed to in where it is.

Please by all means implement this.....please :p
 
Right back at you. I like the idea and should be fairly easy to do.
But I'm not going to be doing it. There's plenty enough to be done by me as it is! :shock

Okay well if it isn't already done. I shall correct it all. And also, Ignore the download link I provided for the time being then until I update it all :D

EDIT:

@Pieter Boelen - In regards to the section of code for adding the naval uniforms to corresponding ranks I shall add it in my B15 suggestions list. It would have to tie to the period too in order so it gives you the correct matching uniforms etc for said nation.

I shall leave that section out of this for now.
 
Last edited:
@Pieter Boelen - In regards to the section of code for adding the naval uniforms to corresponding ranks I shall add it in my B15 suggestions list. It would have to tie to the period too in order so it gives you the correct matching uniforms etc for said nation.
Just a simple line like this would solve that:
Code:
if(GetCurrentPeriod() >= PERIOD_COLONIAL_POWERS)
There are no period-specific navy uniforms anyway. They're either active or not.

Soldier uniforms might be a bit more tricky. Not sure why you'd need them though.
Boarding and shore crew automatically gets soldier outfits for navy officers anyway.

Also, don't forget that you can buy all of this stuff from the tailor shops anyway.
So if you want it, you can get it. That is already in place. That is certainly good enough for me. :shrug
 
Just a simple line like this would solve that:
Code:
if(GetCurrentPeriod() >= PERIOD_COLONIAL_POWERS)
There are no period-specific navy uniforms anyway. They're either active or not.

Soldier uniforms might be a bit more tricky. Not sure why you'd need them though.
Boarding and shore crew automatically gets soldier outfits for navy officers anyway.

Also, don't forget that you can buy all of this stuff from the tailor shops anyway.
So if you want it, you can get it. That is already in place. That is certainly good enough for me. :shrug

Yes I agree. I think I will leave the soldier part out of the equation because as you say, the soldiers are already active with Naval Officers, plus the tailor is there to outfit your officers so to speak. One thing though I must admit I do like is the enemy boarders. For example, usually there is an "Officer" so to speak on each deck when you are boarding who is fighting alongside the standard soldiers. Perhaps the player could have the same models as stated in the Nations file? (rnation.boardingmodel.enemy)

Is that possible? I will add that to B15 suggestions. The last post can be scrapped because It is void now. I shall do the naval uniforms given on each rank.

Will look like this:

3. Lieutenant - All 2.midshipman equivalent uniforms
4. Senior Lieutenant - All 3.Lieutenant equivalent uniforms
7. Commodore - All 6. Captain equivalent uniforms
10. Admiral - All 7. Commodore equivalent uniforms
11. Admiral of the Fleet - All 10. Admiral equivalent uniforms.
 
At some point the boardermodel code has to be completely rewritten as it is quite a mess.
But not now. Better leave that as-is.

Your shore crew and deck crew are easier to change.
 
I've got your work adapted into my game now.
You'll have to check the implementation when I post the next update to make sure it fits with your intentions.

All your added characters are available as part of the "Named" character selection.
For the default "Specific" characters, I would like to stick to a maximum of three English naval officers; that is already far more than any of the other countries get.
In fact, I disabled the "Specific" status of the "Josiah Peabody" character I added in favour of @Grey Roger's John Paul Jones too.
Just to avoid apparent "navy officer overkill".... :oops:

Right now the choices are: Lieutenant Norrington, Post Captain Aubrey and Lieutenant (again) Nelson.
For variety though, we could change that first one to Midshipman Norrington. Then at least it'll be three different starting ranks.
I'll leave that choice up to you. :doff
 
I've got your work adapted into my game now.
You'll have to check the implementation when I post the next update to make sure it fits with your intentions.

All your added characters are available as part of the "Named" character selection.
For the default "Specific" characters, I would like to stick to a maximum of three English naval officers; that is already far more than any of the other countries get.
In fact, I disabled the "Specific" status of the "Josiah Peabody" character I added in favour of @Grey Roger's John Paul Jones too.
Just to avoid apparent "navy officer overkill".... :oops:

Right now the choices are: Lieutenant Norrington, Post Captain Aubrey and Lieutenant (again) Nelson.
For variety though, we could change that first one to Midshipman Norrington. Then at least it'll be three different starting ranks.
I'll leave that choice up to you. :doff

I like that at the moment. Named characters make sense. I kind of like Norrington as a Lieutenant at the moment. But up to you! :D

Well in that case, I will just wait for the next update and I will then start sorting anything that needs sorted lol. At the moment I have no idea what has been adjusted to our agreed things and what hasn't so I shall wait :p
 
The version of this work currently in the modpack is a bit of a simplification.
@Andouce still needs to check that it distinguishes properly between the EITC and navy versions of several characters (I don't think it currently does).

I also left out the entire "giving sets of uniforms to the player" since those are available for purchase from the Tailor Shops.
Your rank should unlock them as you cannot get them at the start of the game.
 
The version of this work currently in the modpack is a bit of a simplification.
@Andouce still needs to check that it distinguishes properly between the EITC and navy versions of several characters (I don't think it currently does).

I also left out the entire "giving sets of uniforms to the player" since those are available for purchase from the Tailor Shops.
Your rank should unlock them as you cannot get them at the start of the game.

If i get time to do a proper test then it shall be done but recently I have been tied up quite a bit :(
 
Two things still to be done for this:
- The portraits should be redone to get the correct borders and no skewed aspect ratio. Might @Jack Rackham see any chance to do that?
- The functionality need to be checked to ensure that the code distinguishes properly between EITC and navy variations on these officers. This really needs to be done by @Andouce
 
Done! I also noticed that a lot of other portraits (mostly mine) we're not ok so I fixed them too.
 
Done! I also noticed that a lot of other portraits (mostly mine) we're not ok so I fixed them too.
Thanks a lot! That's definitely much better. :woot

The aspect ratio on some of those navy officers does still look "off" to me?
Do you see that too or is it just me? :confused:
 
Back
Top