Not real channeling spell

Ritmas

New Member
Reaction score
0
Is it possible to make an ability which is channeling, but while you channel you can only move?

if not - is it possible to detect stuns and other interrups with casting?
 

TomTTT

New Member
Reaction score
44
You can trigger the channel... When the unit begins casting the ability, add it to a unit group and set time to channel = (channel time) [Suggested use Hashtables...] and if it attacks, remove it from the group. If you want help with triggers, just say :p
 

Cookie!

Member
Reaction score
0
I suppose you could make the spell a non channeling spell, and trigger its effect like so:

Trigger:
  • Spell Begin
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Not_Really_A_Channeling_Spell
    • Actions
      • Set Spell_Caster = (Casting unit)
      • Set Spell_Target = (Target unit of ability being cast)
      • Trigger - Turn on Spell_Effect <gen>


Trigger:
  • Spell_Interrupt
    • Events
      • Unit - A unit is attacked
      • Unit - A unit Starts the effect of an ability
      • Unit - A unit Is issued an order targeting a unit
    • Conditions
      • (Attacked Unit has buff of type Not_Really_A_Channeling_Spell (caster)) Equal to True
    • Actions
      • Trigger - Turn off Spell_Effect <gen>
      • Unit - Remove Not_Really_A_Channeling_Spell (caster) buff from Attacked Unit


Where Spell_Effect is a trigger that runs periodically and gives the actual effect of your ability.

You may have to split the second trigger into three triggers, one for each event, or, you could declare a boolean variable, to store whether the spell is being cast or not, and check for the variable's state in the conditions instead.
 

Bogrim

y hello thar
Reaction score
154
There's a better solution to this. Make the channeling spell a transformation and disable the alternate unit's attack (assuming you were literal when you meant only move), then trigger the effect when the transformation ends. This will also give you the nice "channeling" bar on the unit where you can change the text through the transformation's buff.

If you want the spell to have a target, have the transformation ability passively disabled on the unit. Make an instant target ability and then enable the transformation ability when the unit has used the ability, ordering the unit to use the transformation right after with your trigger.
 

Ritmas

New Member
Reaction score
0
I suppose you could make the spell a non channeling spell, and trigger its effect like so:

Trigger:
  • Spell Begin
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Not_Really_A_Channeling_Spell
    • Actions
      • Set Spell_Caster = (Casting unit)
      • Set Spell_Target = (Target unit of ability being cast)
      • Trigger - Turn on Spell_Effect <gen>


Trigger:
  • Spell_Interrupt
    • Events
      • Unit - A unit is attacked
      • Unit - A unit Starts the effect of an ability
      • Unit - A unit Is issued an order targeting a unit
    • Conditions
      • (Attacked Unit has buff of type Not_Really_A_Channeling_Spell (caster)) Equal to True
    • Actions
      • Trigger - Turn off Spell_Effect <gen>
      • Unit - Remove Not_Really_A_Channeling_Spell (caster) buff from Attacked Unit


Where Spell_Effect is a trigger that runs periodically and gives the actual effect of your ability.

You may have to split the second trigger into three triggers, one for each event, or, you could declare a boolean variable, to store whether the spell is being cast or not, and check for the variable's state in the conditions instead.

This is what I'm looking for mainly, but will it get stopped if the caster gets stunned?
 

Cookie!

Member
Reaction score
0
This is what I'm looking for mainly, but will it get stopped if the caster gets stunned?

If the stun comes from an enemy unit (which I presume it will), it will set off the Unit Is Attacked event, interrupting the pseudo-channeling.

Edit
I just realized that the last event "A unit is issued an order targeting another unit" will fire for follow orders as well. You'll probably want to split the trigger and check to see if the orderstring is "attack" on that one.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top