Jagger
AGEod Grognard
Posts: 949
Joined: Sat Mar 18, 2006 2:31 pm

Modding question on Drafts/Volunteers

Thu Oct 25, 2007 10:58 pm

I have created a new scenario with altered volunteer and draft modifiers. So the initial values are set and working.

Now I am wondering whether it is possible to change volunteer/draft modifiers once the game has started considering I had to compile a new scenario to force it to use the modifiers in the first place.

Is it possible to modify the volunteer/draft modifiers once the game is started?

What if I created several gameoption files, referenced all of them within the setup file, then use events in the events page to reference different gameoption files for use at different times in the game?

Would that work?

If not, what would work?

I also altered the monthly conscript numbers by altering the numbers produced per city. Now I am wondering about the best way to reduce monthly conscription numbers. I believe I can use an event to subtract conscripts from the conscript pool each turn which kicks off at certain times. That should work but I am wondering if there is an easier way to reduce monthly conscript numbers?

User avatar
Pocus
Posts: 25673
Joined: Wed Oct 19, 2005 7:37 am
Location: Lyon (France)

Fri Oct 26, 2007 8:11 am

You can change options on the fly, issue another ChangeActorPool with new parameters. If already defined, the new definition will overwrite the old one, if new, it will creates the entry.
The delete an option, use also ChangeActorPool but set MaxUse to 0 in the params.

Conscript production (and others assets prods): Use
ChangeAssetsProd = Supply; Ammo; Power; Money; WSU; Conscript

applied on a region. Positive value augments the asset prod, negative reduces it.
Image


Hofstadter's Law: "It always takes longer than you expect, even when you take into account Hofstadter's law."

User avatar
Rafiki
Posts: 5811
Joined: Thu Aug 24, 2006 9:19 am
Location: Oslo, Norway

Fri Oct 26, 2007 8:53 am

http://ageod.nsen.ch/aacwwiki/ChangeAssetsProd

(To blow the wiki's horn a bit :) )
[CENTER]Latest patches: AACW :: NCP :: WIA :: ROP :: RUS :: PON :: AJE
Visit AGEWiki - your increasingly comprehensive source for information about AGE games
[SIGPIC][/SIGPIC]
[/CENTER]

Jagger
AGEod Grognard
Posts: 949
Joined: Sat Mar 18, 2006 2:31 pm

Fri Oct 26, 2007 4:19 pm

Pocus wrote:You can change options on the fly, issue another ChangeActorPool with new parameters. If already defined, the new definition will overwrite the old one, if new, it will creates the entry.
The delete an option, use also ChangeActorPool but set MaxUse to 0 in the params.

Conscript production (and others assets prods): Use
ChangeAssetsProd = Supply; Ammo; Power; Money; WSU; Conscript

applied on a region. Positive value augments the asset prod, negative reduces it.


Excellent! I found a couple of examples and it will definitely work!

User avatar
lodilefty
Posts: 7616
Joined: Sat Aug 11, 2007 3:27 pm
Location: Finger Lakes, NY GMT -5 US Eastern

OK, I've almost got it....

Thu Jan 03, 2008 8:04 pm

Can you help me how to do this?

I'm trying to restrict the Mobilization draft to start in mid-1862. :sourcil:
I can remove it from 'draft ledger' on the second turn, and make it come back (via events using ChangeActorPool), but I can't prevent it from being there on first turn (April 61 Campaign scenario)..... :grr:

This is my first 'serious' mod, so be gentle !!!!! :siffle:

User avatar
Primasprit
Posts: 1614
Joined: Mon Jun 19, 2006 7:44 pm
Location: Germany

Thu Jan 03, 2008 8:13 pm

Hi lodilefty!

lodilefty wrote:Can you help me how to do this?

I'm trying to restrict the Mobilization draft to start in mid-1862. :sourcil:
I can remove it from 'draft ledger' on the second turn, and make it come back (via events using ChangeActorPool), but I can't prevent it from being there on first turn (April 61 Campaign scenario)..... :grr:

This is my first 'serious' mod, so be gentle !!!!! :siffle:

Any events which are supposed to trigger on the very first turn need to be included in the scenario file itself, not in the event file.

You may create an alternate GameOptions.inc-File for your mod and load it instead of the default one.

Cheers
Norbert

User avatar
lodilefty
Posts: 7616
Joined: Sat Aug 11, 2007 3:27 pm
Location: Finger Lakes, NY GMT -5 US Eastern

Thu Jan 03, 2008 8:59 pm

Primasprit wrote:Hi lodilefty!


Any events which are supposed to trigger on the very first turn need to be included in the scenario file itself, not in the event file.

You may create an alternate GameOptions.inc-File for your mod and load it instead of the default one.

Cheers
Norbert


:bonk: :bonk: :bonk:

I've revised the GameOptions.inc, but it seems to be ignored...

I also tried adding a "draft_mod.inc", "draft_mod.sct", modified 'script.ini' and 'scriptA61.ini', plus tried '1861 April Campaign.sct'. still comes up turn 1 with the 'original' options for Mobilization.....

Script report shows:
Line 19510: ------------------------------
Line 19514: SelectFactions, 1 Faction selected: Confederate States of America
Line 19517: Started processing event: evt_nam_CSA_inactive_draft
Line 19517: This event is not yet referenced, base number of allowed occurences 1
Line 19520: Min date evaluated: 1861/03/01 converted to turn 2669 current turn 2672 True
Line 19521: Max date evaluated: 1861/04/30 converted to turn 2673 current turn 2672 True
Line 19523: Entering triggered actions for event evt_nam_CSA_inactive_draft
Line 19525: SelectFactions, 1 Faction selected: Confederate States of America
Line 19526: ChangeActorPool Confederate States of America Actor entry 5004 has been deleted
Line 19527: ChangeActorPool Confederate States of America Actor entry 5005 has been deleted
Line 19529: Finished processing event: evt_nam_CSA_inactive_draft
Line 19529: ------------------------------
Line 19531: SelectFactions, 1 Faction selected: Confederate States of America
Line 19534: Started processing event: evt_nam_CSA_active_draft
Line 19534: This event is not yet referenced, base number of allowed occurences 1
Line 19537: Min date evaluated: 1861/05/01 converted to turn 2673 current turn 2672 False
Line 19542: SelectFactions, 1 Faction selected: Confederate States of America
Line 19546: Finished processing event: evt_nam_CSA_active_draft
Line 19546: ------------------------------
Line 19548: SelectFactions, 1 Faction selected: United States of America
Line 19551: Started processing event: evt_nam_USA_inactive_draft
Line 19551: This event is not yet referenced, base number of allowed occurences 1
Line 19554: Min date evaluated: 1861/03/01 converted to turn 2669 current turn 2672 True
Line 19555: Max date evaluated: 1862/06/30 converted to turn 2701 current turn 2672 True
Line 19557: Entering triggered actions for event evt_nam_USA_inactive_draft
Line 19558: SelectFactions, 1 Faction selected: United States of America
Line 19559: ChangeActorPool United States of America Actor entry 5004 has been deleted
Line 19560: ChangeActorPool United States of America Actor entry 5005 has been deleted
Line 19562: Finished processing event: evt_nam_USA_inactive_draft
Line 19562: ------------------------------
Line 19564: SelectFactions, 1 Faction selected: United States of America
Line 19567: Started processing event: evt_nam_USA_active_draft
Line 19567: This event is not yet referenced, base number of allowed occurences 1
Line 19570: Min date evaluated: 1862/07/01 converted to turn 2701 current turn 2672 False
Line 19574: SelectFactions, 1 Faction selected: United States of America
Line 19578: Finished processing event: evt_nam_USA_active_draft
Line 19578: ------------------------------
Line 19581: SelectFactions, 1 Faction selected: Confederate States of America
Line 19583: SelectFactions, 1 Faction selected: Confederate States of America
Line 19584: Started processing event: evt_nam_CSA_inactive_draft
Line 19584: Event already referenced, current occurences 1 Max allowed: 1 >>Sleeping<<
Line 19586: Too many occurences for event evt_nam_CSA_inactive_draft further processing aborted.
Line 19592: SelectFactions, 1 Faction selected: Confederate States of America
Line 19596: Finished processing event: evt_nam_CSA_inactive_draft
Line 19596: ------------------------------

Do I have to recompile in edit mode?

User avatar
Primasprit
Posts: 1614
Joined: Mon Jun 19, 2006 7:44 pm
Location: Germany

Thu Jan 03, 2008 9:52 pm

lodilefty wrote: :bonk: :bonk: :bonk:

I've revised the GameOptions.inc, but it seems to be ignored...

I also tried adding a "draft_mod.inc", "draft_mod.sct", modified 'script.ini' and 'scriptA61.ini', plus tried '1861 April Campaign.sct'. still comes up turn 1 with the 'original' options for Mobilization.....

[...]

Do I have to recompile in edit mode?

Yes. To make edited inc-files work you have to recompile the scenario. Only changes in event-files take effect without recompiling the scenario.

So you need to get the scenario DB and change the xls-files of the scenario you like to mod. Even if you do only a few changes I would recommend to change the scenario name, so that the old one is not overwritten. The scenario script will refer to the GameOptions.inc somewhere near the top of the file. Simply replace the file name with the one of your modified Options-file. Also here I recommend not to edit the original GameOptions.inc but to copy it to a new name and make the changes there.
After that as usual: Save as cvs (with semicolon as field delimiter) and convert the file via the CSV-Splitter. Copy the script.ini to the AACW Scripts-directory and run the game in edit mode. Save the game, restart AACW and you are done. :)

Cheers
Norbert

User avatar
lodilefty
Posts: 7616
Joined: Sat Aug 11, 2007 3:27 pm
Location: Finger Lakes, NY GMT -5 US Eastern

Fri Jan 04, 2008 2:39 am

Primasprit wrote:Yes. To make edited inc-files work you have to recompile the scenario. Only changes in event-files take effect without recompiling the scenario.

So you need to get the scenario DB and change the xls-files of the scenario you like to mod. Even if you do only a few changes I would recommend to change the scenario name, so that the old one is not overwritten. The scenario script will refer to the GameOptions.inc somewhere near the top of the file. Simply replace the file name with the one of your modified Options-file. Also here I recommend not to edit the original GameOptions.inc but to copy it to a new name and make the changes there.
After that as usual: Save as cvs (with semicolon as field delimiter) and convert the file via the CSV-Splitter. Copy the script.ini to the AACW Scripts-directory and run the game in edit mode. Save the game, restart AACW and you are done. :)

Cheers
Norbert


Got it, and it appears to work! :niark:
(I did it via editing the files, as I got tangledup in csv formats. Now that I know what to do, I'll read the forums and do it 'right') :siffle:

Thanx for your help! :coeurs:

Return to “Modding AGE engine games”

Who is online

Users browsing this forum: No registered users and 9 guests