| 11-19-2003, 03:31 AM | #1 |
I want to give units a blink ability (which i know how to) but when i have 12 selected and click blink once i want them ALL to blink over not just one of them, how do i do this??? |
| 11-19-2003, 06:59 AM | #2 |
Trigger. Event: Unit is issued an order targeting a point Conditions: Triggering unit is X Ability being cast is Blink Actions: Order unit group (selected units) to (blink) targeting (targeted point) |
| 11-19-2003, 01:45 PM | #3 | |
Quote:
That will crash the game, try this: Event: Unit is issued an order targeting a point Conditions: Unit type of Triggering unit equal to X Ability being cast is Unit Blink Actions: turn off this trigger Pick Every unit in (Units selected by (owner of triggering unit)) --Order picked unit to ("blink") to (targeted point) turn on this trigger And also, remember that questions go to the map development forum, this forum is for working code only. |
| 11-19-2003, 09:02 PM | #4 |
only 1 problem though what if i got units in the group that dont even have 'blink' then there gonna be blinked as well... remember starcraft if u order a unit to lets say... zergling burrow, they all burrow... or at least the ones with the ability. i want to do that with wc3, and not just for blink but for moves like firebolt... and stuff |
| 11-19-2003, 09:06 PM | #5 |
I think you're wrong - if the unit doesn't have blink, then being ordered to blink won't make it blink. blink blink blink |
| 11-19-2003, 09:07 PM | #6 |
aight i was wrnog but what about firebolt? lots of units cast it at once like zerg burrowed in sc at once |
| 11-19-2003, 09:10 PM | #7 |
I think the same method will work - only you'll have to do Event: Unit is issued an order targeting an object Conditions: order string is equal to firebolt Actions: turn off this trigger Pick Every unit in (Units selected by (owner of triggering unit)) --Order picked unit to firebolt target unit of issued order turn on this trigger |
| 12-11-2003, 03:43 PM | #8 |
I have a custom ability based off of mana burn. I made a seperate function using the code below, but they don't cast it -- any ideas? In a nutshell, the first function says: When Ghitu Fire-Eater casts Order(manaburn) on a unit, reduce the Targeted unit's life and kill the Ordered unit And for the multi-casting: When Ghitu Fire-Eater casts Order(manaburn) on a unit, [turn off trig] Pick every unit selected by the owner of the Ordered unit and order that unit to use Night Elf Demon Hunter - Mana Burn on the Target of issued order [turn on trig]. I checked the JASS and they both use the "manaburn" code so, unless this is a short-coming of the WE, I dunno what's wrong. |
| 12-11-2003, 04:00 PM | #9 |
or, u just use bear blink |
| 12-11-2003, 08:20 PM | #10 |
I've been having alot of strife with this code, so for no reason other than having a lucky guess, I found that this is what actually works: Events: Unit - A unit Is issued an order targeting a point Conditions: (Issued order) Equal to (Order(blink)) Actions: Trigger - Turn off (This trigger) Set point = (Target point of issued order) Unit Group - Pick every unit in (Units currently selected by Player 1 (Red)) and do (Actions) - Loop - Actions - - Unit - Order (Picked unit) to Night Elf Warden - Blink point Trigger - Turn on (This trigger) If you don't assign the point reference to a variable, then only one of the units will blink to the selected spot and the rest will blink towards the center of the map. Maybe one of you gurus could explain why. In addition..... If you have a trigger-based ability being triggered by the order that you're giving the units, you need to have it initially off and only turn it on for the duration of the unit group loop. |
