Can someone help me find the files I want to edit?
Private: Welcome to the Reef! › Forums › GOF Eras Module 2 download & discussion board › Can someone help me find the files I want to edit?
- This topic has 4 replies, 3 voices, and was last updated 6 years, 6 months ago by Vincent.
-
AuthorPosts
-
-
April 25, 2018 at 12:31 am #6234VincentParticipant
Hi guys, I’ve actually dived into the code and edited a few values for my own game – namely making crew wages a bit cheaper so that I can run a big crew on my frigate. However, there’s still a few things I’d really like to try and edit if I can, but I don’t know where to find the data for them, and I wanted to kow if any of you guys could point me in the right direction.
One thing I’d like to edit is the damage for a regular cannonball, so that they’ll do hull damage equal to a bomb/hotshot round, in hopes of making naval battles progress a bit faster.
Second, I want to know how to edit the prices for ship upgrades and sail color changes, the price of trade licenses from diplomats, and the prices at the brothels. As a bonus, I’d love to edit the price for a tavern room when sex is involved as well.
So, can anyone point me at the files I need to edit to do these things? Bonus points if you can tell me which code lines to edit in the files!
-
April 25, 2018 at 2:07 am #6237JeffreyKeymaster
Cannonball damage depends on a game option in the Mod Options screen: Realistic Cannon Damage, where it will set variable RTBL to 0, 1, or 2
Then, in STORE\initGoods.c there will be several lines to set Goods[GOOD_BALLS].DamageHull = ?
Look further in that same file for Goods[GOOD_BOMBS].DamageHull to find its values and make them match. The good will then require a re-init for an existing game by manually calling InitGoods() in the console or something.
For ship repair costs: DIALOGS\russian\Shipyard\Pirates_Shipyard.c
int cannonWorkPrice = makeint(cannonQ * cannonMax * 360);
int capacityWorkPrice = makeint(shipCapacity * 200 / shipclass);
int SpeedRateWorkPrice = makeint(shipSpeedRate/5 * 80000*6/shipClass);
int MaxCrewWorkPrice = makeint(shipMaxCrew/5 * 500*6 / shipClass);
int HPWorkPrice = makeint(shipHP * 75);
int PointOfSailWorkPrice = makeint(shipPointOfSail/5 * 80000*21/ shipClass);For the sails colors/emblems, that is separate, found in INTERFACE\shipyard.c
ChangeSails()
int icost = sti(RealShips[sti(Pchar.Ship.Type)].SP) * 30;
For Patents: DIALOGS\russian\RelationAgent_dialog.c
pchar.PatentPrice = 8000 + (sti(NPChar.PatentPrice) * sti(pchar.rank));
For brothel prices: loc_ai\LAi_utilites.c
sld.quest.price is where that value is set and depends on town/nation
case “Tortuga”: sld.quest.price = 1000*(rand(4)+5); break;
case “PortRoyal”: sld.quest.price = 1100*(rand(4)+5); break;
case “Panama”: sld.quest.price = 900*(rand(4)+5); break;
case “Marigo”: sld.quest.price = 700*(rand(4)+5); break;
case “Bridgetown”: sld.quest.price = 400*(rand(4)+5); break;
case “FortFrance”: sld.quest.price = 500*(rand(4)+5); break;
case “Charles”: sld.quest.price = 300*(rand(4)+5); break;
case “SantoDomingo”: sld.quest.price = 200*(rand(4)+5); break; -
April 25, 2018 at 3:19 am #6238VincentParticipant
Thanks so much, Jeffrey! That really helps me out a lot. I’m starting to fiddle with the code a little, and I hope to get a bit of help from my cousin to try and understand it better – I have a dream of someday creating a few quests for the game, one of them even being an opening quest for Svendsen similar in concept to the one for Peter Blood. I also want to learn how to make skins for ships, but that’s a matter for another day…
As I said, thanks a bunch!
-
April 26, 2018 at 9:36 pm #6244modernknight1Keymaster
Just let me ask… have you tried the game out on mod options set to vanilla for damage settings? We set them to “In between” as the default. If you think that is too slow, you should try full realistic damage. I actually regularly set my game to those RTBL realistic settings when I become god-like at level 35 or so. With the stock vanilla cannon damage setting set in mod options you can often sink a ship with one or two broadsides fairly early on in the game progression if you have a decently armed ship. This is preposterous. I always like to emphasize that in reality – often – sea battles historically lasted for days and even when a wooden ship was riddled with holes and beyond repair they would still float for hours or days due to their natural buoyancy.
MK
-
April 27, 2018 at 10:07 pm #6254VincentParticipant
I also prefer inbetween settings, MK, but it seemed as if cannonballs were useless damage wise to me. I wanted to tweak their hull damage setting to see if I could make them just a little more effective. So far there has been a small change, but ships are still holding up even after tons of shot has been poured into them – all of my battles have ended due to escape or boarding actions rather than gunnery duels, and I’m fine with that as is.
-
-
AuthorPosts
- You must be logged in to reply to this topic.
by Vincent