• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Get your art tools and paintbrushes ready and enter Hive's 34th Texturing Contest: Void! Click here to enter!

I have problems with 2 passive Abilities

Level 3
Joined
Nov 1, 2023
Messages
16
I have a problem with this trigger, sometimes when I kill 50 enemies it gives me one agility, sometimes it doesn't. Is it a bug or is there something wrong with the trigger?

  • Agility Bonus On Kills
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set VariableSet Kills_Count[1] = 0
      • Set VariableSet Kills_Count[2] = 0
      • Set VariableSet Kills_Count[3] = 0
      • Set VariableSet Kills_Count[4] = 0
      • Set VariableSet Kills_Count[5] = 0
      • Set VariableSet Kills_Count[6] = 0
  • Add Agility On 50 Kills
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Level of Devotion Aura X for (Killing unit)) Greater than 0
      • ((Killing unit) is A Hero) Equal to True
      • ((Killing unit) belongs to an ally of (Triggering player).) Equal to True
    • Actions
      • Set VariableSet TempUnit = (Killing unit)
      • Set VariableSet Kills_Count[(Player number of (Owner of TempUnit))] = (Kills_Count[(Player number of (Owner of TempUnit))] + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Kills_Count[(Player number of (Owner of TempUnit))] Greater than or equal to 50
        • Then - Actions
          • Hero - Modify Agility of TempUnit: Add 1.
          • Set VariableSet Kills_Count[(Player number of (Owner of TempUnit))] = 0
          • Special Effect - Create a special effect attached to the origin of TempUnit using Abilities\Spells\Items\AIem\AIemTarget.mdl
          • Floating Text - Create floating text that reads +|cff00ffff1|r |cff... above TempUnit with Z offset 50.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 1.00% transparency
          • Wait 2.00 game-time seconds
          • Special Effect - Destroy (Last created special effect)
          • Floating Text - Destroy (Last created floating text)
        • Else - Actions

I made a trigger where you have a 30% chance of a meteorite falling on 4 random enemies within a radius of 1000, the problem is that it doesn't show me the effect of the meteorite falling on their heads and I don't understand why.

  • Meteor Passive
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Level of Devotion Aura X for (Attacking unit)) Greater than 0
      • (Random real number between 1.00 and 100.00) Less than or equal to 30.00
    • Actions
      • Set VariableSet Meteor_Caster = (Attacking unit)
      • Set VariableSet Meteor_Target = (Attacked unit)
      • Set VariableSet Meteor_Group = (Units within 1000.00 of (Position of Meteor_Target) matching ((((Matching unit) belongs to an enemy of (Owner of Meteor_Caster).) Equal to True) and (((Matching unit) is alive) Equal to True)).)
      • For each (Integer Meteor_Loop) from 1 to 4, do (Actions)
        • Loop - Actions
          • Set VariableSet Meteor_RandomUnit = (Random unit from Meteor_Group)
          • If (Meteor_RandomUnit Not equal to No unit) then do (Set VariableSet Meteor_Point = (Position of Meteor_RandomUnit)) else do (Do nothing)
          • Special Effect - Create a special effect at Meteor_Point using Abilities\Spells\Other\Meteor\MeteorMissile.mdl
          • Unit - Create 1 Dummy[Meteor] for (Owner of Meteor_Caster) at (Meteor_Point offset by (0.00, 0.00)) facing Default building facing degrees
          • Unit - Cause Meteor_Caster to damage Meteor_RandomUnit, dealing 30.00 damage of attack type Chaos and damage type Universal
          • Custom script: call RemoveLocation(udg_Meteor_Point)
          • Unit Group - Remove Meteor_RandomUnit from Meteor_Group.
      • Custom script: call DestroyGroup(udg_Meteor_Group)
 
Last edited:
Level 32
Joined
Aug 29, 2012
Messages
1,460
For the 1st trigger, ((Killing unit) belongs to an ally of (Triggering player).) Equal to True means that it only works when you kill an ally unit, is that what you really want?

For the second, does the damage portion work but no effect is shown, or does nothing work at all? You could create the effect at the origin of the affected unit instead of relying on points to see if that's any better.
 
Level 12
Joined
Aug 24, 2022
Messages
437
Does your meteor trigger works? I mean, just the special effect doesn’t play?

I suggest changing “unit is attacked” to “unit takes damage”, since the first one can be triggered without finishing the attack.

Did you try to remove the integer 1 to 4? Check if it works completely with only one target.

I didn’t see anything wrong for now, so my suggestion is to cut your trigger line by line and test it until it works entirely.



EDIT: I also suggest to insert “Game Message” below each line of your spell, to print on the screen if the correct value is being set. Like that random number between 1 and 100. With this, you’ll have a visual feedback about how your trigger is working.
 
Last edited:
Top