• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Trigger skill

Status
Not open for further replies.
Level 13
Joined
Oct 27, 2008
Messages
1,176
is this possible with GUI?
its a 2 part skill thats passive

Everytime a unit is attacked
theres a 75 chance
that all enemy units in a 300 radius of attacked unit take damage equal to 2x the attacking units strenght

everytime a unit dies
If killing unit is = to Berserker
Theres a 50% chance
(hero) gets double attack speed
for 20 seconds
 
Level 10
Joined
Jun 16, 2007
Messages
415
This can be easily done, even easier with JASS, but let's just forget about that for now.

  • Events
    • Unit - Unit Is Attacked
  • Conditions
  • Actions
    • If Random Integer between 1 and 4 is not equal to 4 then
      • Skip remaining actions
    • Set tempgroup = Get Units within 300 range of Triggering Unit matching Matching unit belongs to an enemy of owner of Triggering Unit
    • Unit Group - Pick all units in tempgroup and do Actions:
      • Unit - Let Triggering Unit damage Picked Unit for (Get Strength of Triggering Unit)*2 damage of type Magic
    • Custom script: call DestroyGroup(udg_tempgroup) //get rid of leak
And for the second skill:
  • Events
    • Unit - A unit dies
  • Conditions
    • Unit Type of Killing Unit is equal to Berserker
  • Actions
    • If Random Integer between 1 and 2 is equal to 1 then
      • Skip remaining actions
    • Set temppoint = Get Location of Killing Unit
    • Unit - Create Dummy for Owner of Killing Unit at temppoint facing 0 degrees
    • Unit - Add Frenzy Spell (Increases attackspeed by 100%) to Last Created Unit
    • Unit - Order Last Created Unit to Frenzy Killing Unit
    • Unit - Add a 2.00 expiration timer to Last Created Unit
    • Custom script: call RemoveLocation(udg_temppoint) //remove leak
There is two weaknesses to these spells that could easily be fixed with JASS, them being:
1. The first spell will fire before the attack actually hits the hero and even if the attack misses
2. The second spell will not stack
If you use a tiny bit of JASS however, these problems could be solved.


W00T, 333th Post!
 
Level 13
Joined
Oct 27, 2008
Messages
1,176
its 2 different parts 1 is for unit death the other is for attacking
+rep for the first part though
only condition left in both is the skill which i dont know what to base it off yet XD
 
Base condition on the buff, that's how i do it for the passives.

So lets say you use Endurance aura as the base skill, you set everything to 0.00 and targets allowed to self. So you see that it only applies on your hero.

So condition is attacking unit has (<buff> endurance) aura equal to true

Edit:

Here is a random map I've made some time ago, check the spell Corrupted Blood.
The only thing is that it damages single unit not the whole unit group, but i guess you could manage that out =)

Oh, just one more thing now its not MUI, just remove that wait 0.10 and it is ^^
 

Attachments

  • Taste of Death[new].w3x
    155 KB · Views: 51
Level 13
Joined
Oct 27, 2008
Messages
1,176
so these should work?
  • Attacking
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Berserker
      • (Level of Fury for (Triggering unit)) Equal to 1
    • Actions
      • Set B_str[(Player number of (Owner of (Attacking unit)))] = (Strength of (Attacking unit) (Include bonuses))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random integer number between 1 and 4) Less than or equal to 3
        • Then - Actions
          • Set Fury_Group[(Player number of (Owner of (Attacking unit)))] = (Units within 300.00 of (Position of (Attacked unit)) matching (((Triggering unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True))
          • Unit Group - Pick every unit in Fury_Group[(Player number of (Owner of (Attacking unit)))] and do (Actions)
            • Loop - Actions
              • Unit - Cause (Attacking unit) to damage (Picked unit), dealing ((Real(B_str[(Player number of (Owner of (Attacking unit)))])) x 2.00) damage of attack type Normal and damage type Normal
        • Else - Actions
  • Death
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Killing unit)) Equal to Berserker
      • (Level of Fury for (Triggering unit)) Equal to 1
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random integer number between 1 and 2) Equal to 1
        • Then - Actions
          • Set DeathPoint = (Position of (Dying unit))
          • Unit - Create 1 Killer for (Owner of (Killing unit)) at DeathPoint facing Default building facing degrees
          • Unit - Order (Last created unit) to Orc Shaman - Bloodlust (Killing unit)
          • Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
        • Else - Actions
          • Custom script: call RemoveLocation(udg_DeathPoint)
 
Level 10
Joined
Jun 16, 2007
Messages
415
For the first spell, set condition to "Level of Fury greater than 0", instead of equal to 1.
Also, when you created the Fury_Group you did a wrong condition:
Triggering Unit belongs to an enemy of Owner of Triggering Unit

You mean:
Matching Unit belongs to an enemy of Owner of Attacking Unit

You also forgot to destroy the unit group in order to remove the leak and why are you using arrays? You can just use normal variables. The spell doesn't use any timers or waits, so it will automatically be MUI.
 
Level 13
Joined
Oct 27, 2008
Messages
1,176
array cuz there can be more than 1 of the same hero makeing it that if 2 do the same skill or anything like that it could be messed up for one of the players
 
the skill will have more than 1 lvl to it

Don't make 3 different triggers for one spell, just because it deals more damage on each level ^^

Simply use a math formula dunno "90 x level of <ability> for triggering unit"

Same goes for attributes 2 x level of <ability> for triggering unit x attribute agility

So if agility is 50 level of ability is 2 how much damage does it deal?

2 x 2 x 50 = 200 8)
 
Level 13
Joined
Oct 27, 2008
Messages
1,176
i dont make a second trigger i just go
[
  • Attacking
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Berserker
    • Actions
      • Set B_str[(Player number of (Owner of (Attacking unit)))] = (Strength of (Attacking unit) (Include bonuses))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random integer number between 1 and 4) Less than or equal to 3
          • (Level of Fury for (Triggering unit)) Equal to 1
          • Then - Actions
            • Set Fury_Group[(Player number of (Owner of (Attacking unit)))] = (Units within 300.00 of (Position of (Attacked unit)) matching (((Triggering unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True))
            • Unit Group - Pick every unit in Fury_Group[(Player number of (Owner of (Attacking unit)))] and do (Actions)
              • Loop - Actions
                • Unit - Cause (Attacking unit) to damage (Picked unit), dealing ((Real(B_str[(Player number of (Owner of (Attacking unit)))])) x 2.00) damage of attack type Normal and damage type Normal
        • Else - Actions
          • If - Conditions
            • (Random integer number between 1 and 4) Less than or equal to 3
            • (Level of Fury for (Triggering unit)) Equal to 2
        • Then - Actions
          • Set Fury_Group[(Player number of (Owner of (Attacking unit)))] = (Units within 300.00 of (Position of (Attacked unit)) matching (((Triggering unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True))
          • Unit Group - Pick every unit in Fury_Group[(Player number of (Owner of (Attacking unit)))] and do (Actions)
            • Loop - Actions
              • Unit - Cause (Attacking unit) to damage (Picked unit), dealing ((Real(B_str[(Player number of (Owner of (Attacking unit)))])) x 2.00) damage of attack type Normal and damage type Normal
        • Else - Actions
and just change the damage and other stuff
 
Status
Not open for further replies.
Top