About orbs, enabling attacks

Kazuga

Let the game begin...
Reaction score
110
Hello, in my map all players have one hero each. The heroes attacks are both disabled. Attack 1 is melee, attack 2 is ranged. When a hero picks up a weapon (let's say a sword) a unit orb ability representing that sword is added to the hero enabling it's attack 1 (melee). If he picks up a bow he receives a unit orb ability for that bow enabling his attack 2 (ranged). The projectiles is replaced via the orb as well so it can be different ones depending on what bow your equipping. (This was a tip for everyone else, if you would like to do somewhat the same sometime.)

Now to the problem, when my hero equips a bow, he can shoot at ranged distance, just like he should. But if he equips a sword, even though that orb ability is to unlock attack 1, he becomes ranged anyway. I tried using "enabled attack index: 0" but then he couldn't attack at all.

Why does "enabled attack index: 1" enable the second one?
 

Zwiebelchen

You can change this now in User CP.
Reaction score
60
Hello, in my map all players have one hero each. The heroes attacks are both disabled. Attack 1 is melee, attack 2 is ranged. When a hero picks up a weapon (let's say a sword) a unit orb ability representing that sword is added to the hero enabling it's attack 1 (melee). If he picks up a bow he receives a unit orb ability for that bow enabling his attack 2 (ranged). The projectiles is replaced via the orb as well so it can be different ones depending on what bow your equipping. (This was a tip for everyone else, if you would like to do somewhat the same sometime.)

Now to the problem, when my hero equips a bow, he can shoot at ranged distance, just like he should. But if he equips a sword, even though that orb ability is to unlock attack 1, he becomes ranged anyway. I tried using "enabled attack index: 0" but then he couldn't attack at all.

Why does "enabled attack index: 1" enable the second one?
I think this is because hero attacks are somewhat hardcoded. You also do not really see the UI display of the second attack. Orbs seem to only activate the second attack, but can not activate the first one.

Why dont you use attack 1 as a default and simply add an attack 2 orb for all ranged weapons?
 

Kazuga

Let the game begin...
Reaction score
110
Why dont you use attack 1 as a default and simply add an attack 2 orb for all ranged weapons?
Because, if attack 1 is enabled as a default, and I then enable attack 2 with an orb, he will still attack melee.
 

Zwiebelchen

You can change this now in User CP.
Reaction score
60
i think there was an orb system somewhere. Just check the usual websites (hive, wc3c, etc.) and maybe you will find it.
 
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