Best way to make a spawned unit devour guys using triggers?

Synoscope

New Member
Reaction score
1
The best, I think, would be to cast the ability on-attack but I have so many units doing bad stuff like this on-attack it would start becoming "DONT EVER LET SOMETHING ATTACK YOU- THE GAME."

So please don't suggest

Code:
Event
    A unit is attacked
Condition
    Attacking unit is abomination
Action
    Order attacking unit to Devour PlayerUnitArray[1]
Unless there truly isn't another way.

What I'm wanting (and not sure how to go about) is this unit to spawn, and then cast Devour on someone from a unit array (each player has 1 unit)

I tried

Code:
Event
    Every 60 seconds of game time
Action
    Create on Abomination (this is the unit with the devour skill)
    Order last created unit to Orc Kodo Devour PlayerUnitArray[Random number between 1 and 12]


He will be distracted by anything using this trigger and attack the towers and shit attacking him. I want him to bull-true towards a target and just devour the him (to say he doesn't run away and wait for the abomination to be dropped)

I don't know if setting his acquisition range will help. Last time I had it really low (100) he would only even try to devour enemies right on top of him and only about 50% of the time.
 

Exide

I am amazingly focused right now!
Reaction score
448
I'm not sure what you want here..
But I'd spawn a *Devour Unit*, assign a variable to it and then have a trigger check every X seconds, set *DevourUnitGroup*, order *devourunitvariable* to Orc Kodo Devour *Random unit from DevourUnitGroup*, then, of course, clean up the leaks.
 

vaziocs

New Member
Reaction score
5
Set TempUnitGroup = (Units within 512.00 of (Center of (Playable map area)))
Unit Group - Pick every unit in TempUnitGroup and do (Actions)
Loop - Actions
For each (Integer A) from 1 to 10, do (Actions)
Loop - Actions
Set zz[(Integer A)] = (Picked unit)
Unit - Order Catcher to Orc Kodo Beast - Devour zz[(Integer A)]


maybe this. zz is an unit array
and instead of unit is attacked use unit life.
and set the tempgroup to the condition u want.
 

Synoscope

New Member
Reaction score
1
Set TempUnitGroup = (Units within 512.00 of (Center of (Playable map area)))
Unit Group - Pick every unit in TempUnitGroup and do (Actions)
Loop - Actions
For each (Integer A) from 1 to 10, do (Actions)
Loop - Actions
Set zz[(Integer A)] = (Picked unit)
Unit - Order Catcher to Orc Kodo Beast - Devour zz[(Integer A)]


maybe this. zz is an unit array
and instead of unit is attacked use unit life.
and set the tempgroup to the condition u want.


An altered form of this worked very well. Thank you
 

vaziocs

New Member
Reaction score
5
An altered form of this worked very well. Thank you
i had put a random unit there somewhere
dont have world editor now but probably in Set zz[(Integer A)] = (Picked unit)

instead of picked unit , random unit from tempunitgroup.
and u helped me in other topic i owed u one, didnt test if it worked but anyway.
 
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