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

Search results

  1. T

    Needs Testing Intelligent AI retreats and surrenders

    @Cassadar @Pillat and any others willing to test: New version now attached to first post, new changelog posted there too, and ready for testing! Please let me know your experiences, and also, if you get into any nice battles, please post the compile logs. I've got traces set up so we can see...
  2. T

    Fixed Cannot capture enemy captains after surrender

    Agreed, this is a temporary measure offered only to experienced players who want to start capturing captains in the meantime, not a real fix. :) Happily in playtesting I haven't seen any problems (captured a couple of captains). I think because the checks are coming back false for a silly...
  3. T

    Fixed Cannot capture enemy captains after surrender

    Here's a temporary fix for people currently playing to be able to capture captains again. It goes in PROGRAM/DIALOGS It has all the changes I previously made to Captain dialogue and deathfights still in the file, since those weren't the source of the problem. All it does is insert a single...
  4. T

    Feature Request AI decision to prioritize boarding

    @Pillat had the below idea: With the new rewritten power function, the AI is currently estimated its fighting power as essentially Remaining HP multiplied by Firepower (scaled up for better cannons), and then comparing the sums for the enemy and friendly fleet, to decide whether to withdraw...
  5. T

    Needs Testing Intelligent AI retreats and surrenders

    BTW, the new rewritten function for powerratio is easy to understand, it is essentially: 1) Skip counting all ships farther than long range 2) Remaining HP multiplied by firepower (firepower = remaining cannon qty multiplied by cannon price, so scaling up the firepower for better cannons)...
  6. T

    Needs Testing Intelligent AI retreats and surrenders

    Thanks @Pillat ! :) Sorry for the delay everyone: since the powerratio function had been used in the prior surrender code, I assumed it worked, and had no idea I would have to rewrite it, which made this 10x more complicated. But, on the plus side, in addition to actually working, the new...
  7. T

    Needs Testing Intelligent AI retreats and surrenders

    Well, that took the entire day and completely rewriting the function. As it turned out, it was completely broken in many ways. I need to sleep now, and I want to take one more look at the function tomorrow before releasing the new version. In the meantime, if anyone wants to comment on the...
  8. T

    Drastically reduce chance of Pirate encounter in friendly ports

    And here is the rewritten powerratio function for reference, will take another look at it tomorrow, happy to hear if you have any feedback. For now, it seems to be working as intended. :) (Though I will move the distance limit check up a bit to avoid some caluclations for far ships) //finds...
  9. T

    Drastically reduce chance of Pirate encounter in friendly ports

    @Pieter Boelen Finally, success! Had to basically rewrite the entire thing, but it works well now. Here is what it looks like in compile (with my traces on) when a Pirate ship (happens to be treasure pirate, but coastal raiders would be the same), decided a fort and the British warships in the...
  10. T

    Drastically reduce chance of Pirate encounter in friendly ports

    Yep, the reason it couldn't count forts was the getcurrentshiphp function is returning 0 for forts. Here it is btw: int GetCurrentShipHP(ref _refCharacter) { int nShipType = GetCharacterShipType(_refCharacter); if (nShipType <0 || nShipType >= SHIP_TYPES_QUANTITY) { return 0; } // PB...
  11. T

    Drastically reduce chance of Pirate encounter in friendly ports

    Thanks @Pieter, I found the code you mentioned, and was also able to get the original code for distance working properly. The problem was the original function was orderd wrong and hadn't defined the characters before trying to get the distance. Also, while it was trying to get forts, the...
  12. T

    Drastically reduce chance of Pirate encounter in friendly ports

    Thanks Pieter. Turns out the distance seems to not be gotten from the nearship function properly. Also, because of the place the self power check is positioned, in some situations (especially when the AI ship is alone), it will always return 0 for the power, because it cancels before it gets to...
  13. T

    Drastically reduce chance of Pirate encounter in friendly ports

    Ok, the problem is the distance is missing, probably not getting assigned in the nearship function correctly. I'm not so sure about the current use of distance anyway--it makes the power ratio too drastically changing when ships get a little closer or farther. I think I can fix this.
  14. T

    Needs Testing Intelligent AI retreats and surrenders

    @Cassadar I appreciate that, thanks! :) There will be a new version in a couple of hours once I finish fixing something, the original powerratio function isn't working right correctly. (no harm to the game, just the new retreat check never comes back true right now, so currently only surrender...
  15. T

    Drastically reduce chance of Pirate encounter in friendly ports

    @Pieter Boelen Not sure if you have a moment or not to take a look at something, totally fine if you don't. I wrote some 10-15 trace entries and have been running tests watching things happen. Things look fine on the surrender stuff, but on the powerratio stuff, there is good news and bad news...
  16. T

    Unconfirmed Bug Error in crew quantity

    Interesting, but can't be for the swimming sailor, they had just been generated. It probably was right after they got hit with the cannon blast from the fort, right after opening the scene. Unless their own guy got knocked off themself, but then when would picking him up again run them over...
  17. T

    Unconfirmed Bug Error in crew quantity

    Found this in my compile log: Error!!! Overup maximum crew quantity (character=1433) The character is a treasure pirate. Some other errors were present for him as well: EA: Error: Group Treasure_Pirate, Island Oxbay SEA: Error: Find locators Group , Locator He did spawn correctly in the...
  18. T

    Needs Testing Intelligent AI retreats and surrenders

    Updated version attached to top post. Mainly slight changes to some modifiers based on how strength ratios are compared, and a minor tweak to the powerratio function (setting it to 1.0 instead of 0 under a certain circumstance that would never come up in the way I use it currently, but might...
  19. T

    Drastically reduce chance of Pirate encounter in friendly ports

    I think so, because in my tests the coastal raiders always turned and ran after the first volley from the fort. Can't be entirely sure it was because of this retreat check, but before they had seemed to stick around and shoot back for awhile, so it looks like it worked. But I can't tell from...
  20. T

    Fix in Progress Demasted AI and retreat order

    Looked it up, and bringing down a mast: 1) has equal chances for cannonballs and chain (but 0 chance for grape) (Assuming there isn't some collision detection kind of reason where the chain has a larger impact area) 2) is much more likely when range is closer (which explains why coming up...
Back
Top