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

Fixing Wc3 Lighting

Status
Not open for further replies.
I have used the wc3 editor for many years, and am to a point where I have good mapping, modeling, triggering skills etc. However, I have made a way to "turn out the lights" by replacing the DNCLordaeronUnit and DNCLordaeronTerrain models with ones that produce no light. It was I discovery I greatly enjoy, but it created another problem:

Warcraft III was not build to handle massive amounts of lights, such as torches. If I get enough, the game will begin to show the squares of terrain lighted separately and look glitched up. I was wondering if anyone had a way to fix the light problems. I used some ambient light, which seems to reduce the glitch, but it doesnt look as good and doesnt fix the entire problem, because I still eventually get too many ambient lights.
 
Level 3
Joined
Jan 4, 2007
Messages
18
If i know what you're saying, try switching the doodads to show in fog so that when the model is technically off the screen, it will still emit the lighting. Which might be the cause of the problem for the 'squares' effect. ( when the model goes offscreen, even if in sight, it will cut the model off completely. Pretty sure this is the right fix. )

If that doesn't work try using them as buildings neutral/ally, or gives them a spell to give sight if they are within a certain radius, most likely enough that it starts the effect while still offscreen (screen view + cameraheight offset).
 
Hmm... I'm not sure, by reading your comment, that everything I said in that one post made sense. To add visuals to my problem, I'm going to try and add pictures to go along with the problem. Unfortunately, I haven't done much with this site's forums other than read them before, and I might attach things incorrectly.

What I did to get the broken one was move the camera all over to map to each light.

The game will load a light emitter as soon as you screen over it, and the game will NEVER unload the light emitter. Because of this, it will eventually pass over a maximum light viewed number and screw up.

While trying to make it display the glitch, I somehow caused it to turn all the lights off, and I'll include that picture file.
 

Attachments

  • worldedit 2008-04-19 16-40-24-43.jpg
    worldedit 2008-04-19 16-40-24-43.jpg
    31.3 KB · Views: 534
  • worldedit 2008-04-19 16-50-14-46.jpg
    worldedit 2008-04-19 16-50-14-46.jpg
    14.9 KB · Views: 489
  • worldedit 2008-04-19 17-06-57-14.jpg
    worldedit 2008-04-19 17-06-57-14.jpg
    32.4 KB · Views: 495
Level 3
Joined
Jan 4, 2007
Messages
18
Interesting, have you tried just having a plain map and seeing how many emitters it takes before it starts to glitch?

Also have you tried killing/creating the doodads that display the light to see if the dead ones still cause the glitch?

If the dead ones dont glitch you could use it to your advantage.

I'm not sure if the particle emitters have limitations.
 
Level 3
Joined
Jun 13, 2006
Messages
45
I have the same problem with light emitting tiles. when using many doodads as light emitter I have that square limitation that appear at some places and some other lights that totally disappear.
However I noticed that when loading my map on the editor, all the lights are displayed properly, and when I start editing the glitches start to appear :S.

btw one question Retera, your way of turning the lights off is very interesting, mb you could share it? :)
 
Sorry, didnt get back on here in a bit, but anyway sure I'll share it :grin:

Anyways, I mostly have only used doodads, which don't have many trigger/jass functions working for them. I had a few units in another map using a custom model I made with light, and when they died the light never went away, once more adding to the problem, but I think the was the model maker's (my) fault.

I could try making the light destructables, and seeing how well that worked, but I haven't gotten to it yet.



As for sharing my light-off tool, its simply a few files I used. To make it work in game, you can either overwrite the old files ("Environment\DNC\DNCLordaeron\DNCLordaeronTarget\DNCLordaeronTarget.mdx" or Terrain/Unit in place of target) or import them to any path and use the script function:

call SetDayNightModels( "war3mapImported\\DNCLordaeronTerrain.mdl", "war3mapImported\\DNCLordaeronUnit.mdl" )

war3mapImported here being an example path, you could use anything

be sure to use \\ in the script path, rather than a single slash

Yes, that script function WILL work with local player stuff, I've tried it.


Anyways, I'll attach the file for you to have some fun with.


My other messages don't seem to have shown up, but I was talking about how the third file didn't attach for some reason. My suggestion is to replace DNCLordaeronUnit.mdx with a copy of one of the other files, it should still work.
 

Attachments

  • DNCLordaeronTarget.mdx
    908 bytes · Views: 117
  • DNCLordaeronTerrain.mdx
    756 bytes · Views: 105
Last edited:
Status
Not open for further replies.
Top