Forum Jump :

Author Message


Posts: 5
Rank:


Level: Member

Country: uk
Location:
Occupation:
Age:
In-game name:

 
#1 Posted at 2012-08-07 10:49        
     
Hi folks.
I realise that this might be pretty obvious to more experienced editors but I’m fairly new to this and despite searching the forums I’m having real trouble using the ‘countSide’ operator with triggers. I am running AA2 plus OA.
If for example I place two teams of 5 East soldiers each on an otherwise empty map and set a trigger as follows:
Size: 0/0
Activated by: Opfor
Way of Activation: Present
Frequency of activation: Once
Timer Timeout Min/Mid/Max: 0/0/0
Condition field: east countSide thislist <= 9
Activation field: hint “trigger fired”
I would expect that as soon as one or more of the East soldiers die, regardless of their position on the map, the trigger should fire and the hint text pop up on screen. However it’s just not working for me and I’m now pulling my hair out trying to work out why.
The trigger fires immediately regardless of the number specified, can be <=9, <= 2, <=90 or <9 doesn’t matter!
If the < sign is changed to > the trigger doesn’t fire at all, even when there are all 10 opfor present.

I can get a similar effect to work using count thislist <=9 so long as I set the size to cover the while map (it doesn’t seem to work if using side 0/0 for some reason??).

Any help would be greatly appreciated and apologies if it’s something that’s already been covered in detail.
Thanks


Author Message


Posts: 20658
Rank:


Level: Super Admin

Country: nl
Location: The Netherlands
Occupation:
Age: 44
In-game name: Foxhound

 
#2 Posted at 2012-08-07 11:03        
     
# Cherry : I would expect that as soon as one or more of the East soldiers die, regardless of their position on the map, the trigger should fire and the hint text pop up on screen.

Nope, cause the trigger is set to size 0 and so does not count the units in thislist since thislist refers to the units inside the trigger area.

The trigger fires immediately regardless of the number specified, can be <=9, <= 2, <=90 or <9 doesn’t matter!

of course, cause there are no east units inside the trigger area (trigger size = 0) so the value is always smaller than what you require it to be.

If the < sign is changed to > the trigger doesn’t fire at all, even when there are all 10 opfor present.

Cause there are never more than 0 units inside the trigger area.

I can get a similar effect to work using count thislist <=9 so long as I set the size to cover the while map (it doesn’t seem to work if using side 0/0 for some reason??).

Well, that is your solution. Make sure the trigger covers the entire erea in which you want to count "thislist".

This post was edited by Foxhound (2012-08-07 11:35, ago)

Visit my family webshop desteigerhoutshop.nl.

Advertisement


Author Message


Posts: 1522
Rank:


Level: Member

Country: uk
Location:
Occupation:
Age:
In-game name:

 
#3 Posted at 2012-08-07 11:16        
     
this works for me but oddly when set to anybody present, I can't see why that should be.
east countSide thislist <= 9



as you say you should be able to get it to work using and OPFOR present like this
{Side _x == EAST} count thislist <=9

You can't use 0,0 size as thislist counts units it finds within the trigger area.

If your trying to check a whole map this will work with 0,0 size triggers as it's checking all units on the map.
east countSide allunits <= 4


Author Message


Posts: 5
Rank:


Level: Member

Country: uk
Location:
Occupation:
Age:
In-game name:

 
#4 Posted at 2012-08-07 11:19        
     
Hi Foxhound.
That does of course make perfect sense, now you've explained it. Thanks for being so clear and quick with your reply. :-)
Cheers

Added 9 minutes later:

Hi F2kSel,
Thanks for the suggestions, I'll have a try with them later, but guess I'm going to have to do some work now :-(
The point about trigger size does make perfect sense but I just didn't think of that at all, just assumed size 0/0 meant search everywhere for all opperators.
Cheers

This post was edited by Cherry (2012-08-07 11:29, ago)






Tags: Editing, Trigger