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

Distance from enemy ship for victory/escape

Eskhol

Sailor Apprentice
Hi,

There's an "issue" with the victory conditions when you are in a battle on the sea.
If your cannons are 32 lb you can still reach the enemy ships and shot them but there's no battle going on, you can go into the worldmap from there because they are very far away.
It's a bit weird when you are in a battle and sink one ship that was close but your allies are still in the middle of the battle and your cannons can reach the enemy ships and then the peaceful music starts and you can just exit.

Could this be easily fixed? I'm thinking a good distance would be 1500 yards. If it's an easy fix I could just do it and upload the file for everyone.
 
This is what I mean. Screenshot (53).png

As you can see, I could still fire at him but I can also go into the worldmap and I'm not in combat.
 
There is an InternalSettings.h value for the "go to map" distance.
You can try to increase that, but be aware that we tried that before and that it resulted in occasionally being sea-locked because there were enemies on the other side of the island (that technically were within that circular range).

Alternatively, the cannon ranges should be decreased, which is certainly possible.
But the current ranges are pretty much historically accurate, so I'm not sure we should really want to do that....

You could also enable the Open Sea Mod at the top of InternalSettings.h which might improve things.
 
Oh I'll take a look into it, maybe I can find a good middle value.

The cannon range should stay how it is, I think it's pretty realistic so there's no point in changing it.

As always, thanks for the quick answer! :)
 
Hi Pieter,

I changed the "SAILTO_MIN_DISTANCE " value from 500 to 900 and enabled the Open Sea mod but now it happens when they are even closer than before! That's a bit strange.
 
Sail To is something else. There should be a Map Enter one.

The Open Sea Mod plays around with the scale of the worldmap to increase distances.
So indeed maybe that would have the exact opposite effect of what you have in mind. :facepalm
 
I found it, changed it to 900 and deactivated the Open Sea Mod. I'll do a couple of tests later.

By the way, it has nothing to do with this but, is there an easy way to find big ships or big convoys to fight with or it's just random?
 
It's Random.

If you are high level/have a big ship (can't remember which of the two), then the Governor Ship Hunting quests should be able to trigger some sizeable ones.

Big ships are deliberately rare though, for historical reasons.
 
By Ship Hunting quests you mean the ones with hostiles near the island? Those are starting to give me bigger ships but still small compared to mine so I think I need to be higher level.
I'm also a Baron for England, does that affect this missions?
 
I tested the new distance and it still doesn't work (I can exit to worldmap even closer to them).

// Sea Realism Params
float MIN_ENEMY_DISTANCE_TO_DISABLE_MAP_ENTER = 900.0; // FLOAT - original value is 500 - Petros: reset to 500.0 to prevent trouble
float MIN_ENEMY_DISTANCE_TO_DISABLE_ENTER_2_LOCATION = 500.0; // FLOAT - original value is 500

Maybe the trouble Petros mentions is what is happening to me.
 
Doesn't affect it, no.
Not a bad idea though; might be possible to add a number to the enemy ship Tier based on your current rank so that it'll become harder and harder.
This would probably require a five-minute fix at the top of PROGRAM\QUESTS\quests_common.c .

Would be especially nice if fleets would start showing up eventually, but that would require a little bit more work.

I tested the new distance and it still doesn't work (I can exit to worldmap even closer to them).
Ah, those values aren't actually used.
Look up those same variables in PROGRAM\NK.c as those are the ones that do work.
Note that they differ between Open Sea Mod On/Off, so check that you change the correct one. :onya
 
Last edited:
If you don't know about it yet, this here contains some massively helpful stuff when you want to do any modding:
Tutorial - Modding Tips & Tricks | PiratesAhoy!

Thinking about the "big ship" thing a bit more, I think there is a "player level" variable in the function that generates those enemies.
My first and simplest thought would be to add something like GetRank(pchar, iNation) to it. That would result in a fake higher level and therefore also bigger enemies.

Note that I wrote this from memory, so I might not have gotten the syntax quite right.
Be sure to check on that using the Tips & Tricks I linked to above.
 
That would also be nice and can be combined with the ideas about attacking forts and naval blockades. Maybe you can find the fleet that is going to attack your city before they attack it.

Yes, now it works! Screenshot (54).png

I will increase it further though and then test it near islands.

Edit: I made it 1200 and it works great in sea battles, still have to test it on small islands though.

Thanks, Pieter! :)
 
Last edited:
Back
Top