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 -
case "kill_pirate":
minclass = 7; //We won't encounter pirates in a dinghy
maxclass = 2; //Let's just see how this will turn out :).
GenerateQuestShip("Quest pirate", maxclass, minclass, iNation); // PB: Use Generic Function
if(sti(rCaptain.nation) == PIRATE && maxclass < MAXPIRATECLASS) maxclass = MAXPIRATECLASS;
if(HasSubStr(character_id,"Coastal_Captain") && maxclass < MAXCOASTGUARDCLASS) maxclass = MAXCOASTGUARDCLASS;
if(GetCurrentPeriod() <= PERIOD_EARLY_EXPLORERS || GetCurrentPeriod() >= PERIOD_NAPOLEONIC)
{
if(iNation == HOLLAND && maxclass < 3) maxclass = 3;
if(iNation == PORTUGAL && maxclass < 3) maxclass = 3;
}
int GetCoastGuardShipMaxClass()
{
ref pchar = getMainCharacter();
ref sIsland = GetIslandByIndex(sti(pchar.quest.Contraband.islandindex));
int sState = getSmugglingState(sIsland); //state can be between 0 and 4
//the minclass of the coastguard ships will be 6 so they are a bit challenging. We just substract the smuggling state from 5 to get the max class.
//this way you have a higher chance of higher ships on a higher state
return 5-sState;
}
@Levis: I don't have time to check everything, so these are just some short, random comments:
There was a desire from some players for Tier 1 ships to show up as well, so you may want to consider changing this to 'maxclass = 1'.Code:case "kill_pirate": minclass = 7; //We won't encounter pirates in a dinghy maxclass = 2; //Let's just see how this will turn out :). GenerateQuestShip("Quest pirate", maxclass, minclass, iNation); // PB: Use Generic Function
Oh right I misread it a bit... I agree it should be in force_getShipType. Will add that in the next update I'm going to make. For now it will just default to something else if this is the case.This whole section is now commented out and, as far as I can tell, it is not replicated elsewhere.Code:if(sti(rCaptain.nation) == PIRATE && maxclass < MAXPIRATECLASS) maxclass = MAXPIRATECLASS; if(HasSubStr(character_id,"Coastal_Captain") && maxclass < MAXCOASTGUARDCLASS) maxclass = MAXCOASTGUARDCLASS; if(GetCurrentPeriod() <= PERIOD_EARLY_EXPLORERS || GetCurrentPeriod() >= PERIOD_NAPOLEONIC) { if(iNation == HOLLAND && maxclass < 3) maxclass = 3; if(iNation == PORTUGAL && maxclass < 3) maxclass = 3; }
These are important to keep though, since ships exceeding those tiers for those nations simply don't exist,
so the game would end up searching for something that isn't there to be found.
I think both the pirate and the Holland/Portugal period check could be included in the 'Force_GetShipType' function itself.
Then at least it would only be in one central spot.
NopeIs the 'MAXCOASTGUARDCLASS' variable still used at all?Code:int GetCoastGuardShipMaxClass() { ref pchar = getMainCharacter(); ref sIsland = GetIslandByIndex(sti(pchar.quest.Contraband.islandindex)); int sState = getSmugglingState(sIsland); //state can be between 0 and 4 //the minclass of the coastguard ships will be 6 so they are a bit challenging. We just substract the smuggling state from 5 to get the max class. //this way you have a higher chance of higher ships on a higher state return 5-sState; }
In that case, the bug from the opening post remains.Oh right I misread it a bit... I agree it should be in force_getShipType. Will add that in the next update I'm going to make. For now it will just default to something else if this is the case.
if(sti(rCaptain.nation) == PIRATE && maxclass < MAXPIRATECLASS) maxclass = MAXPIRATECLASS;
if(HasSubStr(captain_id,"Coastal_Captain") && maxclass < MAXCOASTGUARDCLASS) maxclass = MAXCOASTGUARDCLASS;
if(GetCurrentPeriod() <= PERIOD_EARLY_EXPLORERS || GetCurrentPeriod() >= PERIOD_NAPOLEONIC)
{
if(iNation == HOLLAND && maxclass < 3) maxclass = 3;
if(iNation == PORTUGAL && maxclass < 3) maxclass = 3;
}
if(minclass > 8) minclass = 8;
minclass = round( 8.0 * ( 1.0 - ( makefloat(GetRank(pchar, iNation)) / makefloat(GetNationRankQuantity(iNation)) ) ) ); //Depending on your rank you will get less easy challenges
maxclass = 1; //Let's just see how this will turn out :).
GenerateQuestShip("Quest pirate", maxclass, minclass, iNation); // PB: Use Generic Function
should be ....I thought we wanted to put that Holland/Portugal/Pirate check inside 'Force_GetShipType' instead?
That should be quite easy to do, right?
Yesterday I saw that "Force_GetShipType" message again, in the pirate leaders quest.@ANSEL Did you do any ship hunting quests? I believe we can call this fixed right?
If you see it again, could you please post your compile.log file?Yesterday I saw that "Force_GetShipType" message again, in the pirate leaders quest.
I think that's not a problem. Just the game code being "a bit too proactive".Playing as a pirate I stumbled over this:
ItemLogic -> randItem draw: no model for item Pirate_Fort.smugglingbook2?
This is probably the reason for the messages @ANSEL seesIn maximus function file, there is a generation of ship for pirates that places a max class at 3, when pirates only have at most a max class of tier 4.
Suggest either changing to 4, or changing to the internal settings define for max pirate class:
MAXPIRATECLASS
Here is the one to be changed:
GenerateQuestShip("Treasure Pirate", 6, 3, PIRATE); // PB: Use Generic Function //Levis: The pirate you'll encounter wont be the best ever but could be quit challenging untill late game. TODO: Maybe add a loop here so more pirates can be generated if you are really unlucky