• 🏆 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!

MUI Backward's knockback-like trigger

Status
Not open for further replies.
Level 26
Joined
Mar 19, 2008
Messages
3,140
Does this charge realy need to be in hashtables? Sorry, I'm pretty lazy since I made next version of charge few days ago, and remaking it again to hash.. (omg).
Click here if you want to look on my charge anyways. When you enter map, choose bear hero, he got 'Charge' spell with charges bear towards the target.

For normal knockback (pushing backwards) use: this.
 
Level 26
Joined
Mar 19, 2008
Messages
3,140
MAN, charge was in triggers: 'omg man' and so one, rest was turned off, why havent you checked carefully? Tell me that thats not MUI and use waits..

Here you got triggers:
  • Charge main
    • Events
      • Unit - Starts the effect of ability
    • Conditions
      • (Ability being cast) Equal to Charge
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BC_IndexSize Equal to 0
        • Then - Actions
          • Trigger - Turn on explaining is great <gen>
        • Else - Actions
      • Set BC_Speed = 700.00
      • Set BC_IndexSize = (BC_IndexSize + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • JeĹ›li - Warunki
          • BC_IndexSize Większe niĹĽ BC_MaxIndex
        • To - Akcje
          • Set BC_Index[BC_IndexSize] = BC_IndexSize
          • Set BC_MaxIndex = BC_IndexSize
        • Albo - Akcje
      • Set BC_TempInt = BC_Index[BC_IndexSize]
      • Set BC_Caster[BC_TempInt] = (Triggering unit)
      • Set BC_Target[BC_TempInt] = (Target unit of ability being cast)
      • Set BC_Continue[BC_TempInt] = TAK
      • Custom script: call SetUnitAnimationByIndex (udg_BC_Caster[udg_BC_TempInt], 2)
  • Charge loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • For each (Integer BC) from 1 to BC_IndexSize, do (Actions)
        • Loop - Actions
          • Set BC_TempInt = BC_Index[BC]
          • Set BC_TempPoint[1] = (Position of BC_Caster[BC_TempInt])
          • Set BC_TempPoint[2] = (Position of BC_Target[BC_TempInt])
          • Set BC_TempPoint[3] = (BC_TempPoint[1] offset by (BC_Speed / 33.00) towards (Angle from BC_TempPoint[1] to BC_TempPoint[2]) degrees)
          • Custom script: set udg_BCtempX = GetLocationX(udg_BC_TempPoint[3])
          • Custom script: set udg_BCtempY = GetLocationY(udg_BC_TempPoint[3])
          • Custom script: call SetUnitX(udg_BC_Caster[udg_BC_TempInt], udg_BCtempX)
          • Custom script: call SetUnitY(udg_BC_Caster[udg_BC_TempInt], udg_BCtempY)
          • Unit - Make BC_Caster[BC_TempInt] face BC_TempPoint[2] over 0.00 seconds
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (BC_Caster[BC_TempInt] is dead) Equal to True
                  • (BC_Target[BC_TempInt] is dead) Equal to True
            • Then - Actions
              • Set BC_Continue[BC_TempInt] = False
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Distance between BC_TempPoint[3] and BC_TempPoint[2]) Less or equal to 135.00
                • Then - Actions
                  • Set BC_Continue[BC_TempInt] = False
                  • Unit - Create 1 dummy for (Owner of BC_Caster[BC_TempInt]) at BC_TempPoint[2] facing DomyĹ›lna orientacja budynku degrees
                  • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
                  • Unit - Add dummy stun to (Last created unit)
                  • Unit - Set level of dummy stun for (Last created unit) to (Level of Charge [this is true charge] for BC_Caster[BC_TempInt])
                  • Unit - Order (Last created unit) to CzĹ‚owiek - KrĂłl GĂłry: Pocisk Burzy BC_Target[BC_TempInt]
                • Else - Actions
          • Custom script: call RemoveLocation (udg_BC_TempPoint[1])
          • Custom script: call RemoveLocation (udg_BC_TempPoint[2])
          • Custom script: call RemoveLocation (udg_BC_TempPoint[3])
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • BC_Continue[BC_TempInt] Equal to False
            • Then - Actions
              • Custom script: call SetUnitAnimationByIndex (udg_BC_Caster[udg_BC_TempInt], 5)
              • Set BC_Caster[BC_TempInt] = No unit
              • Set BC_Target[BC_TempInt] = No unit
              • Set BC_Index[BC] = BC_Index[BC_IndexSize]
              • Set BC_Index[BC_IndexSize] = BC_TempInt
              • Set BC_IndexSize = (BC_IndexSize - 1)
              • Set BC = (BC - 1)
            • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BC_IndexSize Equal to 0
        • Then - Actions
          • Trigger - Turn off (This trigger)
        • Else - Actions
 
Status
Not open for further replies.
Top