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

How do I change the height of lightning

Status
Not open for further replies.
Level 18
Joined
May 11, 2012
Messages
2,103
native MoveLightning takes lightning whichBolt, boolean checkVisibility, real x1, real y1, real x2, real y2 returns boolean
JASS:
call MoveLightningEx(whichBolt, checkVisibility, x1, y1, z1, x2, y2, z2)
the z1 and z2 are the height coordinates.

Whaa? Haha
So how do I implement this?
I have a lightning and I want it to attach to the chest of the caster and target.
 

Chaosy

Tutorial Reviewer
Level 40
Joined
Jun 9, 2011
Messages
13,183
  • Custom script: call AddLightningEx("DRAL", true, GetLocationX(udg_tloc2), GetLocationY(udg_tloc2), GetLocationZ(udg_tloc2) + 50, GetLocationX(udg_tloc), GetLocationY(udg_tloc), GetLocationZ(udg_tloc) + 295)
This creates a lightning between tloc and tloc2. However, tloc 2 got 50 height and tloc 295 height.

to move the lightning use MoveLightningEx(stuff) instead. Replace DRAL with the lightning of your choice and copy the rest.

To actually understand how to use this properly, go a to a basic jass tutorial and check the section where they call a function.
 
Status
Not open for further replies.
Top