Page 1 of 1

Editing file for deduct 1 oil from a 6 oil counter

Posted: Wed Aug 05, 2026 2:44 pm
by Lvieira
Need to deduct 1 Oil from a 6 Oil counter.

Thanks
Luís

Re: Editing file for deduct 1 oil from a 6 oil counter

Posted: Wed Aug 05, 2026 5:16 pm
by rkr1958
Lvieira wrote: Wed Aug 05, 2026 2:44 pm Need to deduct 1 Oil from a 6 Oil counter.

Thanks
Luís
(1) As I always recommend making a backup copy of your game file before attempting any edits.

(2) In the example below I'm going to reduce the number of saved oil in London from 2 to 3.

(3) Calculate the encode hex location (EHL) of where the oil is saved (e.g., London EHL = 25116)
999-CW-Oil-Edit-1.png
999-CW-Oil-Edit-1.png (645.96 KiB) Viewed 80 times
(4) Next, locate the oil point counter by searching on EHL (e.g. 25116 = London).

(5) EHL is the 8th value of the unit status record (i.e., USR(8)).

(6) If the oil counter is stacked with other game counters (in my case US HQ), you'll encounter this value in USR(8) a number of times before you'll run across the oil counter.

(7) The first record for the game records set for the oil counter will be of the form: ,CID,69,1936

(8) In this specific case, CW CID =201 so the first record for my oil counter of interest was: ,201,69,1936

(9) The number of oil points is defined in USR(12) = 256 x # Oil points.

(10) Use that formula to reduce/increase the number of oil points at that location; which in my example I set USR(12) = 512
999-CW-Oil-Edit-2.png
999-CW-Oil-Edit-2.png (104.25 KiB) Viewed 80 times
(11) Load your edited game file to confirm.

(12) If you didn't get it right then you can continue editing until you do or screw up your game file beyond repair in which case you'll just go back to your backup copy of your game file.
999-CW-Oil-Edit-3.png
999-CW-Oil-Edit-3.png (540.84 KiB) Viewed 80 times

Re: Editing file for deduct 1 oil from a 6 oil counter

Posted: Wed Aug 05, 2026 10:40 pm
by Lvieira
Many Thanks

Worked like a Swiss clock

Re: Editing file for deduct 1 oil from a 6 oil counter

Posted: Thu Aug 06, 2026 11:18 am
by rkr1958
Lvieira wrote: Wed Aug 05, 2026 10:40 pm Many Thanks

Worked like a Swiss clock
You're welcome.