Code:
GiveShip2Character(pchar,"*SHIP ID*","*SHIP NAME*",-1,SPAIN,true,true);
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!
Quick links for Beyond New Horizons
- Download latest version
- Wiki
- FAQ
- Report bugs here
- Bug Tracker on Github
Quick links for Maelstrom
- Download the latest version of Maelstrom
- Download the latest version of ERAS II
- Download the latest version of New Horizons on Maelstrom
Quick links for PotC: New Horizons
- Download latest version
- Wiki
- FAQ
- Report bugs here
Thanks to YOUR votes, GOG.com now sells:
- Sea Dogs
- Sea Dogs: Caribbean Tales
- Sea Dogs: City of Abandoned Ships
Vote now to add Pirates of the Caribbean to the list!
Quick links for AoP2: Gentlemen of Fortune 2
- Downloads and info
- ModDB Profile
- Forums Archive
A Pirate Podcast with Interviews
Music, Comedy and all things Pirate!
- Episode Guide - About - Subscribe -
- Twitter - Facebook - iTunes - Android -
- Youtube - Fill the Coffers -
GiveShip2Character(pchar,"*SHIP ID*","*SHIP NAME*",-1,SPAIN,true,true);
switch(GetAttribute(pchar,"model"))
{
case "cnorrington": GiveModel2Player("Mdnorrington", true); break; // Norrington is promoted to higher-level Norrington
case "blaze": GiveModel2Player("47_Blaze_brtmds", true); break; // Nathaniel Hawk is promoted to higher-level Nathaniel
switch(rand(2)) // Any other character gets a random model upon promotion
{
case 0: GiveModel2Player("rn_mdshp18_1", true); break;
case 1: GiveModel2Player("rn_mdshp18_2", true); break;
case 2: GiveModel2Player("rn_mdshp18_3", true); break;
}
}
switch(GetAttribute(pchar,"model"))
{
case "cnorrington": GiveModel2Player("Mdnorrington", true); break; // Norrington is promoted to higher-level Norrington
case "blaze": GiveModel2Player("47_Blaze_brtmds", true); break; // Nathaniel Hawk is promoted to higher-level Nathaniel
GiveModel2Player("britmds_18", false); // Any other character gets this model (this one doesn't exist???)
}
I never properly finished the code for those promotion models.
There's a lot of models and I didn't actually code them in yet,
except for the midshipmen and some character-specific ones.
If you could do that, it'd be absolutely great!
Here's a short explanation of how the code works:If you want to always give the same model upon promotion, try this:Code:switch(GetAttribute(pchar,"model")) { case "cnorrington": GiveModel2Player("Mdnorrington", true); break; // Norrington is promoted to higher-level Norrington case "blaze": GiveModel2Player("47_Blaze_brtmds", true); break; // Nathaniel Hawk is promoted to higher-level Nathaniel switch(rand(2)) // Any other character gets a random model upon promotion { case 0: GiveModel2Player("rn_mdshp18_1", true); break; case 1: GiveModel2Player("rn_mdshp18_2", true); break; case 2: GiveModel2Player("rn_mdshp18_3", true); break; } }
Code:switch(GetAttribute(pchar,"model")) { case "cnorrington": GiveModel2Player("Mdnorrington", true); break; // Norrington is promoted to higher-level Norrington case "blaze": GiveModel2Player("47_Blaze_brtmds", true); break; // Nathaniel Hawk is promoted to higher-level Nathaniel GiveModel2Player("britmds_18", false); // Any other character gets this model (this one doesn't exist???) }
case 1: // Midshipman
switch(GetAttribute(pchar,"model"))
{
case "cnorrington": GiveModel2Player("Mdnorrington", true); break;
case "blaze": GiveModel2Player("47_Blaze_brtmds", true); break;
switch(rand(3))
{
case 0: GiveModel2Player("brtmds1_18", true); break;
case 1: GiveModel2Player("brtmds2_18", true); break;
case 2: GiveModel2Player("brtmds3_18", true); break;
case 3: GiveModel2Player("brtmds4_18", true); break;
}
}
You mean?Code:case 1: // Midshipman switch(GetAttribute(pchar,"model")) { case "cnorrington": GiveModel2Player("Mdnorrington", true); break; case "blaze": GiveModel2Player("47_Blaze_brtmds", true); break; switch(rand(3)) { case 0: GiveModel2Player("brtmds1_18", true); break; case 1: GiveModel2Player("brtmds2_18", true); break; case 2: GiveModel2Player("brtmds3_18", true); break; case 3: GiveModel2Player("brtmds4_18", true); break; } }
If you put /* */ around a section of code it makes that code NOT HAPPEN!
The switch (rand(3)) would get a random number between 0 and 3, and then would make that case happen (eg if random number is 2 then you would be given "brtmds3_18")...
It only does this random number if:
a) your character model isnt cnorrington
b) your character model isnt blaze
Nations[ENGLAND].fantomModel.m1
GiveModel2Player(Nations[ENGLAND].fantomModel.m1, true);
This line of code will give you the soldier models for era your inOf course ENGLAND needs to be changed depending on nation and the number at the end is a number between 1-6 (for all 6 period model uniforms)Code:Nations[ENGLAND].fantomModel.m1
Also when doing the code it isso no "" around the model nameCode:GiveModel2Player(Nations[ENGLAND].fantomModel.m1, true);
The Holland officers are: Offic_Hol_*per* and the same for Portugal but Offic_Pol_*per* (I dont think all periods are there for them though and that is just the basic officers not Admiral or anything)![]()
GiveModel2Player(Nations[ENGLAND].fantomModel.m1, true);
You dont, there is a bit of code set up that the statement I just gave you will get model 1 for ENGLAND in ANY period, you change the 1 to any number between 1-6 to get the other models for that period
I dont have a clue Im afraid
The ship part is already more-or-less done with the shipyards.
You can only buy high-class navy vessels if you've got the correct navy rank.
If you want to actually GIVE to the player, you'll need to mess around with the dialog code.
Not too difficult, but personally I'm more interested in the model-assignment code being finished.
Be sure to upload your work once you're on a point you're happy with.
And thanks a lot for working on this. Definitly a good job after two days of coding.![]()
Ill add you to group "modders" which gives you a lot more attachment size
Correct me if Im wrong but I thought when you became a officer for a nation it automatically gave your crew there soldier uniform? :?
Characters[GetCharacterIndex("Crewmember_01")].model = Nations[ENGLAND].fantomModel.m1;
Characters[GetCharacterIndex("Crewmember_01")].headmodel = Nations[ENGLAND].fantomModel.m1;
Characters[GetCharacterIndex("Crewmember_03")].model = Nations[ENGLAND].fantomModel.m3;
Characters[GetCharacterIndex("Crewmember_03")].headmodel = Nations[ENGLAND].fantomModel.m3;
Characters[GetCharacterIndex("Crewmember_04")].model = Nations[ENGLAND].fantomModel.m4;
Characters[GetCharacterIndex("Crewmember_04")].headmodel = Nations[ENGLAND].fantomModel.m4;
Characters[GetCharacterIndex("Crewmember_05")].model = Nations[ENGLAND].fantomModel.m5;
Characters[GetCharacterIndex("Crewmember_05")].headmodel = Nations[ENGLAND].fantomModel.m5;
pchar.boardingmodels = "Soldiers"; //change the boarding model in fights
I can think of a way to make it so that your crewman get the uniform by default, which I think is probably a better way to handle it as then it doesnt clutter up your outfit menu
The code needed to pull it off is justCode:Characters[GetCharacterIndex("Crewmember_01")].model = Nations[ENGLAND].fantomModel.m1; Characters[GetCharacterIndex("Crewmember_01")].headmodel = Nations[ENGLAND].fantomModel.m1; Characters[GetCharacterIndex("Crewmember_03")].model = Nations[ENGLAND].fantomModel.m3; Characters[GetCharacterIndex("Crewmember_03")].headmodel = Nations[ENGLAND].fantomModel.m3; Characters[GetCharacterIndex("Crewmember_04")].model = Nations[ENGLAND].fantomModel.m4; Characters[GetCharacterIndex("Crewmember_04")].headmodel = Nations[ENGLAND].fantomModel.m4; Characters[GetCharacterIndex("Crewmember_05")].model = Nations[ENGLAND].fantomModel.m5; Characters[GetCharacterIndex("Crewmember_05")].headmodel = Nations[ENGLAND].fantomModel.m5; pchar.boardingmodels = "Soldiers"; //change the boarding model in fights
Well then the boarding models isnt "soldiers" its something else then. What about changing your crew though :wacko:Sorry bout the double post but iv had to fix afew minor things, should be fine now.
all that code did was change the crew models when boardin a ship and attackin a fort into nathan hawks lol prity funny watchin 6 nathan hawks runnin around. maybe i didnt put it in the right place or somethin, i placed it in the midshipman section of the NK. from what i can tell tho this code is supost to do the same thing the Boardin advanced options does all ready so i dont think there is any point tryin to work it in
switch(GetAttribute(pchar,"model"))
You do know that your code does need to include theat the top before you add the casesCode:switch(GetAttribute(pchar,"model"))
![]()