• 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 Raising Flag in battle shouldn't always trigger treason

Hylie Pistof

Curmudgeon
QA Tester
Storm Modder
Pirate Legend
What happened is that I was on a smuggling run and leaving Jamaica when I was intercepted and had to fight. During the battle when I saw I was winning I changed my flag from English to my personal flag so they could surrender and I could capture them. I did get one ship that way. Then went on my merry way.

Later I went there again for another smuggling run and was recognized in town and quickly killed twice. The English were never friendly with me and started out at -60. Now they are -65.

This flag thing and being recognized is a no win situation.
 
Any thoughts on how we could keep the feature and make it less annoying?
Perhaps prevent the citizens from joining in on the fight? Remove the additional soldiers and have you deal only with the normal town guards?

I don't really want to lose it. There is a "punishment" right now for being a traitor like that and I do believe there should be.
Just not to the point of "instant game-over".
 
Maybe add a timer to it?
After a month for example they forget about it..
 
If anyone wants to do something with it, this feature is triggered in PROGRAM\BATTLE_INTERFACE\BattleInterface.c with this line:
Code:
if(sti(chr.nation) != PIRATE) PChar.traitor = chr.nation; // marker for recognizing feature
Then that PChar.traitor attribute is checked in various dialog files to trigger the actual recognizing.
 
I remember reading about an English ship that flew the Spanish flag as they sailed past the fort and entered a harbor. I forget why they wanted to get into that harbor. I do remember that they even lowered some sails and coasted in nice and easy to make it look like they were unconcerned.

Another time a small English frigate decided to attack a much larger Spanish frigate, so they ran up the Spanish flag and moved in. They almost got to within boarding distance before the Spanish became alarmed and did in fact board and take the Spanish frigate.

Now in those type of situations perhaps someone would remember them as low down dirty snakes and sound the alarm. But when battle has already been engaged and the reason for changing flags is to accept a surrender there should be no penalty. As a smuggler the last thing I want is to attract attention. Also, as a smuggler I have no loyalty to any nation so can not be a traitor.
 
So maybe an extra check should be done?

If the PChar.Ship.Cannons.fired_time is larger then a certain number it should trigger. Else you probally are in battle already.
I'm not sure how the fired_time is stored. Have to look at up. But say for example you haven't fired your guns in 3 hours (ingame) then probally you aren't in battle.

we could also change the range. its on visability range now
 
I was trapped in a small bay and we were firing at each other at point blank range.
beta3 2013-11-06 21-25-44-34.jpg

There are those who hang around the edge of a large battle and sail up close to a surrendered but friendly ship and then change flags to hostile, capture it, and then quickly sail away before the other ships in the fleet can engage them.
They should get the penalty.

How to separate the two situations?

On the subject of fighting in town, at level 12 or so I could just about get past the immediate town folk but when the soldiers came running up we got wiped out. Really the only option is to just take off running out of that part of town.
 
Is hoisting another nation flag close to another ship not considered a traitorous action?
If I recall, Hornblower was being condemned to death for that by Napoleon in "A Ship of the Line"/"Flying Colours".

Why should you need to change flags to accept a surrender anyway? If the surrendering ship was previously hostile to you, you should be able to accept the surrender.
If the surrendering ship was not previously hostile to you, then they thought you were your friend and therefore "accepting their surrender" could be considered traitorous.
After all, they don't know you might normally be hostile to their nation.

Imagine you join a battle between the Dutch and French under a Dutch flag. You are actually hostile with both nations.
A Dutch ship surrenders, so you hoist either your personal flag or a French flag in order to accept this surrender.
Consider how that looks to them: For all they knew, you were a friend!

Anyway, here's the relevant code:
Code:
    if(Ship_GetDistance2D(pchar, chr) <= visibility_range)
     {
       //If you hoist an enemy flag close to other ships, they will remenber you and recognise you next time
       if(CheckAttribute(Pchar,"flagchanged") && GetNationRelation(sti(pchar.nation), sti(chr.nation)) == RELATION_ENEMY)
       {
         chr.recognized = 1;
         chr.EnemyShipName = Pchar.Ship.Name;
         chr.EnemyShipType = Pchar.Ship.Type;
         // PB: Only do this close to enemy ships
         if(sti(chr.nation) != PIRATE) PChar.traitor = chr.nation; // marker for recognizing feature
       }
     }
     // SCREWFACE : Check if you have been previously recognized
     //if(GetRMRelationType(GetActualRMRelation(sti(characters[Ships[i]].nation))) == RELATION_ENEMY && Checkattribute(&characters[Ships[i]],"recognized"))
     if(Checkattribute(chr, "recognized") && !CheckAttribute(chr,"surrendered"))
     {
       if(chr.EnemyShipName == Pchar.Ship.Name && chr.EnemyShipType == Pchar.Ship.Type)
       {
         SetCharacterRelationBoth(sti(PChar.index), Ships[i], RELATION_ENEMY);
       }
     }
If you changed your flag AND this makes you hostile, then the enemy ship recognizes you and you are marked as a traitor.
Then if that ship hadn't already surrendered, they will turn hostile.

We can also reduce the penalty for being recognized for doing this, such as making you deal with only the town guards and not the citizens.

Possible things to add:
- Check if that ship was hostile to you before you changing your flag
- Check if that ship is hostile to your personal nation
- Check if bMapEnter is true, which checks if you are locked in battle (or locked in a storm)

If the PChar.Ship.Cannons.fired_time is larger then a certain number it should trigger. Else you probally are in battle already.
I'm not sure how the fired_time is stored. Have to look at up. But say for example you haven't fired your guns in 3 hours (ingame) then probally you aren't in battle.
I think that is used for the "cannon ready" sounds and I know for sure those don't work right. Wouldn't recommend using that.
 
Using bMapEnter is indeed better.

maybe add some kind of infamy counter? Doing these kinds of things will result it in going up and for example each month it goes down a bit. If the number is above a certain value the chance of being recognized will go up?
 
I belong to no nation and owe no allegiance to any nation. They were hostile to me and commenced firing as soon as I boarded my ship. I only changed flags because of recent problems when they surrender.

When recognized in town the only option is to run.
 
I belong to no nation and owe no allegiance to any nation.
But they don't know that, unless you fly your Personal Flag.
Are you hostile with everyone, then? Like a true pirate?

They were hostile to me and commenced firing as soon as I boarded my ship. I only changed flags because of recent problems when they surrender.
Recent problems? What recent problems?

I always thought that if a ship is hostile to you before surrendering, you should be able to capture them.
Unless there is some code to check literally WHO they are surrendering to and if it isn't YOU, then you can't capture them.
But I didn't think the code was quite that advanced.
 
But they don't know that, unless you fly your Personal Flag.
Are you hostile with everyone, then? Like a true pirate?

Recent problems? What recent problems?

I always thought that if a ship is hostile to you before surrendering, you should be able to capture them.
Unless there is some code to check literally WHO they are surrendering to and if it isn't YOU, then you can't capture them.
But I didn't think the code was quite that advanced.


In the Army if someone is caught wearing the wrong national uniform, if he isn't shot on sight he is hung, guillotined, drawn and quartered, etc. Why should a Navy be any different? Those English sailors I mentioned before were not traitors. To the Spanish they were common criminals (pirates) and to the English they were heroes.

In this game I am only hostile with the Pirates, because I can't make a living as a Pirate as I would have to be doing nothing but smuggling, and the English, because they are the best opponents.

Recent problems were when I tried that pirate hunting save game the other day and could not complete it until I changed flags. You see, I normally do not bother changing flags because I get instantly recognized anyway, but after that I tried it again and got in trouble in town. So no more changing flags.
 
In this game I am only hostile with the Pirates, because I can't make a living as a Pirate as I would have to be doing nothing but smuggling, and the English, because they are the best opponents.
Exactly what are you using the fake flags for though? There should be no need for it, unless you are deliberately pretending to be of another nation.
And when you're caught for doing that, that's when you get the whole "traitor" thing going.

We could also put a random chance to whether this happens or not. For example, have it happen only 1-in-4 times if it seems too frequently now.

New game required! Incompatible saves.
Good call! I forgot to mention that. :facepalm
I'm not sure if it really IS necessary, but a lot has been changed behind the scenes, so I figured playing it safe and requiring a new game. :oops:
 
Thread split from original thread.
 
Cheers. :cheers

Some things we could do:
1. Add a random chance to this: Should be easy enough and decreases the chance
2. Only do this if bMapEnter is true
3. Decrease the amount of enemies you get when you are recognized for doing this

All three of those should be pretty easily accomplished.
 
To put create some sort of risk when doing evil, traitorous things!!! :whipa

It used to be limited to only "raising a pirate flag", but nobody ever used that button.
It became common because I changed it to "raising any hostile flag".
Which should be fair enough if it works for raising pirate. :shrug
 
I think it should only happen when there are other ships also in the vicinity. If you attack only 1 ship this way there wont be anyone to tell you did it.
 
Well, that one would require some figuring out. bMapEnter would already check for the presence of hostile ships though.
 
I am getting attacked by 2-6 ships if I am discovered and the distance of recognition is beyond the horizon. Only speed and lucky wind allows an escape. Or some powerful ships. On my last smuggling run last night my Hoy had to dodge 6 ships. Two in the bay, two just outside the bay, and two more that came around from the other side of the island. Got a bit shot up.........and they don't give up. Here is a screenie of me entering a safe harbor. Those sails in the distance are an English battle fleet.beta3 2013-11-08 20-52-26-72.jpg

In the standard storyline, how does one get into St. Pierre without changing flags?
 
Back
Top