How to mod port bonus range?

A forum to discuss custom scenarios, campaigns and modding in general.

Moderators: Slitherine Core, The Lordz

Post Reply
Kossatx
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 241
Joined: Wed Nov 27, 2013 3:27 pm

How to mod port bonus range?

Post by Kossatx »

Hi! A few years ago I changed the port bonus range, but now I can't remember how I did it :? I thought it was in the game.lua file, but I don't find it there. Anyone can help me?
Robotron
Brigadier-General - Elite Grenadier
Brigadier-General - Elite Grenadier
Posts: 2151
Joined: Tue Nov 23, 2010 3:35 pm

Re: How to mod port bonus range?

Post by Robotron »

Open game_supply.lua

look for the function called: "function AddPortSupply(alliance, hex)"

look for the line that reads:
hexes = game.map:GetHexesInRange(hex, 2)

change "2" to whatever number you want to change the range of the home water combat bonus.
Image
Slitherine's Commander the Great War - Director's Cut: POTZBLITZ mod!
FIND IT HERE: http://www.slitherine.com/forum/viewtopic.php?f=218&t=77884&p=662610#p662610
Kossatx
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 241
Joined: Wed Nov 27, 2013 3:27 pm

Re: How to mod port bonus range?

Post by Kossatx »

Robotron wrote: Tue Jul 24, 2018 2:43 pm Open game_supply.lua

look for the function called: "function AddPortSupply(alliance, hex)"

look for the line that reads:
hexes = game.map:GetHexesInRange(hex, 2)

change "2" to whatever number you want to change the range of the home water combat bonus.
Thanks a lot Robotron! :D
Post Reply

Return to “Commander the Great War : Mods & Scenario Design”