Jump to content

Help Understanding Script Behavior


Recommended Posts

I am trying to create counter-attack scripts for Germany instead of "Garrison these hexes" scripts. But they are not behaving the way I think they should. The following script activates as soon as Benelux is defeated. While it does not necessarily hurt the Paris drive, the unexpected and inconsistent bahavior is causing a problem in other areas. Note that date is set to 1942. France flag specifies surrendered. And Brest listed as Friendly_Position. Also the tile used to activate on allied unit presence is a land locked tile and the only French unit in the activation region is a cruiser. What am I missing? Thanks for the help!

{

#NAME= Germany Counter-Attacks at Bordeaux

#POPUP=

#FLAG= 1

#TYPE= 2

#COUNTRY_ID= 5

#TRIGGER= 100

#LEVEL= 0

#PLAN_ID= 1

#SIZE= 3

#LENGTH= 1

; Bordeaux

#GOAL_POSITION= 63,21

#DATE= 1942/01/01

#STEAL= 3

; Brest

#FRIENDLY_POSITION= 59,18

; France surrendered

#VARIABLE_CONDITION= 2 [2] [100] [1]

; Berlin not threatened

#TACTICAL_CONDITION= 84,16 [1]

#ACTIVATE_POSITION= 64,23 [2,2] [1,1] [2]

; Cancel if 3 axis units already in region

#CANCEL_POSITION= 65,21 [3,3] [3,3] [1]

}

Link to comment
Share on other sites

I also have a script where the Italian Rome Garrison abandons their post as soon at Italy enters the war. Please help if you know why this script is not working.

{

#NAME= Italy Garrison - Rome

#POPUP=

#FLAG= 1

#TYPE= 2

#COUNTRY_ID= 6

#TRIGGER= 100

#LEVEL= 0

#PLAN_ID= 0

#SIZE= 1

#LENGTH= 1

; Rome - a must garrison 24x7x365

#GOAL_POSITION= 83,24

#DATE= 1939/09/03

#STEAL= 0

#FRIENDLY_POSITION= 83,24

; Italy politically Axis and not surrendered

#VARIABLE_CONDITION= 6 [1] [50] [0]

#TACTICAL_CONDITION= 83,24 [3]

#ACTIVATE_POSITION= 0,0 [0,0] [0,0] [0]

#CANCEL_POSITION= 0,0 [0,0] [1,1] [0]

}

Link to comment
Share on other sites

IF the intention of the second script is for Italy to leave Rome after the Italians join the war, then it won't work because you have the variable condition at 50% or above. When they join the war they are still above 50%(100), so the script will still be active.

Also, I would set the tactical condition to 84,16, since Rome CAN be navally threatened.

Link to comment
Share on other sites

ND, Thanks for the help.

Relative to the Italy script, no intention was for the Rome garrison to be permanent. But the garrison leaves when Itlay goes to 100%. I suspect is has to do with the tactical condition even thought AI report (~) does not show as such. I will set to Berlin and see if behavior is changed.

Relative to first script, the AI grabs uncommitted units or steals units from the Paris Offensive and sends them toward Bordeaux (in 1940 of course). If I understand the script variable settings this should not be happening for three different control # settings. Does the Activate_Position override everything else?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...