[Spell] How Toggle Abilities work.

Level 2
Joined
Jun 17, 2012
Messages
17
How does Toggle Abilities work.

Hello I'm trying to figure out how I should proceed, in order to do this.
I have designed a spell.
How will it work...
:goblin_good_job:

When it is toggled off. increase the damage on auto attacks by Xor%.
When it is toggled on. remove the previous power, and reduce the damage taken by Xor% (have not made up numbers yet)

I thought that perhaps it was possible to copy the inner fire and modify it but I ran into the problem that I can not do so it gives an effect when it is off.

Pure and simple, it's a switch between either reduce damage taken, or do more damage with auto attack.
 
Last edited:
Level 2
Joined
Jun 17, 2012
Messages
17
What is the difference between toggle and activate ?

Toggle - Right-click ?
Activate - Activating the spell via clicking it (Left-click) ?

Sorry, I was a little unclear.
There is no difference and it's not something I even thought of.
But to make things clearer, I want it to circulate through
1> 2
when it is clicked.

so when it is on 1. And someone clicks then it jump to 2. And is it 2. And someone clicks then it jump to 1.

As ... an on off switch just that it does something when it is off.

Or maybe I didn't understand your question. xD
 
Level 2
Joined
Jun 17, 2012
Messages
17
What happens when that ability is toggled on/off + the player left-click the ability ?

toggled off
  • name- ATTACK
  • what happens- DAMAGE INCREASE
toggled on
  • name- PARRY
  • what happens- DECREASE DAMAGE TAKEN

left click- nothing happens
 
Level 2
Joined
Jun 17, 2012
Messages
17
I made a preist and looked up his "heal" spell.

If I left-clicked I got the targeting cursor I assume that is "nothing happens"?

Right-click is toggle ability.

I just wanna shift between 2 different states by using 1 button(with a swirly golden thing around it xD).

Is it not possible? Any clue what spell to copy from?
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
As I said the target cursor would appear, what if the player targets a unit ?
Therefore creating an additional order to that unit making it, not a "nothing happens" action.

It is best to make "nothing happens" auto-cast based from instant-cast auto-cast ability such as Faerie Shift but when the player activates it, it will give the spell benefit to that unit (to evade all types of damage for period of time even it is 0.01 second).

Therefore no such thing as "nothing happens" order by default auto-cast ability, well I'm experimenting on something, could give a result, could not.
 
Level 14
Joined
Aug 8, 2010
Messages
1,022
You can use a loop trigger that picks all the units that have the "Attack" spell, order a dummy to cast inner fire and then add the picked units to a group that prevents dummies from casting inner fire to the same picked unit. I mean - you have a group. If the unit is out of it - create a dummy that casts inner fire on the picked unit AND adds it to the group. If the unit is IN the group - do nothing (because the picked unit is in the group which means that it has inner fire because there is no other way the unit can be in the group).

If the picked units DON'T have the "Attack" spell, this means that they have the "Parry" spell. There you do the same but with different group and with a dummy spell that increases armor (you can just make two copies of inner fire - the first adds damage for the "Attack" spell and the second adds armor for the "Parry" spell).

Hope i helped! :]
 
Level 2
Joined
Jun 17, 2012
Messages
17
You can use a loop trigger that picks all the units that have the "Attack" spell, order a dummy to cast inner fire and then add the picked units to a group that prevents dummies from casting inner fire to the same picked unit. I mean - you have a group. If the unit is out of it - create a dummy that casts inner fire on the picked unit AND adds it to the group. If the unit is IN the group - do nothing (because the picked unit is in the group which means that it has inner fire because there is no other way the unit can be in the group).

If the picked units DON'T have the "Attack" spell, this means that they have the "Parry" spell. There you do the same but with different group and with a dummy spell that increases armor (you can just make two copies of inner fire - the first adds damage for the "Attack" spell and the second adds armor for the "Parry" spell).

Hope i helped! :]

I'm not sure if I saw what you did there.
btw, The player will only have 1 hero-unit at all times.

:)

Furthermore, why do you need it auto-cast ?
Can't you just make 2 abilities that can switch vice-versa to each other ?
A default ability would be either +Damage or +Damage Reduction.

Well... don't you need a toggle ability to get that yellow swirling thing around the button?
And I want them to be on the same spot in the spellmenu. !!!>On eachother<.!!!
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
Well... don't you need a toggle ability to get that yellow swirling thing around the button?
Do you want the auto-cast for cool effects only ? Okay.

And I want them to be on the same spot in the spellmenu. !!!>On eachother<.!!!
You can Add/Remove ability you know.
When Ability A is used, remove Ability A and add Ability B, Ability B will take the slot in Ability A.
 
Top