Reoccuring Decision Question

Please post here for questions and discussion about modding for Strategic Command.
Post Reply
User avatar
Lothos
Posts: 1330
Joined: Tue May 23, 2006 8:22 pm

Reoccuring Decision Question

Post by Lothos »

Trying to figure out what happens with the following situation

You have a decision with

#TYPE= 2

And then you have events in the amphibious.txt file that are LINK(ed) to that decision with a [1] (Yes)

What happens if the Decision trigger conditions became TRUE so its a [1] but then latter the events conditions then became false does will the conditions still be marked as [1] and the events that are LINK(ed) to it will continue to fire or will they stop firing?

This is of-course assuming the LINKED events are also set with #TYPE= 2
User avatar
BillRunacre
Posts: 6890
Joined: Mon Jul 22, 2013 2:57 pm
Contact:

Re: Reoccuring Decision Question

Post by BillRunacre »

The triggered events will continue providing their own conditions continue to be met in all other respects.
Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/
User avatar
Lothos
Posts: 1330
Joined: Tue May 23, 2006 8:22 pm

Re: Reoccuring Decision Question

Post by Lothos »

BillRunacre wrote: Tue Jun 14, 2022 1:43 pm The triggered events will continue providing their own conditions continue to be met in all other respects.
When I did my tests the trigger condition keeps sending out a true example LINK= 631[1]

Even when it was true but the condition is no longer valid so 631 should not be either 1 or 0 it should be nothing

So for example

- 1/1/1940 Event 631 fires and its sub conditions
- 11/1/1940 Event 631 conditions are no longer true but because it fired once (back on 1/1/1940) all the LINK commands still fire
User avatar
BillRunacre
Posts: 6890
Joined: Mon Jul 22, 2013 2:57 pm
Contact:

Re: Reoccuring Decision Question

Post by BillRunacre »

I'm referring to all the other conditions in the script will need to still be relevant, i.e. the Decision event has fired and if it's a Type= 1 script, that is only checked the once.

So let's say that the Decision fires in one turn, and the other conditions are met later on, at that later point the script can fire.

However, if the other conditions are met before the Decision fires, then the script won't fire unless other conditions remain in effect.

Hopefully that explains it better?
Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/
User avatar
Lothos
Posts: 1330
Joined: Tue May 23, 2006 8:22 pm

Re: Reoccuring Decision Question

Post by Lothos »

BillRunacre wrote: Tue Jun 14, 2022 7:10 pm I'm referring to all the other conditions in the script will need to still be relevant, i.e. the Decision event has fired and if it's a Type= 1 script, that is only checked the once.

So let's say that the Decision fires in one turn, and the other conditions are met later on, at that later point the script can fire.

However, if the other conditions are met before the Decision fires, then the script won't fire unless other conditions remain in effect.

Hopefully that explains it better?
My apologies, it is hard to explain this

Assume the Decision is a TYPE= 2

The Decision Fired because all conditions are true
xxx[1]

Since it is a TYPE= 2 decision it fires every turn and keeps sending out xxx[1] because the decision is a hidden one with AI RESPONSE = 100

So two turns go by and now the conditions of the trigger are no longer true and it DOES NOT execute (fire)

Is the game engine then still registering a xxx[1] or is the xxx no longer valid and clear out so any sub-events that are LINKed to it will no longer fire?

Hopefully that explains it better.
User avatar
Hubert Cater
Posts: 6094
Joined: Mon Jul 22, 2013 11:42 am
Contact:

Re: Reoccuring Decision Question

Post by Hubert Cater »

If it is a TYPE=2, then what happens is the DECISION event fires, all related events to that DECISION will fire, and then the decided result of that DECISION event, the Yes or No, is reset back to NULL as it is TYPE=2 and will presumably fire again at some point and the Yes or No value will need to be re-established.

If the DECISION event is a TYPE=1 then the result of that event, the YES or NO, persists after that as the DE is removed never to be looked at again.

Hope this helps,
Hubert
Post Reply

Return to “Scenario Design and Modding”