Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

What's wrong with this string of scripts?

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [New Releases from Matrix Games] >> Strategic Command Series >> Strategic Command WWII War in Europe >> Scenario Design and Modding >> What's wrong with this string of scripts? Page: [1]
Login
Message << Older Topic   Newer Topic >>
What's wrong with this string of scripts? - 12/22/2018 1:09:23 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
Hi, I've made this string of two scripts. The first one (#DECISION= 106) works perfectly, but the second one (#DECISION= 107) don't. I have done a lot of testings, but I can't find any error The coordinates are ok, and the #TRIGGER value is changed to 100% for testings. Anyone has suggestions about?

quote:


;Once Germany is without oil reserves (105) starts oil shortage.
{
#NAME= DE 106 1/2 - Germany oil shortage (Trigger 30%) 1/2
#POPUP=
#IMAGE=
#SOUND=
#FLAG= 1
#TYPE= 2
#AI= 0
#LEVEL= 0
#GV= 1[1,100]
#LINK= 105[1]
#COUNTRY_ID= 45
#TRIGGER= 100
#DISPLAY_ORDER= 0
#DECISION= 106
#MPP_UPDOWN= 0
#MPP_TURNS= 0
#MPP_TEXT=
#NOTES=
#NOTES_POSITION=
#AI_RESPONSE= 100
#AI_RESPONSE_POPUP=
#DATE= 1939/09/02
#TEXT_RGB= 0,0,0
#SHADOW_RGB= 0,0,0
#ALIGNMENT_POSITION= 141,28 [1]
#ALIGNMENT_POSITION= 1,24 [2]
#ALIGNMENT_POSITION= 191,44 [2]
#NATIONAL_MORALE_TRIGGER= 0 [0]
#VARIABLE_CONDITION= 45 [1] [100] [0]
#CONDITION_POSITION= 185,51 [0,0] [0,0] [2] [0]
#CONDITION_POSITION= 185,51 [0,0] [0,0] [0] [0]
}

;Once Germany is without oil reserves (105) starts oil shortage.
{
#NAME= DE 106 2/2 - Germany oil shortage (100%) 2/2
#POPUP=
#IMAGE=
#SOUND=
#FLAG= 1
#TYPE= 2
#AI= 0
#LEVEL= 0
#GV= 1[1,100]
#LINK= 106[1]
#COUNTRY_ID= 45
#TRIGGER= 100
#DISPLAY_ORDER= 0
#DECISION= 107
#MPP_UPDOWN= -90
#MPP_TURNS= 1
#MPP_TEXT= Oil shortage
#NOTES=
#NOTES_POSITION=
#AI_RESPONSE= 100
#AI_RESPONSE_POPUP=
#DATE= 1939/09/02
#TEXT_RGB= 0,0,0
#SHADOW_RGB= 0,0,0
#ALIGNMENT_POSITION= 141,28 [1]
#ALIGNMENT_POSITION= 1,24 [2]
#ALIGNMENT_POSITION= 191,44 [2]
#NATIONAL_MORALE_TRIGGER= 0 [0]
#VARIABLE_CONDITION= 45 [1] [100] [0]
#CONDITION_POSITION= 191,58 [0,0] [0,0] [2] [0]
#CONDITION_POSITION= 191,58 [0,0] [0,0] [0] [0]
}


< Message edited by Kossatx -- 12/23/2018 2:58:59 PM >
Post #: 1
RE: What's wrong with this string of scripts? - 12/22/2018 6:27:20 PM   
BillRunacre

 

Posts: 4945
Joined: 7/22/2013
Status: offline
Hi Kossatx

The #CONDITION_POSITION= in the second script are different to those in the first one.

Does DE 106 work if it has the same #CONDITION_POSITION= as DE 105?

If so then it must be that.

_____________________________

Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/

(in reply to Kossatx)
Post #: 2
RE: What's wrong with this string of scripts? - 12/22/2018 6:50:12 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
Thanks BillRunacre, but the decision 107 even don't work with a dummy "#CONDITION_POSITION= 0,0 [0,0] [0,0] [0] [0]". The #CONDITION_POSITION are different between 106 and 107 because (if I'm not wrong) is not possible to include the four condition position in the same script and obtain the effect I want. If are all together, if one coordinate is true the other three don't have to be. I want at least one option of each pair to be true.

(in reply to BillRunacre)
Post #: 3
RE: What's wrong with this string of scripts? - 1/23/2019 6:33:44 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
I can't solve this string of two scripts While the first one (#DECISION= 106) triggers ok, the second one (#DECISION= 107) never triggers even though "#CONDITION_POSITION= 191,58 [0,0] [0,0] [2] [0]" or "#CONDITION_POSITION= 191,58 [0,0] [0,0] [0] [0]" are true. Anyone has any idea about this?

(in reply to Kossatx)
Post #: 4
RE: What's wrong with this string of scripts? - 1/24/2019 2:24:27 PM   
BillRunacre

 

Posts: 4945
Joined: 7/22/2013
Status: offline
If you remove DE 107's link to DE 106, does it then fire?

_____________________________

Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/

(in reply to Kossatx)
Post #: 5
RE: What's wrong with this string of scripts? - 1/24/2019 4:10:29 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
Yes, it works if there is no "DE 106" link, but then the string sequence disappears I don't understand why the "DE 106" link breaks the string

(in reply to BillRunacre)
Post #: 6
RE: What's wrong with this string of scripts? - 1/26/2019 1:11:42 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
I've found why "DE 107" didn't fire. If I change "#TYPE= 2" to "#TYPE= 1" in "DE 106", then "DE 107" fires. I guess there is any incompatibility with "#TYPE= 2" events when included in a string of scripts. If what I say is ok, then I'm not sure if is possible to mod the "Oil shortage" event as I want. How can I write is necessary to fire an event these two conditions must be true every turn?

Condition A. One of these options must be true:
#CONDITION_POSITION= 185,51 [0,0] [0,0] [2] [0]
#CONDITION_POSITION= 185,51 [0,0] [0,0] [0] [0]

Condition B. And one of these two options must also be true:
#CONDITION_POSITION= 191,58 [0,0] [0,0] [2] [0]
#CONDITION_POSITION= 191,58 [0,0] [0,0] [0] [0]

(in reply to Kossatx)
Post #: 7
RE: What's wrong with this string of scripts? - 1/26/2019 1:37:30 PM   
BillRunacre

 

Posts: 4945
Joined: 7/22/2013
Status: offline
Hi Kossatx

What is the relevance of there being no Allied units at these locations?

Could this be done instead by adding them to the #ALIGNMENT_POSITION= as being in Axis hands?

_____________________________

Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/

(in reply to Kossatx)
Post #: 8
RE: What's wrong with this string of scripts? - 1/26/2019 2:35:38 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
I don't know how to fire the event saying "if positions A and B aren't in Axis hands", so I've used the "CONDITION_POSITION" command to say "if positions A and B are in neutral or allied hands". If I'm not wrong, only one of the "CONDITION_POSITION" commands included in an script must be true to fire, that's the reason I divided them in two pairs:

For DE 106:
#CONDITION_POSITION= 185,51 [0,0] [0,0] [2] [0]
#CONDITION_POSITION= 185,51 [0,0] [0,0] [0] [0]

For DE 107:
#CONDITION_POSITION= 191,58 [0,0] [0,0] [2] [0]
#CONDITION_POSITION= 191,58 [0,0] [0,0] [0] [0]

Maybe there is a better way to do it, but I don't know

< Message edited by Kossatx -- 1/26/2019 2:49:10 PM >

(in reply to BillRunacre)
Post #: 9
RE: What's wrong with this string of scripts? - 1/28/2019 2:40:33 PM   
BillRunacre

 

Posts: 4945
Joined: 7/22/2013
Status: offline
If you add more #ALIGNMENT_POSITION= to the first Decision then you can do that, as there can be more than one of those in the script.

Then you won't need the second Decision, at least that's what I'm thinking from looking at this.

_____________________________

Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/

(in reply to Kossatx)
Post #: 10
RE: What's wrong with this string of scripts? - 1/28/2019 7:20:11 PM   
Kossatx

 

Posts: 97
Joined: 8/16/2015
From: Spain
Status: offline
But if I write more than one "ALIGNMENT_POSITION" they will be read with AND logic, so if I write this it has no sense... not? Is not possible a place to be occupied by Allies and neutrals

#ALIGNMENT_POSITION= 191,58 [2]
#ALIGNMENT_POSITION= 191,58 [0]

(in reply to BillRunacre)
Post #: 11
RE: What's wrong with this string of scripts? - 1/30/2019 2:08:47 PM   
BillRunacre

 

Posts: 4945
Joined: 7/22/2013
Status: offline
If the neutral is pro-Allied then it should still work with a setting of 2

It may be that you could use two different scripts, one for when place X is Allied but Y is Axis, another for when both are Allied, etc.

_____________________________

Follow us on Twitter: https://twitter.com/FurySoftware

We're also on Facebook! https://www.facebook.com/FurySoftware/

(in reply to Kossatx)
Post #: 12
Page:   [1]
All Forums >> [New Releases from Matrix Games] >> Strategic Command Series >> Strategic Command WWII War in Europe >> Scenario Design and Modding >> What's wrong with this string of scripts? Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

1.422