• 💀 Happy Halloween! 💀 It's time to vote for the best terrain! Check out the entries to Hive's HD Terrain Contest #2 - Vampire Folklore.❗️Poll closes on November 14, 2023. 🔗Click here to cast your vote!
  • 🏆 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!
  • 🏆 HD Level Design Contest #1 is OPEN! Contestants must create a maze with at least one entry point, and at least one exit point. The map should be made in HD mode, and should not be openable in SD. Only custom models from Hive's HD model and texture sections are allowed. The only exceptions are DNC models and omnilights. This is mainly a visual and design oriented contest, not technical. The UI and video walkthrough rules are there to give everyone an equal shot at victory by standardizing how viewers see the terrain. 🔗Click here to enter!

[Spell] Life Binder (Lightning Problem)

Status
Not open for further replies.
Level 5
Joined
Aug 14, 2020
Messages
118
Hi guys, I'm trying to create a spell with lightning effect but I keep getting this error.

Untitled.png


I can't find the problem it's showing this line as error
  • Custom script: set udg_LifeBind_Light = AddLightningEx("HLFX", true , GetLocationX(udg_LifeBind_LocA), GetLocationY(udg_LifeBind_LocA), GetLocationZ(udg_LifeBind_LocA) + 70, GetLocationX(udg_LifeBind_LocB), GetLocationY(udg_LifeBind_LocB), GetLocationZ(udg_LifeBind_LocB) + 70)
can some1 help me plz?

here are all triggers:

  • LifeBind
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Life Binder
    • Actions
      • -------- Target unit --------
      • Set LifeBind_Target = (Target unit of ability being cast)
      • -------- -------------------------------------------------------------------------------------- --------
      • -------- Locations --------
      • Set LifeBind_LocA = (Position of Alleria)
      • Set LifeBind_LocB = (Position of LifeBind_Target)
      • -------- -------------------------------------------------------------------------------------- --------
      • Custom script: set udg_LifeBind_Light = AddLightningEx("HLFX", true , GetLocationX(udg_LifeBind_LocA), GetLocationY(udg_LifeBind_LocA), GetLocationZ(udg_LifeBind_LocA) + 70, GetLocationX(udg_LifeBind_LocB), GetLocationY(udg_LifeBind_LocB), GetLocationZ(udg_LifeBind_LocB) + 70)
      • Set LifeBind_Heal = (5.00 x (Real((Level of Life Binder for Alleria))))
      • Set LifeBind_Bol = True
      • Trigger - Turn on LifeBindLoop <gen>
      • Wait (3.00 + (3.00 x (Real((Level of Life Binder for Alleria))))) seconds
      • Set LifeBind_Bol = False
  • LifeBindLoop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • LifeBind_Bol Equal to True
        • Then - Actions
          • Set LifeBind_LocA = (Position of Alleria)
          • Set LifeBind_LocB = (Position of LifeBind_Target)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Distance between LifeBind_LocA and LifeBind_LocB) Less than or equal to 800.00
            • Then - Actions
              • Custom script: call MoveLightningEx(udg_LifeBind_Light, true, GetLocationX(udg_LifeBind_LocA), GetLocationY(udg_LifeBind_LocA), GetLocationZ(udg_LifeBind_LocA) + 70, GetLocationX(udg_LifeBind_LocB), GetLocationY(udg_LifeBind_LocB), GetLocationZ(udg_LifeBind_LocB) + 70)
              • Unit - Set life of Alleria to ((Life of Alleria) + LifeBind_Heal)
              • Unit - Set life of LifeBind_Target to ((Life of LifeBind_Target) + LifeBind_Heal)
            • Else - Actions
              • Set LifeBind_Bol = False
        • Else - Actions
          • Trigger - Turn off (This trigger)
          • Set LifeBind_Target = No unit
          • Lightning - Destroy LifeBind_Light
          • Custom script: call RemoveLocation(udg_LifeBind_LocA)
          • Custom script: call RemoveLocation(udg_LifeBind_LocB)
 

Uncle

Warcraft Moderator
Level 58
Joined
Aug 10, 2018
Messages
5,859
I remember reading that Custom script that was too long would cause problems. Try shortening the script by using shorter variable names and Setting the X/Y/Z beforehand (again, using shorter variable names).
 
Status
Not open for further replies.
Top