• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[JASS] AddLightning question

Status
Not open for further replies.
Level 12
Joined
Mar 23, 2008
Messages
942
Well, I'm trying to connect two units with a line, so I found this function using the search:

JASS:
native AddLightningEx takes string codeName, boolean checkVisibility, real x1, real y1, real z1, real x2, real y2, real z2 returns lightning

But, what is that string codeName? What do I put there?
Edit: Also what native boolean checkVisibility does?
 
Level 40
Joined
Dec 14, 2005
Messages
10,532
I imagine CheckVisibility has to do with fog of war.

As for the lightning names, there are two ways to get them.

Way 1 (good for custom lightnings): check the SLK table which defines lightnings (it's called something like LightningData.slk).

Way 2: Select the lighting effect in the "Lightning effect" field of an ability, then press Ctrl+D (View as Raw Data) and it will show the lightning name-string, which is four characters long.
 
Status
Not open for further replies.
Top