Dead Zone

Dan

The New Helper.Net gives me great Anxiety... o.O;;
Reaction score
159
I have a persistent with a search area that fires an effect. It is not entirely obvious how I would add a minimum radius to the search area so that it can't find units within the first few yards when it scans for targets. Would I have to do with with a validator or is there an easier way?
 

hopy

Active Member
Reaction score
64
If I understand correctly you could just add a certain condition to the units you pick (depending on your trigger, this could be via the unit pick event conditions, or via an If/else). Let the condition check if the distance between the picked unit's position and the centre of the region is smaller than x.
"Distance between (picked unit position Point) and (centre of region) < 500"

Something like that.
 

Siretu

Starcraft 2 Editor Moderator
Reaction score
293
If I understand correctly you could just add a certain condition to the units you pick (depending on your trigger, this could be via the unit pick event conditions, or via an If/else). Let the condition check if the distance between the picked unit's position and the centre of the region is smaller than x.
"Distance between (picked unit position Point) and (centre of region) < 500"

Something like that.
That would be a good solution if Dan was doing this with triggers. However, judging from his post, it seems like he's trying to accomplish it with the data editor.

As for a data solution, I have to say I haven't done anything like it before. However, there are two ways that I'd try if I were you. Either with the "Search: Exclude +" field. or with a validator. For the search: exclude field, I think you need to create a new search effect with a smaller radius(which will target the units to exclude) and add it in the search: exclude field(set the value to target, if it doesn't work, try around with other values as well.).

I think a validator would be easier. Make a Detect range validator and set the unit to caster and other unit to target. Set the compare to "Greater than" and the value to the range to exclude.

To add the validator to the search effect, I _think_ you shouldn't add it to the search (since I think that'll be checked when the search is started, not for every target it finds) instead you should put it in the effect that you run on the targets.

Let's say you have a blast ability which has a search effect and a damage effect that is run on the units it finds in the search effect. In that case, put the validator on the damage effect.
 

Dan

The New Helper.Net gives me great Anxiety... o.O;;
Reaction score
159
I tried a detect range validator previous to posting and didn't have any luck. The validator worked somehow because it stopped the ability from firing at all. I'll give it another try tonight... It seems logical though.

I need to do it through the data editor btw because it's tied to a periodic search area, and a trigger would be complicated and clunky.
 

hopy

Active Member
Reaction score
64
That would be a good solution if Dan was doing this with triggers. However, judging from his post, it seems like he's trying to accomplish it with the data editor.
I ... didn't even know that was possible! :D Sorry if my awnser was useless, I'm used to this kind of stuff only being possible with triggers, and attempting to help people who help me.
 

Dan

The New Helper.Net gives me great Anxiety... o.O;;
Reaction score
159
Hopy, I sincerely appreciate all the help you can give. These threads can sometimes be brainstorm sessions until the OP figures out the solution to the problem they are facing. Nothing is completely ruled out until an answer is found.

In any case, you would be surprised what can be done through the data editor alone.
 

Siretu

Starcraft 2 Editor Moderator
Reaction score
293
The fact that the validator stopped your ability from firing at all makes it seem like you added the validator to the search effect instead of the damage effect.
 
  • Like
Reactions: Dan

Dan

The New Helper.Net gives me great Anxiety... o.O;;
Reaction score
159
So I finally now just got to my map work again. The validator works fine as long as I set it to the "Launch missile" effect and not the search area. I never figured that you would pick all units in radius and then validate if they were within range. My thought process was that I didn't want to even pick all units within the minimum distance to begin with heh.

Thanks Siretu, you truly are a hero in these parts.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top