• Check out the results of the Techtree Contest #19!
  • 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 void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

[Trigger] Ranking buff for units gone wrong.

Problem.png

When I make a custom race, a custom unit (which is a killing unit) receives a rank buff, but the buff belongs to dying unit. Feel free to ask, TY.
 
Please post your triggers instead of using screenshots :peasant-grin:
 
  • Ranking to Sergeant
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Killing unit) belongs to an enemy of (Owner of (Dying unit)).) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Killing unit) belongs to an enemy of (Owner of (Dying unit)).) Equal to True
          • (Level of Ascension Rank for (Killing unit)) Less than 1
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to ((Level of Ascension Rank for (Killing unit)) + 1)
        • Else - Actions
          • Trigger - Run Sergeant Rank <gen> (checking conditions)
          • Unit - Increase level of Ascension Rank for (Killing unit)
 
And this:
  • Ranking to Lieutenant
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
          • (Level of Ascension Rank for (Killing unit)) Less than 5
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to ((Level of Ascension Rank for (Killing unit)) + 1)
        • Else - Actions
          • Special Effect - Destroy Sergeant
          • Wait 0.50 seconds
          • Unit - Increase level of Ascension Rank for (Killing unit)
          • Trigger - Run Lieutenant Rank <gen> (checking conditions)
 
Everytime when a player unit kills an enemy, it grants a promotion, means increasing attack damage. Here are the rest:
  • Ranking to Lieutenant
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
          • (Level of Ascension Rank for (Killing unit)) Less than 5
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to ((Level of Ascension Rank for (Killing unit)) + 1)
        • Else - Actions
          • Special Effect - Destroy Sergeant
          • Wait 0.50 seconds
          • Unit - Increase level of Ascension Rank for (Killing unit)
          • Trigger - Run Lieutenant Rank <gen> (checking conditions)
  • Ranking to Captain
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
          • (Level of Ascension Rank for (Killing unit)) Less than 10
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to ((Level of Ascension Rank for (Killing unit)) + 1)
        • Else - Actions
          • Special Effect - Destroy Lieutenant
          • Wait 0.50 seconds
          • Unit - Increase level of Ascension Rank for (Killing unit)
          • Trigger - Run Captain Rank <gen> (checking conditions)
  • Ranking to Major
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
          • (Level of Ascension Rank for (Killing unit)) Less than 15
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to ((Level of Ascension Rank for (Killing unit)) + 1)
        • Else - Actions
          • Special Effect - Destroy Captain
          • Wait 0.50 seconds
          • Unit - Increase level of Ascension Rank for (Killing unit)
          • Trigger - Run Major Rank <gen> (checking conditions)
  • Ranking to General
    • Events
      • Unit - A unit Dies
    • Conditions
      • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) belongs to an enemy of (Owner of (Killing unit)).) Equal to True
          • (Level of Ascension Rank for (Killing unit)) Less than 20
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to ((Level of Ascension Rank for (Killing unit)) + 1)
        • Else - Actions
          • Special Effect - Destroy Major
          • Wait 0.50 seconds
          • Unit - Increase level of Ascension Rank for (Killing unit)
          • Trigger - Run General Rank <gen> (checking conditions)
 
Or this:
  • Rank to Sergeant
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • Set VariableSet SergeantKills = (SergeantKills + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • SergeantKills Less than 1
        • Then - Actions
          • Unit - Set level of Ascension Rank for (Killing unit) to 1
          • Trigger - Run Sergeant <gen> (checking conditions)
        • Else - Actions
  • Rank to Lieutenant
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • Set VariableSet LieutenantKills = (LieutenantKills + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • LieutenantKills Less than 5
        • Then - Actions
          • Special Effect - Destroy Sergeant
          • Wait 0.50 seconds
          • Unit - Set level of Ascension Rank for (Killing unit) to 2
          • Trigger - Run Lieutenant <gen> (checking conditions)
        • Else - Actions
  • Rank to Lieutenant
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • Set VariableSet LieutenantKills = (LieutenantKills + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • LieutenantKills Less than 5
        • Then - Actions
          • Special Effect - Destroy Sergeant
          • Wait 0.50 seconds
          • Unit - Set level of Ascension Rank for (Killing unit) to 2
          • Trigger - Run Lieutenant <gen> (checking conditions)
        • Else - Actions
  • Rank to Captain
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • Set VariableSet CaptainKills = (CaptainKills + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • CaptainKills Less than 10
        • Then - Actions
          • Special Effect - Destroy Lieutenant
          • Wait 0.50 seconds
          • Unit - Set level of Ascension Rank for (Killing unit) to 3
          • Trigger - Run Captain <gen> (checking conditions)
        • Else - Actions
  • Rank to Major
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • Set VariableSet MajorKills = (MajorKills + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • CaptainKills Less than 15
        • Then - Actions
          • Special Effect - Destroy Captain
          • Wait 0.50 seconds
          • Unit - Set level of Ascension Rank for (Killing unit) to 4
          • Trigger - Run Major <gen> (checking conditions)
        • Else - Actions
  • Rank to General
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • Set VariableSet GeneralKills = (GeneralKills + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • GeneralKills Less than 20
        • Then - Actions
          • Special Effect - Destroy Major
          • Wait 0.50 seconds
          • Unit - Set level of Ascension Rank for (Killing unit) to 5
          • Trigger - Run General <gen> (checking conditions)
        • Else - Actions
 
Or even this:
  • Ascension Rank Kills Gain Attack Speed
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Level of Ascension Rank (Attack Speed) for (Killing unit)) Equal to 1
        • Then - Actions
          • Player - Enable Ascension Rank (Attack Speed) for (Owner of (Killing unit))
          • Wait 0.50 seconds
          • Unit - Set level of Ascension Rank (Attack Speed) for (Killing unit) to 1
          • Trigger - Run Sergeant <gen> (checking conditions)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Level of Ascension Rank (Attack Speed) for (Killing unit)) Equal to 3
            • Then - Actions
              • Unit - Set level of Ascension Rank (Attack Speed) for (Killing unit) to 2
              • Trigger - Run Lieutenant <gen> (checking conditions)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Level of Ascension Rank (Attack Speed) for (Killing unit)) Equal to 5
                • Then - Actions
                  • Unit - Set level of Ascension Rank (Attack Speed) for (Killing unit) to 3
                  • Trigger - Run Captain <gen> (checking conditions)
                • Else - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Level of Ascension Rank (Attack Speed) for (Killing unit)) Equal to 7
                    • Then - Actions
                      • Unit - Set level of Ascension Rank (Attack Speed) for (Killing unit) to 4
                      • Trigger - Run Major <gen> (checking conditions)
                    • Else - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • (Level of Ascension Rank (Attack Speed) for (Killing unit)) Equal to 10
                        • Then - Actions
                          • Unit - Set level of Ascension Rank (Attack Speed) for (Killing unit) to 5
                          • Trigger - Run General <gen> (checking conditions)
                        • Else - Actions
 
Back
Top