Hero get exp if creeps are fighting and revive event

Arberden

Active Member
Reaction score
0
Firstly, I want to ask how to disable giving hero exp unless they are near enough. I tried a search but cant get the right keywords.

Secondly, I like to know if there is a event which states hero has revive ability and is dead awaiting revival.If there is none in GUI is there any in jass?
 

HydraRancher

Truth begins in lies
Reaction score
197
Advanced > Gameplay Constants


Revive ability? Do you mean the ability to be revived at an altar? What possible implications do you need?
 

Arberden

Active Member
Reaction score
0
First one done thanks.
For the revive i mean tauren cheiftains revive. I want to damage the area around the place he died.
Another question.Is there a binary system in WE.I want to add to the max life of a unit and have been trying to use a sort of binary system to do so.
So first binary adds 1 hp, second 2hp, third 4hp and so on and if i want 6 i can get second and third to get 6 hp.
Is there any system around here that can do that.
 

HydraRancher

Truth begins in lies
Reaction score
197
I think there isn't a way to track when the tauren uses his ability, so I'm not sure how to go around doing that.



For binary, yes. Although you'll have to use Item Life Bonus ability for such a thing.

First Ability has
Level 1: +0
Level 2: -1

So you add the First ability, then set it to level 2 and remove it. This glitch will permanently add 1 HP.

Ability 2

Level 1: +0
Level 2: -2

This will add 2 life when you apply it correctly.


This should produce the required effect.
 

HydraRancher

Truth begins in lies
Reaction score
197
You'd need to do some parsing.


http://www.wikihow.com/Convert-from-Decimal-to-Binary

Like this^

EDIT:

Something like,

On Initialization, set Binary[1] = 1, Binary[2] = 2, Binary[3] = 4, etc. All the way up to Binary[10], let's say. Then do Set NumberOfBinary = 10



INPUT is the value that you are converting into binary.


Trigger:
  • Trigger
    • Events
    • Conditions
    • Actions
      • --------------Your Actions------------
      • Set CurrentValue = INPUT
      • Set BinaryLimit = 0
      • For each (Integer A) from 1 to NumberOfBinary do (Actions)
        • Loop - Actions
          • If (All Conditions are true) do (Actions) else do (Actions)
            • If - Conditions
              • Binary[(Integer A)] is Greater than or Equal to CurrentValue
              • BinaryLimit is Equal to 0
            • Then - Actions
              • Set BinaryLimit = (Integer A)
              • Else - Actions
      • For each (Integer A) from 1 to BinaryLimit do (Actions)
        • Loop - Actions
          • If (All Conditions are true) do (Actions) else do (Actions)
            • If - Conditions
              • Binary[((Binary Limit - (Integer A) + 1)] is Greater than or Equal to CurrentValue
            • Then - Actions
              • Set BinaryResult = ((BinaryResult * 10) + 0)
              • Else - Actions
                • Set CurrentValue = (CurrentValue - Binary[((Binary Limit - (Integer A) + 1)])
                • Set BinaryResult = ((BinaryResult * 10) + 1)


I haven't tested it, but that's the general idea. To check if the value is larger than a power of two, then to minus it, and write down 1.
 
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