HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Custom Lightning Effects

08-13-2004, 08:28 PM#1
CryoniC
How to create your own custom lightning
What you will need
  • TFT World Editor
  • Microsoft Excel or any other slk editor
  • WinMPQ
  • Paint Shop Pro or similiar program
  • Warcraft 3 Viewer


Step 1
Start by creating a texture in your Paint Program to be used by your lightning you are about to create. For best results use a 256X64 24bit image with a black background for the transparency. I used an existing lightning texture used by the Forked Lightning spell. All of the Lightning textures can be found in the ReplaceableTextures\Weather\ folder. After you have edited your texture to your satisfaction convert it to a BLP file with the Warcraft 3 Viewer

Step 2
Extract the LightningData.slk file from War3x.mpq file located in your Warcraft install folder. Open the SLK file in Excel and hopefully you will see a Table that looks like this

Zoom (requires log in)

Description of the table headings. These headings should not be changed in any way

  • Name - This is the name used by the WE and should only be 4 characters long.
  • Comment -This is your own description and can be of any length.
  • Dir - This is the directory path where you're going to save your texture.
  • File - The name of the texture file.
  • AvgSegLen - Average Segment Length is how long one segment of the lightning is.
  • Width - Changes the thickness of the lightning.
  • R G B - Red Green Blue. Can be used to change the color of the lightning without having lots of different textures for different colored lightning.
  • A - Changes the Alpha value of the lightning i.e. changes the transparency.
  • NoiseScale - Changes the noise or "chaos" of the lightning.
  • TexCoordScale - Changes the size of the texture, probably the same as AvgSegLen.
  • Duration - Time in seconds that the lightning will be rendered on screen.
  • Version - The Warcraft version, 0 for ROC and 1 for TFT


Step 3
On the next open line of the table enter a name or code that you can remember later on in the Name column and anything you want in the Comment. In the Dir column enter the directory path where you want to put the texture. Insert the name of the texture file including the BLP extension in the file column.
Copy the values from the above lines into the AvgSegLen Width R G B A columns or enter your own values if you want to. Remember the R G B and A values cannot be a non-negative integer bigger than 255.
Change the NoiseScale to a value between 0.00 and 1.00 . A larger value causes a more chaotic lightning.
Also change the TextCoordScale Duration and Version to values other than an empty cell. Save the file.


Step 4
Open WE and the map you want to use the lightning in. Use the Import Manager to import your textures and the LightningData.slk file into your map. Change the SLK file's custom path to Splats\LightningData.slk.
Also change the textures' paths to those used in the SLK file.
Go to the Object Editor and then the Abilities rollout. Find the spell you want to use the lightning with. Find the Art - Lightning Effects or LightningEffects property and while holding down shift double click on it. Enter the 4 character name of the lightning here. Save your map and test it in warcraft.
Hopefully everything will work perfectly and you'll have your own custom lightning without having to replace existing lightning.
Here are some examples of lightning I created. Examples of effects you can create:


Zoom (requires log in)
Attached Images
File type: gifexcel.gif (79.6 KB)
File type: giflightning7fx.gif (176.1 KB)
08-29-2004, 12:34 AM#2
ForgottenLight
Not a half-bad tutorial. (Don't have Excel, WinMPQ or Wc3Viewer though...)
09-05-2004, 01:19 AM#3
RemnantZ27
You dont need Excel, you can use notepad, it works just as well.
09-18-2004, 12:36 PM#4
garith
I cant find the Lightning.slk file (or anything similar) in war3.mpq OR war3x.mpq!!!!!!! where is it!??!
09-18-2004, 08:24 PM#5
CryoniC
Sorry but I misspelled the filename. It should be LightningData.slk and not just Lightning.slk. I have fixed this in the main post.
Please let me know about any other problems.
09-20-2004, 11:35 AM#6
garith
Quote:
Originally Posted by CryoniC
Sorry but I misspelled the filename. It should be LightningData.slk and not just Lightning.slk. I have fixed this in the main post.
Please let me know about any other problems.


nope, srry, thats not there either! in my War3x.mpq under L i have theese files:

L.mpq
Leader.jpg
Licence.txt
LocationBar.html
Logo.jpg
Lrepeat.jpg

Nothing else! Whats going on! there is no LightningData.slk in War3.mpq either!!!!!!!!!
09-20-2004, 05:25 PM#7
Guest
The TexCoord thingy changes the speed and direction of the lightning effects. negative makes it go backwards towards the caster.
09-26-2004, 02:15 AM#8
Necromancer_187
Wow, that's a really good tutorial. It actually sounds easier than my method, too. I also like your explainations of the different fields. I hope to see this used in future maps.
10-02-2004, 07:24 PM#9
CryoniC
You should look under S for Splats\LightningData.slk since the file is located under a folder named Splats.
01-23-2005, 01:43 AM#10
Guest
wat if i dont have printshop and i dont want to buy one what could i use?
02-04-2005, 04:09 PM#11
CryoniC
You can use The Gimp that can be found Here
02-06-2005, 09:38 AM#12
Demon-Reaper
Good tut, really helped my map ^_^ . It looks cool if you set 'A' (is it alpha?) to 100 and make it red!
03-08-2005, 11:46 PM#13
Yoz
This... didn't work for me. Do you have any suggestions on what might have gone wrong? Also, when I shift-click on the Art - Lightning Properties thingy it just goes to the normal selection, as if I had not held shift. Also, I have a Mac, and I don't know if the shift thing can only be done on PCs or some stupid thing like that...

Yup, I checked on my PC, and only PCs have the shift-click thingy You should probably warn about this in your tutorial under the "What you will need" section.

Why does Blizzard have to give Macs the shaft???????
03-22-2005, 10:17 AM#14
Daelin
Awsome stuff! I must say I am impressed. I was searching for such a tutorial for ages. Thanks dude!

~Daelin
03-22-2005, 12:04 PM#15
Guest
Your the best your Tutor have i maded it have me Inspired thx and GL!