Shop  •   Avatar  •   FAQ  •   Search  •   Memberlist  •   Usergroups  •   Profile  •   Log in to check private messages  •   Log in  •  Register 

realistic cannonball speeds
Post new topic   Reply to topic     Forum Index -> Customization & Modding Goto page 1, 2, 3, 4, 5, 6  Next
View previous topic :: View next topic  
Author Message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Thu Feb 27, 2014 4:14 pm    Post subject: realistic cannonball speeds Reply with quote

Update: The final* version has been released. (updated Friday, March 14th 2014)

Download: http://www.adammil.net/files/121/CannonballMod.zip

The mod is also available in The Challenge Pack.

To use, unpack the .exe into your Pirates! game folder and run the game as usual. (Make a backup of your Pirates!.exe file first.) If you play on the Mac and want a Mac version of this mod, I'd be happy to create one, but we'd need to work together a bit since I don't have a Mac.

I'd like to post a patch so that people can combine this mod with other exe mods, but it turns out to be infeasible because most people are running an encrypted version of the game exe. Unless people start using an unencrypted version, code changes can't be feasibly released in patches.

Tips: Sea battles are more dangerous now! There's no more dodging cannonballs, so you should probably close quickly for boarding. If you want to fight a prolonged sea battle, larger warships have a definite advantage now (as it should be). To fight a battle against a more powerful foe, it's crucial to obtain superior positioning. You should try to remain aft of the enemy vessel, where it can't hit you, especially if you can remain aft while holding the weather gage. Smaller vessels have a better chance of obtaining this position in battle, but in all cases it's good to position yourself appropriately on the world map first.

* Of course, if you try it out and find a bug I'd be glad to fix it. :-)

Original blurb:

Having finished my second Pirates! playthrough today (on iron man/Rogue) and once again completed all the quests, I feel a bit bored with it. (Is that sacrilege? :-P) There's not much left to accomplish, and the game seems way too easy. I can win any sea battle without taking a scratch by just maneuvering around all the incoming cannonballs with my trusty royal sloop. It's kind of ridiculous that the cannonballs float gracefully towards me at 25 knots, so I was wondering what the game would be like if that was accelerated to a more realistic speed, say 250 knots.

I imagine that might shift or exacerbate the war canoe / SotL debate. On one hand, having a ship with staying power would be a lot more important. But then so would maneuverability - not that you could dodge a well-aimed broadside, but perhaps you could maneuver to stay out of their field of fire while keeping them in yours. That might make it more important to consider position relative to the wind before attacking. Also, the close and board tactic might become crucial, but it still wouldn't give tiny ships a decisive advantage, since they might just be blasted out of the water. But it would probably establish real dominance of the large warships over their medium-sized cousins (as it should be), rather than the current situation where any ship in the hands of the player can beat any ship in the hands of the AI. If a brigantine goes up against a brig of war in a fair fight, the brig of war should be expected to win! That would make acquiring the best ships a real challenge.

Maybe it would make the game impossible, or too frustrating. Fighting Monty and friends might be hellish. On the other hand, it might help make up for the inept battle AI. Combined with the iron man mod, it might make sea battles too risky to attempt casually, and pirate hunters more than mere speedbumps. You'd have to earn your plunder, and climbing the top 10 list wouldn't be child's play. :-P

(It would be good if it could be combined with something to reflect variation in crew experience, so that even though a trade galleon's cannons are dangerous, the crew wouldn't be nearly as skilled at aiming them as the crew of a warship. But I'm not sure if there are any existing data about the ships that could be used to infer crew skill. It'd also be good if cannonball speed depended on difficulty level, with Apprentice equal to the game as it is now and Swashbuckler being realistic speeds.)

Thoughts?


Last edited by AdamMil on Sun Mar 16, 2014 9:45 am; edited 19 times in total
Back to top
View user's profile Send private message Visit poster's website
Roland
Boatswain
Posts: 2880



8364 Gold -

PostPosted: Thu Feb 27, 2014 10:39 pm    Post subject: Reply with quote

I agree that the cannonball speeds are unrealistically slow. Instead of letting the AI cheat at higher levels by allowing enemy ships pivot on their mainmast (which is also unrealistic), it would be better to give cannonballs more speed at higher difficulty levels - and perhaps more range.

The game currently has several features that allow the effectiveness of a ship's guns to vary: taking Gunner as your special skill; the Gunner specialist; fine-grain powder; and bronze cannons.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Captain Teague
Rigger
Posts: 1161



11805 Gold -

PostPosted: Fri Feb 28, 2014 1:41 am    Post subject: Reply with quote

I would get on board with this idea; if it was made. Shoot, I'd do it myself if I had any know how.
_________________
The Code is the Law.
Back to top
View user's profile Send private message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Fri Feb 28, 2014 3:00 am    Post subject: Reply with quote

Well, I estimate it'd take 30+ hours to do the mod if I had to do it myself, so there'd have to be sufficient interest. I wonder if there are any other modders in the forums capable of finding or modding game logic who could help out. (Usually making the changes is relatively easy. The hard part is tracking down the code that needs to be changed.)
Back to top
View user's profile Send private message Visit poster's website
Pirate
Rigger
Posts: 1964



28235 Gold -

PostPosted: Fri Feb 28, 2014 10:14 pm    Post subject: Reply with quote

I am glad to see people trying to mod the game to be more realistic so the ultimate challenge would be to program it to kill you after you loose a fight or if that is too much then at least have it destroy your your PC or exe. file at the least. As you all know real pirates didn't have it as easy as we do. I doubt they would have minded having slower cannonballs fired at them and I am sure they would have taken advantage of being able to reload the scene after losing if that would have been possible. Pirates were cheats, scallywags anyway right?
Back to top
View user's profile Send private message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Fri Feb 28, 2014 10:23 pm    Post subject: Reply with quote

Pirate wrote:
... the ultimate challenge would be to program it to kill you after you loose a fight or if that is too much then at least have it destroy your your PC...
That's my next mod, "Pirate Roulette".

But I'm not trying to make it more challenging just for the hell of it, but because it might be more fun and interesting that way. :-P
Back to top
View user's profile Send private message Visit poster's website
Pirate
Rigger
Posts: 1964



28235 Gold -

PostPosted: Sat Mar 01, 2014 10:14 pm    Post subject: Reply with quote

I just want to say that I hope you can figure out this cannonball thing. To be honest with you I wouldn't have a clue as to how to go about doing it. It may be something as simple as editing a hex string in the .exe file but if in fact that is the case the challenge would be to find the cannonball speeds to start with. I have been myself looking into the city's trying to find out as much as I can about them when I am not working but anyway good luck with the cannonballs. Maybe the Pirate Roulette thing might be a little to much for some of the gamers. I was just being my ole crazy self in my last post.
Back to top
View user's profile Send private message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Sat Mar 01, 2014 10:30 pm    Post subject: Reply with quote

Pirate wrote:
I just want to say that I hope you can figure out this cannonball thing. To be honest with you I wouldn't have a clue as to how to go about doing it. It may be something as simple as editing a hex string in the .exe file but if in fact that is the case the challenge would be to find the cannonball speeds to start with. I have been myself looking into the city's trying to find out as much as I can about them when I am not working but anyway good luck with the cannonballs.
It's pretty tough. It's unfortunate that there's no central repository of information about the game's internals, since I'm having to basically figure out the whole thing from scratch. It seems like different people make progress in various areas, but the knowledge never really gets shared or centralized. I tried to contact some people (e.g. Phalzyr, jlangsdo, etc.) to ask if they could share the knowledge they've obtained but I've gotten no response yet. Since the game just dumps its memory directly into the save file for the most part, figuring out the save file format would shed light on the logic within the executable.

Speaking of the cities, I am at this very moment trying to decipher the data about them. So, do you have any information to share? :-)

Pirate wrote:
Maybe the Pirate Roulette thing might be a little to much for some of the gamers. I was just being my ole crazy self in my last post.
Hehe, I was joking too. :-)
Back to top
View user's profile Send private message Visit poster's website
dogcigar
Swabbie
Posts: 82



536 Gold -

PostPosted: Sun Mar 02, 2014 12:37 pm    Post subject: Reply with quote

Ok, if you want to find the general area of code I`d use the cheat engine (like I always do). Now we know that bronze cannons and having a gunner will affect how the gunshot works. get the readme file from Phalyzer`s trainer and it should show you where these items are kept in the registry. You may need to find the offsets for your version of the game (I have found that mine usually differ from everyone as I`m on a mac.

I`d load up a battle and just before letting of some cannons attach the search functions to find out what reads from these values, Hopefully it should get you into the general area of code.
Back to top
View user's profile Send private message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Sun Mar 02, 2014 7:34 pm    Post subject: Reply with quote

Well, I found the code that launches the cannonballs but it's about 70 pages of inscrutable logic. I'm slowly chipping away at it though, through the very roundabout method of trying to understand the game code generally...

I did discover a number of new things that I don't think anybody has mentioned yet. As a side project I was going to create a wiki where all this information can be centralized, or something, so other modders don't have to start from scratch.
Back to top
View user's profile Send private message Visit poster's website
Pirate
Rigger
Posts: 1964



28235 Gold -

PostPosted: Sun Mar 02, 2014 10:05 pm    Post subject: Reply with quote

Well it sounds like we might have faster cannonballs coming up soon hopefully. As far as the city's I just know some of the basics that has already been discovered by others. I have been trying to figure out mainly about what makes the treasure fleets spawn from one city to the other. Like in the East Indies mod that jlangsdo created I could never see or hear about a treasure fleet until I put some of the actual Spanish Caribbean city's in place of the Spanish city's in the mod. Also the other stuff like prices, population etc.. has got me confused as well.[/quote]
Back to top
View user's profile Send private message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Mon Mar 03, 2014 12:23 am    Post subject: Reply with quote

Pirate wrote:
Well it sounds like we might have faster cannonballs coming up soon hopefully.
In a week, maybe. I keep getting distracted with other things to figure out. :-P

Pirate wrote:
I have been trying to figure out mainly about what makes the treasure fleets spawn from one city to the other.
Coincidentally, I mostly figured that out a couple hours ago. It's not simple to describe, though not super complex either. Want me to describe it?
Back to top
View user's profile Send private message Visit poster's website
Captain Teague
Rigger
Posts: 1161



11805 Gold -

PostPosted: Mon Mar 03, 2014 12:42 am    Post subject: Reply with quote

NO! NO MORE DISTRACTIONS!!! I NEED FASTER CANNONBALLS!!! JK, but I am really excited for it. Sailor
_________________
The Code is the Law.
Back to top
View user's profile Send private message
AdamMil
Cutthroat
Posts: 274



4481 Gold -

PostPosted: Mon Mar 03, 2014 10:17 am    Post subject: Reply with quote

Pirate wrote:
I have been trying to figure out mainly about what makes the treasure fleets spawn from one city to the other.
Alright, so here's how the game selects the destination cities for the treasure fleet:

First of all, the game has a hard-coded list of cities: Cumana, Caracas, Puerto Cabello, Coro, Rio de la Hacha, Santa Marta, Cartagen, Puerto Bello, Havana, Havana (again), "Europe" (city ID 45), and "Europe" (45, again). ("Europe" is an invisible city so when the ships 'dock' there it looks like they've gone off the map to Europe.)

The game remembers its position in the list. The initial position is randomly selected to be either Cumana or Caracas.

Once per year in February it checks if there are any ships in the treasure fleet. If not, it does two things: 1) change the destination city and 2) spawn a new treasure fleet. It changes the current city by advancing further in the list by either one or two places (randomly). When it gets to the end of the list, it goes back to the beginning (back to either Cumana or Caracas, again chosen at random). Also, the game always skips over cities that are not Spanish or "Europe". If the new city is not Spanish (or "Europe"), it will try each of the remaining cities in order until it finds one that's suitable. Then the game tries to spawn a treasure fleet that heads towards the city. The fleet has either 3 or 4 ships. They spawn in the vicinity of the second invisible "Europe" city (ID 46).


Last edited by AdamMil on Tue Mar 04, 2014 1:58 am; edited 4 times in total
Back to top
View user's profile Send private message Visit poster's website
Captain Teague
Rigger
Posts: 1161



11805 Gold -

PostPosted: Mon Mar 03, 2014 12:50 pm    Post subject: Reply with quote

AdamMil wrote:
Pirate wrote:
I have been trying to figure out mainly about what makes the treasure fleets spawn from one city to the other.
Alright, so here's how the game selects the destination cities for the treasure fleet:

First of all, the game has a hard-coded list of cities: Cumana, Caracas, Puerto Cabello, Coro, Rio de la Hacha, Santa Marta, Cartagen, Puerto Cabello (again), Havana, Havana (again), "Europe" (city ID 45), and "Europe" (45, again). ("Europe" is an invisible city so when the ships 'dock' there it looks like they've gone off the map to Europe.)

The game remembers its position in the list. The initial position is randomly selected to be either Cumana or Caracas.

Each month, it changes the current city by advancing further in the list by either one or two places (randomly). When it gets to the end of the list, it goes back to the beginning (back to either Cumana or Caracas, again chosen at random). Also, the game always skips over cities that are not Spanish or "Europe". If the new city is not Spanish (or "Europe"), it will try each of the remaining cities in order until it finds one that's suitable.

After selecting the new city for a given month, the game tries to spawn a treasure fleet that heads towards the city. The fleet has either 3 or 4 ships. They spawn in the vicinity of the second invisible "Europe" city (ID 46).

It also advances the current treasure city in the same way in some particular condition that I haven't looked at much yet. Something like: when there are no more ships in the treasure fleet and <something I'm not sure about yet>.


Does the fleet always have 3-4 ships? Because I play most of my games in 1680 and the fleet usually has only 2 ships.
_________________
The Code is the Law.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Customization & Modding All times are GMT
Goto page 1, 2, 3, 4, 5, 6  Next
Page 1 of 6

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group