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

Ship morale (not your own)

IncredibleHat

Landlubber
Storm Modder
I am trying to clean up the surrender toggle in the code, or lack of. I am trying to fathom what point is calculating the morale of 'other ships' in the game, when surrender is turned off in BS.h?

It looks like all this figuring is going on for morale, just to figure if a ship should surrender to you or not. Really, this could have been done differently... not calculating EVERY ships distance, every ships strength, every ships condition, every ships state, every ships nation, blah blah blah blah, and every ships own paint job. Only needed to be concerned with YOUR ship, and if you are a better match for them. When has a ship ever surrendered to another NPC ship? I havnt seen that happen, so why all this calculation of each ship to each and every other ship, when only they ever surrender to you or not?

Other ships don't continue to exist in the world, and morale doesn't change their effectiveness in battle. So, why were there not code added to simply ignore all these calculations when surrender was turned off? This is what I'm fixing.

However, I wanted to know if I am not seeing some other use that all this morale calcing is used for on NPC ships?

And btw, who is "NK".

I am not trying to be offensive on this one. I am just doing this because it is squarely related to this code, why I have the crappiest performance during sailing in Post Build Mod 12. I dont care about surrenders, and as such, all this code is doing nothing for me but make the sailing in game unplayable. So, a proper toggle, will save me much time and effort in the future commenting all this code out in each new update.
 
<!--quoteo(post=153752:date=Jul 4 2006, 11:49 AM:name=IncredibleHat)--><div class='quotetop'>QUOTE(IncredibleHat @ Jul 4 2006, 11:49 AM) [snapback]153752[/snapback]</div><div class='quotemain'><!--quotec-->
When has a ship ever surrendered to another NPC ship? I havnt seen that happen, so why all this calculation of each ship to each and every other ship, when only they ever surrender to you or not?
<!--QuoteEnd--></div><!--QuoteEEnd-->

I see this happen all the time. Sometimes you can board these surrendered ships yourself.

I can't prove it at the moment, but I think morale affects reload time for the cannons and probably a lot more things as well.

NK is Nathan Kell. He did a lot of great modding for the game. And one of the rumors says,

"Be warned that even the towns aren`t safe from crime anymore these days. The godfather of Archipelago, the notourious Nathan Kell, has organized mobs of thugs and robbers that rule the streets. So be careful if you walk around in town, anyone carrying a weapon may assault you, even if he looks like a honest citizen at first sight.",

Gotta love that one. <img src="style_emoticons/<#EMO_DIR#>/smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" />

Hook
 
Hahah. Granted, there is a lot of nice code added with the sailing AI. It is nice how ships act in groups, retreat together, act together etc.

I havn't seen any code relating to cannons in the morale check area. Closest I find, is reducing the amount of cannons you can fire, if the crew is too few for the cannons.

It may however look at ship morale in a completely different area dealing with the reloading of cannons though.

That was my question... if the morale portion actually is used in other places. Naming conventions is crazy to follow, many used the same varname in multiple locations, yet they have no relation to each other unless that var HAPPENED to be initiated in globals, instead of inside the function. Really... if yer gonna make a global, put a prefix on it so people know! LOL.

I did find something interesting ... FindNearShips occurs about A BEEELION times per round of code. LogIt is FUN... *cough*

Hey... why do forts and ships fire massive volleys right into the side of the island at each other? I don't recall stock game ever doing that...

Also, how the %#$@%# can a fort fire at you from 2 miles away!?!?!?!?!? Sheeeeeeeeeesh man... I didn't realize they had that sort of high tech balistics back then =)
 
The point for calculating ship morale is the fact that when u board an ship the chance for surendering depends on the morale. Please note that sea surender is different from ship boarding surender. Also if the shi doesn't surender when u board it, the enemy board crew HP depends on morale, like ur boarding crew HP.

Edit:It has to do with cannons reloading, how fast ur ship changes sail mode(sails), how fas they execute special ability(not sure about this one), how fast their repair ship, its usualy how fast....<img src="style_emoticons/<#EMO_DIR#>/biggrin.gif" style="vertical-align:middle" emoid=":D" border="0" alt="biggrin.gif" /> . And if i remember corectly it has to do with gun salvo being executed all at once. if morale is low the time between first gun and the last gun is quite big. These thing seem prety logical to me. (anyhow i did finish stock game twice:p)

PS: i agree surender to sea sux. I remember somewhere in history(i mean RL history) if a captain surender in the midle of the fight he was called a traitor! so why in the Neptuns name i cant bring him to justice?? My point is that you should be able to board ANY white flag ship.
 
<!--quoteo(post=153763:date=Jul 4 2006, 02:14 PM:name=IncredibleHat)--><div class='quotetop'>QUOTE(IncredibleHat @ Jul 4 2006, 02:14 PM) [snapback]153763[/snapback]</div><div class='quotemain'><!--quotec-->
I did find something interesting ... FindNearShips occurs about A BEEELION times per round of code. LogIt is FUN... *cough*<!--QuoteEnd--></div><!--QuoteEEnd-->
Hm, seems like that should only be called when the sea updates, which is *I think* every 2 seconds. Find out where that block of code is called, and see if you can figure out why it's so frequent.

<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec-->Hey... why do forts and ships fire massive volleys right into the side of the island at each other? I don't recall stock game ever doing that...<!--QuoteEnd--></div><!--QuoteEEnd-->
Possibly because in the stock game the ranges were like 333 yards. The game doesn't appear to be checking for land masses in the way of firing.

<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec-->Also, how the %#$@%# can a fort fire at you from 2 miles away!?!?!?!?!? Sheeeeeeeeeesh man... I didn't realize they had that sort of high tech balistics back then =)
<!--QuoteEnd--></div><!--QuoteEEnd-->
I was wondering that myself recently when a fort was firing at an enemy ship about 2000 yards away. I just checked the code and the CANNON_TYPE_LONG_LBS32 has a range of 2080. There are a few others that have high ranges, but that was the highest I saw.

Blody Roger: Sometimes it's not the captain that surrenders in Real Life, but the crew. I think that's called mutiny. <img src="style_emoticons/<#EMO_DIR#>/smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" /> A captain who surrenders will be brought to trial, but is not necessarily a traitor.

Hook
 
Back
Top