Page 1 of 1
_Regen questions
Posted: Sat Feb 21, 2009 11:00 am
by Hobbes
Hi folks, I'm a bit puzzled about the _Regen options script. In the example I am using to test it (attached) I have set the StartEvent in the _ON script to zero and have a MinDate of October.
However I trigger the _Regen in May and the following turn the event option appears for the player - ignoring the MinDate. Any idea why this is?
I'm also surprised that the
ChgEvtOccurs evt_nam_GBR_Militia1PW_Check|MaxOccurs|1
Changes the _Check event and not the _ON and _AIActivate MaxOccurs.
A last question - what happens if an option is available to a player but he has not yet used it - but the _Regen event fires - I assume the event is just reset without the player noticing anything?
Thanks for any clarification on _Regen.
Cheers, Chris
Posted: Sat Feb 21, 2009 1:07 pm
by lodilefty
Your regen event does not have a mindate, so it will occur every June [turn 5]
ChgEvtOccurs evt_nam_GBR_Militia1PW_Check|MaxOccurs|1
will only affect the one event in bold
Regen can't fire if the option is on because the ActorDisabled will evaluate to false
These are 4 independant, but related events:
_AI is only for the AI, regulates wgen and probability the AI will select the option
_On is only used once, for the very first activation of the option
_check is "the action", checking for the selection, checking the cost, and doing the option
_regen regulates how many more times [if any] the option is activated, and when
It looks like you are trying to tie the availability of this option to another event, or such:
I suggest a mindate [or EvalEvent evt_nam_GBR_Militia1PW_ON|>|0]
in your regen conditions, and a completely separate event to set maxoccurs for the _ON and _AI events....
Posted: Sat Feb 21, 2009 2:06 pm
by Hobbes
lodilefty wrote:Your regen event does not have a mindate, so it will occur every June [turn 5]
ChgEvtOccurs evt_nam_GBR_Militia1PW_Check|MaxOccurs|1
will only affect the one event in bold
Regen can't fire if the option is on because the ActorDisabled will evaluate to false
These are 4 independant, but related events:
_AI is only for the AI, regulates wgen and probability the AI will select the option
_On is only used once, for the very first activation of the option
_check is "the action", checking for the selection, checking the cost, and doing the option
_regen regulates how many more times [if any] the option is activated, and when
It looks like you are trying to tie the availability of this option to another event, or such:
I suggest a mindate [or EvalEvent evt_nam_GBR_Militia1PW_ON|>|0]
in your regen conditions, and a completely separate event to set maxoccurs for the _ON and _AI events....
Many thanks for that Lodi - it's a great help. My main confusion was that I thought _Regen would work on the AI and ON events.
It's all much clearer now!
Thanks, Chris
Posted: Sat Feb 21, 2009 2:41 pm
by lodilefty
Hobbes wrote:Many thanks for that Lodi - it's a great help. My main confusion was that I thought _Regen would work on the AI and ON events.
It's all much clearer now!

Thanks, Chris
To further pontificate, the 'key' to action in the options are the "Actor" commands:
ChangeActorPool turns the option choice as seen in the ledger on or off {using the
$gmaOptionMil|MaxUse|
[color="Red"]1[/color]|} part of the "monster parameters string" [1 = "on", 0 = "off]
ActorEnabled simply does a "true/false" test on the option described in the parameters, where "on" = true
ActorDisabled tests for "off" = true
and
ChangeOption $gmaOptionDip|FRA_Repl_Militia|1 is used {usually in the _AI event} to "select" the option [event language equivalent of 'clicking' on the option in gameplay]
Also note that the "Actors" are hard coded. In WIA, we only use:
$gmaOptionMil
$gmaOptionDip
Posted: Sat Feb 21, 2009 3:36 pm
by Hobbes
Thanks Lodi, much appreciated. I'm going to go through my _Regen events - that was the last thing I wasn't sure of.
I've already done quite a bit of testing and everything apart from _Regen is working fine. I now just need to test for balance and make some NM and VP adjustments.
I can see the light!
Thanks very much, Chris
Posted: Sun Feb 22, 2009 10:54 am
by Hobbes
One thing that is still confusing me - why do many _Regen events have a 0 StartEvent such as evt_nam_GBR_More_OntSq_Regen in 1812?
Surely this will never fire? Is it being set to 1 somewhere?
Cheers, Chris
Posted: Sun Feb 22, 2009 12:55 pm
by lodilefty
Hobbes wrote:One thing that is still confusing me - why do many _Regen events have a 0 StartEvent such as evt_nam_GBR_More_OntSq_Regen in 1812?
Surely this will never fire? Is it being set to 1 somewhere?
Cheers, Chris
No. It is set = 0 so you may only build 1 squadron [from the "_ON event]
Event is only there for an easy mod [or change of heart]

Posted: Sun Feb 22, 2009 8:22 pm
by Hobbes
lodilefty wrote:No. It is set = 0 so you may only build 1 squadron [from the "_ON event]
Event is only there for an easy mod [or change of heart]
Or to confuse modders
Thanks Lodi
Posted: Sun Feb 22, 2009 9:03 pm
by lodilefty
Hobbes wrote:Or to confuse modders

Thanks Lodi
Do you mean that is NOT the objective?
