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

Fixed Tales of a Sea Hawk: some guards remain Personal after Bridgetown is recaptured

Grey Roger

Sea Dog
Staff member
Administrator
Storm Modder
You've just captured Bridgetown and the guards now have Personal uniforms. Silehard counterattacks, you defeat his fleet and teleport to the lighthouse for a conversation with Clement and Danielle, then head off to Cozumel, while Britain moves back into Bridgetown. And when you visit Bridgetown again, several guards are still in Personal uniform. The only ones in British uniform are the ones outside the prison and the ones on the town side of the port gate.

Enclosed: savegame just after I've finished attacking Bridgetown and am about to talk to the soldier to take formal possession of the town; savegame after I've finished everything, been pardoned, and returned to Bridgetown as a reinstated British privateer; and log files.
 

Attachments

  • -=Player=- Barbados_Bridgetown_port.zip
    1 MB · Views: 87
  • -=Player=- Barbados_Town.zip
    1 MB · Views: 92
  • compile.log
    132.9 KB · Views: 86
  • error.log
    6.6 KB · Views: 101
  • system.log
    19.2 KB · Views: 102
You've just captured Bridgetown and the guards now have Personal uniforms. Silehard counterattacks, you defeat his fleet and teleport to the lighthouse for a conversation with Clement and Danielle, then head off to Cozumel, while Britain moves back into Bridgetown. And when you visit Bridgetown again, several guards are still in Personal uniform. The only ones in British uniform are the ones outside the prison and the ones on the town side of the port gate.
Possibly the way the town is captured for the player (through Capture Colonies) is not exactly the same as when it is given back to England?
Does it not use CaptureColonyForNation or something?

Enclosed: savegame just after I've finished attacking Bridgetown and am about to talk to the soldier to take formal possession of the town; savegame after I've finished everything, been pardoned, and returned to Bridgetown as a reinstated British privateer; and log files.
No attachment....
 
Now attached. There was a hiccup in which the article was posted twice, and it may be the attachments only went into the one which I then deleted. :oops:
 
Possibly the way the town is captured for the player (through Capture Colonies) is not exactly the same as when it is given back to England?
Does it not use CaptureColonyForNation or something?
It uses 'CaptureColony' to take Bridgetown for Personal, then uses 'CaptureTownForNation' to retake it for Britain. The former gives you the full credit/blame, the latter just changes the colony's nationality.

At least, that's what used to happen. I've changed the capture for Personal to also use 'CaptureTownForNation'. That's because 'CaptureColony' turns you into a pirate and makes all other nations hostile, which is very annoying if you've been building up your relations with Portugal and Holland as well. Replacing it with 'CaptureTownForNation' means you keep your standing with them. (Though I had to add a line to make sure Britain is hostile because, whether by paying a diplomat or by clobbering a pirate colony, you may have improved your relation with Britain to "Wary" by this point, and the battle with Silehard's squadron doesn't work unless you're hostile to Britain.)

So my first thought was that maybe this was what had caused the guards to keep the wrong uniforms - unlikely, but I checked it anyway. I put the line back to 'CaptureColony', reloaded that savegame where I'm about to talk to the soldier and take Bridgetown, refought the counterattack battle, then went away, made peace with Britain and came back. The same guards were still in Personal uniform. Therefore whatever differences exist between 'CaptureColony' and 'CaptureTownForNation', they're not responsible for the guards' uniforms.
 
At least, that's what used to happen. I've changed the capture for Personal to also use 'CaptureTownForNation'. That's because 'CaptureColony' turns you into a pirate and makes all other nations hostile, which is very annoying if you've been building up your relations with Portugal and Holland as well.
Is the call to that function inside the quest code? Or is it really the generic functionality?
If it is generic, then "skipRM" may be needed here (which is probably not supported right now, but should be easy enough to add).

the battle with Silehard's squadron doesn't work unless you're hostile to Britain
Hoisting a hostile flag should work regardless of your actual relations, right?

So my first thought was that maybe this was what had caused the guards to keep the wrong uniforms - unlikely, but I checked it anyway. I put the line back to 'CaptureColony', reloaded that savegame where I'm about to talk to the soldier and take Bridgetown, refought the counterattack battle, then went away, made peace with Britain and came back. The same guards were still in Personal uniform. Therefore whatever differences exist between 'CaptureColony' and 'CaptureTownForNation', they're not responsible for the guards' uniforms.
Strange; I'll have to check it. It is definitely those two functions that swap out the uniforms.
Sounds like some stuff is being set, but never reset, which should definitely not be the case. :modding

Therefore whatever differences exist between 'CaptureColony' and 'CaptureTownForNation', they're not responsible for the guards' uniforms.
The only difference should be that one of those two does more than the other one.
Quite literally, the one calls the other. But I cannot remember the differences by the top of my head.
 
Is the call to that function inside the quest code? Or is it really the generic functionality?
If it is generic, then "skipRM" may be needed here (which is probably not supported right now, but should be easy enough to add).
The call to 'CaptureColony' - or now, to 'CaptureTownForNation' - is in the quest code. That's why I was able to replace it. I did try adding the "SkipRM" attribute to Bridgetown town, which didn't have any effect, and then I realised that 'CaptureTownForNation' does what I want anyway, which is change the town's nation without blaming you for it.

Hoisting a hostile flag should work regardless of your actual relations, right?
For you, yes. Though if you're trying to play the role of a loyal British privateer who's been the victim of a treacherous governor, it feels a bit wrong to hoist a hostile flag. :bonaparteMore to the point, Danielle is sitting in the fort flying a Personal flag, and if Personal isn't hostile to Britain then she won't fire at Silehard's ships. In fact, if you hoist a flag which is hostile to Britain and probably hostile to you as well, she'll fire at you instead! (This, in fact, is how I found out I needed to change this bit. Ever since Build 12, I've bought LoM's from Britain, Holland and Portugal, then when Silehard turns nasty I switch from using a British flag to a Dutch one. That way Tomlison doesn't accuse me of being a traitor for attacking him under the same flag. The game now auto-hoists Personal before the battle, and you already know what I think about that! :D So I switched back to the Dutch flag. I hadn't noticed that capturing Bridgetown now turned me Pirate and hostile to everyone else, including Holland. Danielle noticed, though. So the fort started firing at me. At first I thought it was just bad shooting and she was hitting me because I was between the fort and the other ships, but it was too consistent, and eventually I realised why.)

Strange; I'll have to check it. It is definitely those two functions that swap out the uniforms.
Sounds like some stuff is being set, but never reset, which should definitely not be the case. :modding

The only difference should be that one of those two does more than the other one.
Quite literally, the one calls the other. But I cannot remember the differences by the top of my head.
I'd imagine that it's 'CaptureTownForNation' which switched uniforms. It has to, because it's used whenever a story has to change a colony's ownership without you being the one who did it. It's how, at your suggestion, I arranged for Isla Mona to be taken over by PIRATE in Ardent's "StartStoryline.c". "CaptureColony" presumably deals with the effects on you due to you being the one who captured the colony, then calls 'CaptureTownForNation' to do the actual nation change. Though looking at the code for "CaptureColony", that's also the one which inflicts some damage on the town.
 
The call to 'CaptureColony' - or now, to 'CaptureTownForNation' - is in the quest code. That's why I was able to replace it.
That definitely helps. :onya

I did try adding the "SkipRM" attribute to Bridgetown town, which didn't have any effect, and then I realised that 'CaptureTownForNation' does what I want anyway, which is change the town's nation without blaming you for it.
Indeed I don't think I added that exception yet. I probably should though. 5-minute job and then at least it is consistent.

There are more differences between 'CaptureColony' and 'CaptureTownForNation' if I recall, so this change may have some additional effects....

For you, yes. Though if you're trying to play the role of a loyal British privateer who's been the victim of a treacherous governor, it feels a bit wrong to hoist a hostile flag. :bonaparte
Of course getting amnesty again from England at that point is going a bit against the story.
Which doesn't mean it should be possible, but it does complicate things as you already noticed....

More to the point, Danielle is sitting in the fort flying a Personal flag, and if Personal isn't hostile to Britain then she won't fire at Silehard's ships. In fact, if you hoist a flag which is hostile to Britain and probably hostile to you as well, she'll fire at you instead!
Definitely true! So I definitely support this change, just in case. :yes

The game now auto-hoists Personal before the battle, and you already know what I think about that! :D
It does? That's not intentional on my part, that much I can tell you.
If you can get rid of that without any unintended side-effects, I don't think I'd object....

I hadn't noticed that capturing Bridgetown now turned me Pirate and hostile to everyone else, including Holland. Danielle noticed, though. So the fort started firing at me. At first I thought it was just bad shooting and she was hitting me because I was between the fort and the other ships, but it was too consistent, and eventually I realised why.
Wait a second.... Danielle is Personal and you are too and she went firing on YOU? What flag were you flying at the time? :shock

I'd imagine that it's 'CaptureTownForNation' which switched uniforms. It has to, because it's used whenever a story has to change a colony's ownership without you being the one who did it. It's how, at your suggestion, I arranged for Isla Mona to be taken over by PIRATE in Ardent's "StartStoryline.c". "CaptureColony" presumably deals with the effects on you due to you being the one who captured the colony, then calls 'CaptureTownForNation' to do the actual nation change. Though looking at the code for "CaptureColony", that's also the one which inflicts some damage on the town.
Indeed 'CaptureTownForNation' is the one that sounds the most familiar to you.
I'd need to look into it to see exactly how they work together again....
 
Indeed I don't think I added that exception yet. I probably should though. 5-minute job and then at least it is consistent.

There are more differences between 'CaptureColony' and 'CaptureTownForNation' if I recall, so this change may have some additional effects....
'CaptureColony' also inflicts damage on the colony, presumably reflecting the fact that you've just demolished its fort and rampaged through the town.

Of course getting amnesty again from England at that point is going a bit against the story.
Which doesn't mean it should be possible, but it does complicate things as you already noticed....
Who said anything about getting an amnesty? ;) Setting Britain hostile means your relation is -60. Sinking a French ship doesn't change that - in fact it doesn't seem to have any effect on your relations unless you have a LoM, e.g. if you're -45 and sink something French, you're still -45. Or in this case, -59. Because while sinking a ship doesn't affect your relations, looting Nevis Pirate Settlement does, so after I'd done that, Britain was at -59, i.e. Wary.

It does? That's not intentional on my part, that much I can tell you.
If you can get rid of that without any unintended side-effects, I don't think I'd object....
I suspect the idea was that if you've turned Pirate then the only flag Danielle won't attack is Personal. It might not be necessary to switch you to Personal now that you don't turn Pirate, but just in case someone decided that they should fly a non-Personal flag hostile to Britain while attacking the fort, and can't change it because you're not allowed to change flag except at sea, we may as well leave it. Being probably the only one with such an aversion to using a Personal flag, I'm content to put the Dutch flag back up as soon as I put to sea for the purposes of this bit of this storyline.

Wait a second.... Danielle is Personal and you are too and she went firing on YOU? What flag were you flying at the time? :shock
Dutch. ;)

Indeed 'CaptureTownForNation' is the one that sounds the most familiar to you.
I'd need to look into it to see exactly how they work together again....
"Familiar" is perhaps too strong a word. I've heard of it and know it's used to change town ownership without involving the player, and that's because I went looking for somewhere that a town is captured without involving the player and found it.
'CaptureColony' is in "Dialog_func.c". 'CaptureTownForNation' is in "Towntable.c". See attached. :doff
 

Attachments

  • Dialog_func.c
    100.7 KB · Views: 388
  • Towntable.c
    64.7 KB · Views: 123
Who said anything about getting an amnesty? ;)
How else would you get Britain to not be hostile to you at that point in the story?
They turn hostile at the same time you are forced into piracy. To make them not hostile again, you have to arrange that yourself, no?

Setting Britain hostile means your relation is -60. Sinking a French ship doesn't change that - in fact it doesn't seem to have any effect on your relations unless you have a LoM, e.g. if you're -45 and sink something French, you're still -45.
Of course if you have no LoM and England and France are not allied, then attacking French ships does nothing to your relations with Britain.
But that is normal. :shrug

Or in this case, -59. Because while sinking a ship doesn't affect your relations, looting Nevis Pirate Settlement does, so after I'd done that, Britain was at -59, i.e. Wary.
Wait, what? Looting Nevis Pirate Settlement makes Britain more hostile??? o_O

So Danielle was flying a Personal Flag and you were flying a Dutch flag, then Danielle started firing on you?
Is that because you attacked England (which was not hostile) and Holland and England were allied?
Then that attack would turn Holland hostile to you, so Danielle should be hostile to a Dutch ship. Except that WAS you.
LOL! :rofl

"Familiar" is perhaps too strong a word.
Sorry, I meant to write "me", but didn't. :facepalm
 
How else would you get Britain to not be hostile to you at that point in the story?
They turn hostile at the same time you are forced into piracy. To make them not hostile again, you have to arrange that yourself, no?
Britain is only marginally hostile. -60 is borderline so the first act which they actually notice is enough to put you back over the border.

Of course if you have no LoM and England and France are not allied, then attacking French ships does nothing to your relations with Britain.
But that is normal. :shrug
I thought the idea was that attacking an enemy ship would earn you points up to 0 but would not get you above 0. So if you're at -59 and attack an enemy ship (legally, via someone else's LoM) then you should go up to -58.

Wait, what? Looting Nevis Pirate Settlement makes Britain more hostile??? o_O
No, it turned Britain from hostile (-60) to wary (-59).

So Danielle was flying a Personal Flag and you were flying a Dutch flag, then Danielle started firing on you?
Is that because you attacked England (which was not hostile) and Holland and England were allied?
Then that attack would turn Holland hostile to you, so Danielle should be hostile to a Dutch ship. Except that WAS you.
LOL! :rofl
Pretty much. Attacking Bridgetown while under the Dutch flag turned me into Pirate, which made everyone (including Holland) hostile. And then, indeed, Danielle was loyal to Personal, i.e. me; I'd just raised a Dutch flag which I hadn't noticed was now hostile to me; so Danielle, in her loyalty to me, attacked me. xD (I tried re-running the attack but under a Spanish flag. Holland and Portugal only turned Wary, not Hostile, so I'd probably have got away with flying a Dutch flag in front of Danielle's fort then. But I still didn't like losing the high standing I'd gained with Holland and Portugal before then, so I fixed the code accordingly.)

If you want a story-based explanation, the other nations have found out Silehard is rotten and are waiting to see how this plays out. So, provided you don't do anything in excess of what's needed to defeat Silehard, the other nations aren't going to take action. Maybe they already know what you're going to find out later, which is that a new governor is on his way with a pardon for you and an arrest warrant for Silehard. This would also be why they don't object to you taking out Silehard's counterattack fleet. (Besides, you've just shown you can take out a fort, and after the counterattack you probably have another battleship. But you seem to be confining your attention to Silehard for now. Do they really want to provoke you? xD)
 
No, it turned Britain from hostile (-60) to wary (-59).
How can you be getting points with England while England is hostile to you?
You're not meant to get ANY plus points with a nation, unless you have a LoM or you're doing a Governor Ship Hunting quest for them.

Could it be that because you have a Dutch LoM and Holland is allied with Britain, you gain points with Britain too?
That is definitely not intentional on my part! :shock

So....
I thought the idea was that attacking an enemy ship would earn you points up to 0 but would not get you above 0. So if you're at -59 and attack an enemy ship (legally, via someone else's LoM) then you should go up to -58.
Not really, no. If you sink ships hostile to England while also being hostile to England yourself, your relation to England should get neither better nor worse.

Attacking Bridgetown while under the Dutch flag turned me into Pirate, which made everyone (including Holland) hostile.
Yes, it would do. That is the equivalent of sinking an English ship while under an English flag.

And then, indeed, Danielle was loyal to Personal, i.e. me; I'd just raised a Dutch flag which I hadn't noticed was now hostile to me; so Danielle, in her loyalty to me, attacked me. xD
That is definitely quite hilarious! Everything technically working like it should, having a consequence that is quite ridiculous. :rofl

I tried re-running the attack but under a Spanish flag. Holland and Portugal only turned Wary, not Hostile, so I'd probably have got away with flying a Dutch flag in front of Danielle's fort then.
At least Spain was hostile to Britain, right? That would indeed be less bad, at least.

Still, the best solution would be to have "skipRM" in place here. That is what that is for, I just didn't add it here yet.
All that's necessary is a check for that attribute prior to the 'UpdateRMRelation' function call, since that is the one that triggers all those relation changes.

If you want a story-based explanation, the other nations have found out Silehard is rotten and are waiting to see how this plays out. So, provided you don't do anything in excess of what's needed to defeat Silehard, the other nations aren't going to take action. Maybe they already know what you're going to find out later, which is that a new governor is on his way with a pardon for you and an arrest warrant for Silehard. This would also be why they don't object to you taking out Silehard's counterattack fleet. (Besides, you've just shown you can take out a fort, and after the counterattack you probably have another battleship. But you seem to be confining your attention to Silehard for now. Do they really want to provoke you? xD)
I completely agree with you that taking the Bridgetown Fort under normal circumstances should have no negative effects on nation relations. :yes
 
How can you be getting points with England while England is hostile to you?
You're not meant to get ANY plus points with a nation, unless you have a LoM or you're doing a Governor Ship Hunting quest for them.
I knew you couldn't earn points with a nation who is hostile to you, but thought you could earn points if they're not hostile. Just not beyond 0. And not if it's an act of piracy. But if Britain is non-hostile (better than -60), you have a Dutch LoM and you sink a French ship, then you'd earn a point with Britain so long as it doesn't take you over 0. However, apparently not.

Could it be that because you have a Dutch LoM and Holland is allied with Britain, you gain points with Britain too?
That is definitely not intentional on my part! :shock
What earned me a point with Britain wasn't sinking a ship. It was raiding a colony.

Not really, no. If you sink ships hostile to England while also being hostile to England yourself, your relation to England should get neither better nor worse.
But what if Britain isn't hostile, it's only wary? Perhaps the colony raiding code is bugged and I shouldn't have earned a point for that either, but the net result was that for a while Britain was not hostile. In that case, should you be able to earn points to become even more neutral? Not to go above 0, but perhaps to go from -50 to -30?

Still, the best solution would be to have "skipRM" in place here. That is what that is for, I just didn't add it here yet.
All that's necessary is a check for that attribute prior to the 'UpdateRMRelation' function call, since that is the one that triggers all those relation changes.
Perhaps if that's implemented, I can use it if I return to "Tales of a Sea Hawk" to deal with the ending...
 
Perhaps if that's implemented, I can use it if I return to "Tales of a Sea Hawk" to deal with the ending...
Save attached to your PROGRAM folder. I think that should make fort captures take into account "skipRM" too.
It also adds the "betrayal" functionality into Fort Capturing, which is already in place at sea, but wasn't for forts.

I knew you couldn't earn points with a nation who is hostile to you, but thought you could earn points if they're not hostile. Just not beyond 0. And not if it's an act of piracy. But if Britain is non-hostile (better than -60), you have a Dutch LoM and you sink a French ship, then you'd earn a point with Britain so long as it doesn't take you over 0. However, apparently not.
That isn't intended to be the case, no.

But what if Britain isn't hostile, it's only wary?
Shouldn't matter. If you don't have a LoM, then you don't have a LoM and that is what matters.

Perhaps the colony raiding code is bugged and I shouldn't have earned a point for that either, but the net result was that for a while Britain was not hostile.
Well, it's not bugged per se, since I found out why you got that +1 in Dialog_func.c:
Code:
   // PB: Turn Hostile Upon Looting -->
   if(GetRMRelation(PChar, iNation) > REL_WAR)
   {
     SetRMRelation(PChar, iNation, REL_WAR);
   }
   // PB: Turn Hostile Upon Looting <--
   ChangeRMRelation(PChar, iNation, -relchg);
   for (i = 0; i < NATIONS_QUANTITY; i++)
   {
     if (i != iNation && GetNationRelation(iNation, i) == RELATION_ENEMY) ChangeRMRelation(PChar, i, 1.0);
   }
So somebody added that on purpose at some point. I'm not sure if it makes sense to have that though.

Why does that not simply call 'UpdateRMRelation' which normally takes care of stuff?
I think there was actually a reason for that, but cannot think of it now.

The way it currently is: If you start the game with all nations hostile and you loot one pirate town, they all turn friendly.
Something like this does make slight sense to me, but NOT for attacking the pirates (because those are by default hostile to everyone).
I'd propose keeping it as-is, but adding an exception so this doesn't happen for pirates.

In that case, should you be able to earn points to become even more neutral? Not to go above 0, but perhaps to go from -50 to -30?
You can do that by doing Governor Ship Hunting Quests, which is now intended to be the primary way of doing that and, in so doing, reduce the purchase price of a LoM.
And, as it turns out now, Raiding a colony affects it also.

Anything else you do at sea though does not have this effect and personally I'd prefer keep it like that.
If you don't have a LoM, then the other nations don't know you do it "for them" so whatever you do should not affect your relations with them.
The Governor Ship Hunting Quest is an exception since it is pretty much a single-use LoM against a specific target.

What earned me a point with Britain wasn't sinking a ship. It was raiding a colony.
And you're absolutely right. I didn't remember that was in the code, but now I understand. :yes
 

Attachments

  • Dialog_func.c
    101.3 KB · Views: 103
Some more information:

CaptureColony does:
- Apply nation relation changes (since the player is responsible for this being triggered!)
- Write a Ship's Log entry
- Give XP to the player
- Repair the fort and reset its memory (so you don't get shot on your way out)
- Execute 'CaptureTownForNation'
- Whatever Event(COLONY_CAPTURED does :unsure

Then CaptureTownForNation does the actual changing of the nationality.

So as for the original report, this seems to be where Bridgetown is set to Personal:
Code:
CaptureTownForNation: town=Greenford, 1st=0
SetTownGarrisonForNation: town=Greenford, 1st=0
Quest name Story_GreenfordCapturedByBlazeAndDanielle FOUND in QuestComplete
Then I assume this is where it goes back:
Code:
Quest name Story_TalkWithResearcherAfterSiegeGreenford_2 FOUND in QuestComplete
CaptureTownForNation: town=Greenford, 1st=0
SetTownGarrisonForNation: town=Greenford, 1st=0
Error!!! Overup maximum crew quantity (character=519)
Error!!! Overup maximum crew quantity (character=1033)
Error!!! Overup maximum crew quantity (character=1036)
Error!!! Overup maximum crew quantity (character=1032)
Quest name Story_VoyageToKhaelRoaBegan FOUND in QuestComplete

Both times, the relevant function 'SetTownGarrisonForNation' gets called and does not get aborted, since it is logged in compile.log .
However, I think I found the culprit and I recognize the initials there (yes, they're mine...):
Code:
trace("SetTownGarrisonForNation: town="+town+", 1st="+bFirstInit);

   for (n = 0; n < CHARACTERS_QUANTITY; n++) {
     character = GetCharacter(n);
     if (CheckAttribute(character, "location") == false || FindLocation(character.location) < 0 || GetTownGovernorIndex(town) == n || IsOfficer(character) == true) continue;
     if (GetTownIDFromLocID(character.location) == town) {
       if (bAllies(character)) continue; // PB: Skip any characters that are with the player

If I recall, the reason for that 'bAllies' check is to avoid any characters belonging to the player party from getting their nationality changed.
But of course those Personal Soldiers ARE in the Player Party and are therefore being skipped too, which is NOT intentional.

I'm not entirely sure of the safest way to fix this, but at least we now know why it happens.

I am also failing to see where the town characters get their actual .nation attribute changed.
As far as I can tell now, that never does actually happen. Which makes me wonder why I had to bother to put that "tailor" exception in place.

Ugh.... My brain is certainly not in the mood to figure this one out today.
But at least we knew more now than we did this morning.... :oops:
 
So then the question becomes - why are there some town guards who do change correctly? Specifically, the two outside the prison and the two on the town side of the port gate.
Save attached to your PROGRAM folder. I think that should make fort captures take into account "skipRM" too.
It also adds the "betrayal" functionality into Fort Capturing, which is already in place at sea, but wasn't for forts.
How do I set "skipRM" for Bridgetown in that case?

As for "betrayal", I thought it was in place for forts, which is how I turned pirate after capturing Bridgetown when the quest code was using 'CaptureColony'. Anyway, since you can't change flag except at sea, whichever flag you used while bombarding the fort from the sea will also normally be your flag when you capture the town.

The way it currently is: If you start the game with all nations hostile and you loot one pirate town, they all turn friendly.
Something like this does make slight sense to me, but NOT for attacking the pirates (because those are by default hostile to everyone).
I'd propose keeping it as-is, but adding an exception so this doesn't happen for pirates.
Why not? They're not the only party who is hostile to everyone. If you're playing in the War of the League of Augsburg, whether by free-play in the relevant years or while playing "Ardent", France is hostile to everyone. And in "Revolutions", Britain is hostile to everyone except Portugal.

You can do that by doing Governor Ship Hunting Quests, which is now intended to be the primary way of doing that and, in so doing, reduce the purchase price of a LoM.
And, as it turns out now, Raiding a colony affects it also.

Anything else you do at sea though does not have this effect and personally I'd prefer keep it like that.
If you don't have a LoM, then the other nations don't know you do it "for them" so whatever you do should not affect your relations with them.
The Governor Ship Hunting Quest is an exception since it is pretty much a single-use LoM against a specific target.
Fair enough. I thought I'd seen somewhere that attacking someone's enemy would earn you a point with them so long as it didn't take you above 0, but if that's not the case, so be it - I'm just trying to understand the rules, not to change them. ;)
 
So then the question becomes - why are there some town guards who do change correctly? Specifically, the two outside the prison and the two on the town side of the port gate.
I have absolutely no clue. That doesn't make much of any sense to me at the moment. o_O

How do I set "skipRM" for Bridgetown in that case?
This should work:
Code:
Characters[GetCharacterIndex("Greenford Commander")].skipRM = true;
It gets automatically removed upon capturing, so you shouldn't need to manually remove it afterwards.

This behaviour could easily be changed for forts; I just replicated it from 3D Sailing Mode.

As for "betrayal", I thought it was in place for forts, which is how I turned pirate after capturing Bridgetown when the quest code was using 'CaptureColony'. Anyway, since you can't change flag except at sea, whichever flag you used while bombarding the fort from the sea will also normally be your flag when you capture the town.
The "betrayal" code is just the one that is triggered if you start the battle while under a flag friendly to the fort.

Why not? They're not the only party who is hostile to everyone. If you're playing in the War of the League of Augsburg, whether by free-play in the relevant years or while playing "Ardent", France is hostile to everyone. And in "Revolutions", Britain is hostile to everyone except Portugal.
Why not? Because it ends up being quite a bit of a cheat, no?
You're hostile to everyone, loot a pirate town and suddenly you're not hostile with any of them anymore. o_O

Fair enough. I thought I'd seen somewhere that attacking someone's enemy would earn you a point with them so long as it didn't take you above 0, but if that's not the case, so be it - I'm just trying to understand the rules, not to change them. ;)
That applies for the Governor Ship Hunting Quests only. :yes
 
Save attached to your PROGRAM folder. I think that should make fort captures take into account "skipRM" too.
It also adds the "betrayal" functionality into Fort Capturing, which is already in place at sea, but wasn't for forts.
It works after one slight change has been made. Line 2574:
Code:
ref chref = GetTownFortCommander(TownName, 0); // PB
Delete the 'ref'. "chref" is already declared on line 2565 so the repeat declaration causes the game to crash immediately.

"chref" is used again later in a block around line 2614, and the structure of that block implies that towns can have more than one fort. The new code only deals with fort commander 0, which is fine for Bridgetown as it only has one fort. But if there are indeed towns with more than one fort and "skipRM" is used on them, I wonder if "skipRM" will work properly?

Perhaps the line to use it should be:
Code:
Characters[GetTownFortCommanderIndex("Greenford", 0)].skipRM = true;
(Found by doing a Windows search for "ref GetTownFortCommander", finding it in "Towntable.c", and then finding that there's another function in the same file, 'int GetTownFortCommanderIndex', which gives the index number of the fort commander of your choice.)
 
Delete the 'ref'. "chref" is already declared on line 2565 so the repeat declaration causes the game to crash immediately.
Uhm.... oops? :shock

the structure of that block implies that towns can have more than one fort. The new code only deals with fort commander 0, which is fine for Bridgetown as it only has one fort. But if there are indeed towns with more than one fort and "skipRM" is used on them, I wonder if "skipRM" will work properly?
As far as I have ever seen, the "multiple forts" logic was added by @konradk but is not actually used anywhere.
All towns still only have a single fort commander. :shrug

Perhaps the line to use it should be:
That should do the trick too. :onya
 
Some towns appear to have more than one fort from the sea. St. Pierre, Martinique, is one - the main fort is next to the town, then there's a smaller one behind and to the left of the town as viewed from the deck of a ship which is firing at them. Perhaps that code is to make sure that both of them reset properly when you've finished raiding the town. :pirate41: But your "skipRM" code is looking specifically for commander 0, so if the attribute is set for commander 0 then it should work regardless of how many forts there are. Bridgetown only has one fort so 'Characters[GetCharacterIndex("Greenford Commander")].skipRM = true;' should work there. And indeed, it does - that was the version I had in "quests_reaction.c" when I reloaded the savegame just before talking to the soldier to take the colony.
The "betrayal" code is just the one that is triggered if you start the battle while under a flag friendly to the fort.
That's what I meant. The first time I played the battle, I attacked the fort under a Dutch flag and as a result was labelled as a pirate. Some sort of "betrayal" code must already have been in place before you added the "skipRM" and extra "betrayal" code.
You're hostile to everyone, loot a pirate town and suddenly you're not hostile with any of them anymore. o_O
And in the War of the League of Augsburg, you're hostile to everyone, loot a French town and are suddenly not hostile to anyone, apart from France of course - but then, looting a pirate town won't make the pirates like you either. Looting a British town in "Revolutions" is almost as good, everyone except Britain and Portugal will stop being hostile to you. Also, they're still only one point up from hostile; you have quite a way to go before you reach -45 which is "REL_AFTERATTACK", which means shopkeepers are still going to refuse to trade with you if they detect your false flag.
 
Some towns appear to have more than one fort from the sea.
Appear, yes. As far as I know, the game still considers it a single fort.
Look through the fort commanders character init file; there is only one for each town.
If there are truly multiple forts, then who commands them?

That's what I meant. The first time I played the battle, I attacked the fort under a Dutch flag and as a result was labelled as a pirate. Some sort of "betrayal" code must already have been in place before you added the "skipRM" and extra "betrayal" code.
I can't remember what adds the "betrayed" attribute again, but the fort capture did not check for that yet.

And in the War of the League of Augsburg, you're hostile to everyone, loot a French town and are suddenly not hostile to anyone, apart from France of course - but then, looting a pirate town won't make the pirates like you either. Looting a British town in "Revolutions" is almost as good, everyone except Britain and Portugal will stop being hostile to you.
So what if we just use the regular 'UpdateRMRelation' call instead?
In other words: You won't get plus points when looting a colony from any nation, EXCEPT those you already have a LoM from.

Should you get plus points for looting a colony at all? Definitely for capturing it and giving it to another nation.
But with looting, it is YOU who gets the main bonus. Why should random nations "reward" you for you enriching yourself?

Also, they're still only one point up from hostile; you have quite a way to go before you reach -45 which is "REL_AFTERATTACK", which means shopkeepers are still going to refuse to trade with you if they detect your false flag.
One point makes quite a huge difference, since forts and ships won't try to kill you.
 
Back
Top