• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

order a unit to cast a spell based on "Channel"?

Status
Not open for further replies.
Level 2
Joined
Apr 13, 2011
Messages
13
I think you can't do this. If you want to make some kind of AI for a unit that has na ability based on Channel, make this via dummy units. Channel based spells are made for human player only.
(At least as far as I know)
 
Level 28
Joined
Jan 26, 2007
Messages
4,789
The channel spell hads an order ID (Data - Base Order Id, e.g.: "thunderbolt"). This order ID represents what should be used in the GUI action (in the case of "thunderbolt", it should be the Mountain King's Storm Bolt).

Note that this isn't always possible in GUI: if you gave a unit-target spell the order ID "thunderclap", then you won't be able to use it (as "thunderclap" is listed under "no target").
However, in that case, you can still use the JASS-form IssueTargetOrder(caster, "thunderclap", target).

Other JASS-functions:
JASS:
call IssuePointOrderLoc(caster, "order", location)
call IssueImmediateOrder(caster, "order")

I hope this made sense.
 
Level 6
Joined
Jul 26, 2010
Messages
167
I think I found a better way some minutes ago: call IssueTargetOrder (unit, "channel", targetUnit).

However what I was trying to do is make a unit cast mana shield on another unit trought this spell, but I have no idea how and so far I'm failing a big time :ogre_icwydt:
 
Level 6
Joined
Jul 26, 2010
Messages
167
The channel spell hads an order ID (Data - Base Order Id, e.g.: "thunderbolt"). This order ID represents what should be used in the GUI action (in the case of "thunderbolt", it should be the Mountain King's Storm Bolt).

Note that this isn't always possible in GUI: if you gave a unit-target spell the order ID "thunderclap", then you won't be able to use it (as "thunderclap" is listed under "no target").
However, in that case, you can still use the JASS-form IssueTargetOrder(caster, "thunderclap", target).

Other JASS-functions:
JASS:
call IssuePointOrderLoc(caster, "order", location)
call IssueImmediateOrder(caster, "order")

I hope this made sense.

xD I think I typed that above while u where typing the answer, thnx anyways apocalypse. Ehm don't you know how I do that I said?
 
Status
Not open for further replies.
Top