• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

How to make a spell deal damage based on attribute?

Status
Not open for further replies.
Level 33
Joined
Mar 27, 2008
Messages
8,035
  • Untitled Trigger 001
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to YourTargetUnitAbility
    • Actions
      • Unit - Cause (Triggering unit) to damage (Target unit of ability being cast), dealing (Real((Strength of (Triggering unit) (Include bonuses)))) damage of attack type Spells and damage type Normal
Which part do you stuck on ?
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
Conversion - Convert Integer To Real > Hero - Hero Attribute

The function is in Integer, default Damage dealt is in Real, that's why you must convert it first to get to Integer, and then there will be that Hero - Hero Attribute function.

I've created a test map for you.
 

Attachments

  • test5.w3x
    12.6 KB · Views: 357
Status
Not open for further replies.
Top