Staredit Network > Forums > SC2 Assistance > Topic: if any hostile units in region == false
if any hostile units in region == false
Aug 27 2010, 12:55 am
By: Rizz  

Aug 27 2010, 12:55 am Rizz Post #1



First off, I would like to say that I am glad I found this site, as already it has given me more knowledge in SC2 map editor and given me some ideas for making my map better. Now for the problem:

I have attached what I have gotten so far for my trigger 'unit check'. This was basically my workaround for not being able to figure out how to check and see if any units owned by player 15 in the region 'unit check' == false.

What I would like to do for this trigger would be that for any unit that enters 'tele 9' to hold position, become invulnerable, and then wait until all the living units that are in the region 'unit check' to == 0/false. Then when that condition is false, to do the other actions mentioned (create timer/make vulnerable/attack end). I know there are a lot of rendundancies in the trigger, it's basically just me getting fed up with not being able to do what I wanted and trying to find workarounds :D

All I seem to find is unit group conditions like 'Units in region matching condition' or 'Units in unit group within region'. Is there any way I could make this condition?

Thanks in advance for any replies I get :)

Attachments:
Unit check.jpg
Hits: 2 Size: 123.46kb



None.

Aug 27 2010, 2:52 am Roy Post #2

An artist's depiction of an Extended Unit Death

Quote from Rizz
What I would like to do for this trigger would be that for any unit that enters 'tele 9' to hold position, become invulnerable, and then wait until all the living units that are in the region 'unit check' to == 0/false. Then when that condition is false, to do the other actions mentioned (create timer/make vulnerable/attack end).

All I seem to find is unit group conditions like 'Units in region matching condition'
So... Can't you just use a unit group from Units in Region Matching Condition, where the condition is their player owner (15)? Or do you want this to run for all units in the region, regardless of their player owner? If so, just have the matching condition be something like "unit is alive." You could do the same thing for the condition to check that the other region is empty.

I don't understand the context of your 'units in tele 7' variable, but if it's unimportant to what you want to accomplish, you don't need to explain it.

I hope this helps answer your question.




Aug 27 2010, 4:02 am Rizz Post #3



Quote from Roy
So... Can't you just use a unit group from Units in Region Matching Condition, where the condition is their player owner (15)? Or do you want this to run for all units in the region, regardless of their player owner? If so, just have the matching condition be something like "unit is alive." You could do the same thing for the condition to check that the other region is empty.

I don't understand the context of your 'units in tele 7' variable, but if it's unimportant to what you want to accomplish, you don't need to explain it.

I hope this helps answer your question.

The variable is my workaround for the timer. what happened before I put that in was that when any unit entered the region 'tele 9', the timer would appear, basically giving me 1-15 timers depending on how many units entered the region. So what I want to do is have either one or two conditions, where any units owned by player 15 in region 'unit check' == false. That way, it will wait for this condition before starting the timer, thus creating it only once, and creating it only when all the units leave the playing area for players 1-6.

Post has been edited 1 time(s), last time on Aug 27 2010, 4:20 am by Rizz.



None.

Aug 27 2010, 5:03 am Rizz Post #4



I think I have this figured out. Thank you Roy for replying, it's what helped me probe further into unit groups to find what I needed.

It ended up being this:

Comparison
Value 1: number of units in unit group
Type: living
- Unit group: units in region matching condition
unit type: any
region: unit check
player: 15
unit filter: excluded: missile,dead,hidden
count: any amount
operator: ==
value 2: 0



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[04:15 am]
DarkenedFantasies -- you eat lots of beans
[03:46 am]
IskatuMesk -- how do i get gas
[11:43 pm]
Moose -- you don't
[10:06 pm]
Zoan -- how do i get minerals
[2026-4-14. : 11:45 pm]
ClansAreForGays -- Anyone wanna played Skewed StarCraft?
[2026-4-14. : 12:07 am]
Vrael -- NudeRaider
NudeRaider shouted: Vrael ranting still is though
you're a gentleman and a scholar, thank you
[2026-4-13. : 10:07 pm]
NudeRaider -- ya why phone people when you can just write letters
[2026-4-13. : 9:37 pm]
IskatuMesk -- I have never and will never own a phone
[2026-4-13. : 9:15 pm]
NudeRaider -- Vrael ranting still is though
[2026-4-13. : 9:14 pm]
ClansAreForGays -- anticapitalism isnt edgy anymore
Please log in to shout.


Members Online: Excalibur