Devour

lopp231

New Member
Reaction score
3
I made a custom Devour for a hero, and it's not working! :( When I click on an enemy unit nothing happens, my hero won't devour it. But if i click on my own unit it will say can't target friendly units? Whats up?
 

WastedSavior

A day without sunshine is like, well, night.
Reaction score
217
It's been a while since i've played around with devour, but take a look at a kodo or a dragon, see what abilities they have, i think devour needs a cargo to function
 

WastedSavior

A day without sunshine is like, well, night.
Reaction score
217
Find the below field on your hero
Code:
Abilities - Normal - (Add the ability devour cargo)
 

lopp231

New Member
Reaction score
3
New problem!
I want to give the player who devours a creep bonus gold based on the devoured unit's bounty. Example: A creep is worth 100 gold, my hero devours it, when the creep is dead, the hero gets +110 gold. So my trigger would be something like
unit dies
unit dies from devour (maybe?)
add property to player owner of unit casting devour or something?
help me! =]
 

Doom-Angel

Jass User (Just started using NewGen)
Reaction score
167
hmmm well i dunno if devour has buff to detect but try doing something like this:
Code:
Event
    A unit start the effect of an ability
Conidtion
   (Ability being cast) Equal to Devour  
Action
   Set Devoured_Unit = Target Unit of ability being cast
Code:
Event
    A unit Dies
Condition
    (Triggering unit) equal to Devoured_Unit
Action
    Add property.....
i dunno if devour has target unit but anyway if it doesn't have than detect the killing unit and just turn on and off the 2nd trigger everytime (of course u should make a few changes)
anyway hope i helped


--------------------------------------------------------------------------------------------------------------
"We are still looking for Jassers"
 

lopp231

New Member
Reaction score
3
Thank you, that was helpful!
But is there an action to add a property that isn't a set number. Like instead of gaining 10 gold, you gain 10% of the unit's bounty?
 

Doom-Angel

Jass User (Just started using NewGen)
Reaction score
167
Code:
Set Integer = Current gold owned by player 1 (Red)/10
here's a 10% of player's bounty i hope u got the point
 

lopp231

New Member
Reaction score
3
Not 10% of your total gold, 10% of the devoureded unit's bounty.
Example: A creep is worth 100 gold, when you finish devouring him you get 110 gold.
A creep is worth 50 gold, when you finish devouring him you get 55 gold.
Or you get 25% of the unit's bounty.
So a creep is worth 100 gold, when you finish devouring him you get 125 gold.
And so on..
 

Doom-Angel

Jass User (Just started using NewGen)
Reaction score
167
i don't think it's possible to detect the unit's bounty unless u detect like the already given bounty after death and add 10% more....
 
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