Ability that gives damage based on an attribute

bane25

New Member
Reaction score
1
Is it possible to make a skill that gives damage based on an attribute, say, intelligence (in other words, make a hero get bonus damage from both a primary attribute and an extra one)? Thanks for helping.
 

Dynamis

New Member
Reaction score
2
Is it possible to make a skill that gives damage based on an attribute, say, intelligence (in other words, make a hero get bonus damage from both a primary attribute and an extra one)? Thanks for helping.

Yes, here is an example:
Iron Tempest
Events
Unit - A unit Begins casting an ability
Conditions
(Ability being cast) Equal to Iron Tempest
Actions
Unit - Cause (Triggering unit) to damage (Target unit of ability being cast), dealing ((Real((Strength of (Casting unit) (Include bonuses)))) x 3.50) damage of attack type Spells and damage type Normal

Just customize any spell that damages (Single target), change the range, set its damage to 0. Change the mana cost & cooldown the way you want it to look, and do all damage through the trigger.
For example, my spell does 3.5x the caster's Strenght as damage and you can even add in a base amount if you'd like.

This can also be done to make a healing spell but is a bit more complicated.
 

Weep

Godspeed to the sound of the pounding
Reaction score
400
Absolutely; make the ability itself deal the base damage, and use a trigger to cause damage proportional to the caster's stats:

Trigger:
  • Zap
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Zap
    • Actions
      • Unit - Cause (Triggering unit) to damage (Target unit of ability being cast), dealing (2.00 x (Real((Intelligence of (Triggering unit) (Exclude bonuses))))) damage of attack type Spells and damage type Magic
 

bane25

New Member
Reaction score
1
I think I was not clear:

I want a passive ability that gives your normal attack bonus damage based off of 2 attributes (obviously a primary one, and an extra one).
I know, this is a whole lot harder than just an ability, but... I wanted to see if it was possible.
Think spiritbreakers skill in dota that gives him damage based on his movespeed.
 

Weep

Godspeed to the sound of the pounding
Reaction score
400
I want a passive ability that gives your normal attack bonus damage based off of 2 attributes (obviously a primary one, and an extra one).
You can do that too. You already want this to be a passive ability, so it works out well: base it off of a buff-placing orb ability (eg. slow poison) and set the ability's stats to have no effect, and use a custom buff. This lets you detect for the presence of the buff with a trigger, so you know when a unit takes damage from an attack.

Because there's no "any unit takes damage" event, you'd need to either set up your own damage detection system (using one trigger with no event for the actual ability, and another with the event "Unit enters Playable Map Area" with actions to add the event "(Triggering Unit) takes damage" to the main ability trigger), or use a system like my GDD which takes care of all that for you.

The main trigger would have the condition that the damaged unit has the buff placed by the dummy orb ability, with actions to remove the buff from the unit and cause the additional damage.

Using GDD it would look like this:
Trigger:
  • Damage Bonus
    • Events
      • Game - GDD_Event becomes Equal to 0.00
    • Conditions
      • (GDD_DamagedUnit has buff Damage Bonus) Equal to True
    • Actions
      • Unit - Remove Damage Bonus buff from GDD_DamagedUnit
      • Unit - Cause GDD_DamageSource to damage GDD_DamagedUnit, dealing (2.00 x (Real((Intelligence of GDD_DamageSource (Exclude bonuses))))) damage of attack type Hero and damage type Normal
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top