Jump to content
  • 0

axeman

Question

The latest patch has the culmination of all of the work done on lighting so far for dayZ.
 
Street Lights: The street lights are enabled by default, adding the lighting system allows you to set a failure percentage. The lower this is set the more the street lights will flicker off and fail.
 
House Lights: Currently buildings that can not be entered will be lit, this is also based upon the lighting percentage, the higher this is the more houses will be lit.
 
Illuminant Towers: The towers that can be climbed that have a spotlight on each corner will be lit..
 
New Features:

  • House lights are now brighter at a distance. This allows the player to see distant houses up to 600m (with default settings can be set to 1km). During the night when running from the coast or through the forest heading north, this is a beacon, an oasis in the dark guiding your player to the next town..
  • Generators: Placing a generator will effect the surrounding lighting depending on your settings. If a generator is required it will light all illuminant objects within it's range. If a generator is not required houses will be lit yet a placed generator will force the surrounding lights to be 100% reliable (this allows a low lighting percentage and enabling of lights through generator placement).
  • Chance: Set this high or low, I like a very low chance of lighting, this fails lots of street lights causing them to flicker and go off.. House lights are few and far between yet generators cause all of the surrounding houses and street lights to be lit also.

See the dayZ Epoch Lighting Wiki for more details and put any feedback or questions about the lighting system here..
 
To enable the lighting simply uncomment the line at the bottom of your init.sqf to look like this:

//Lights
[0,0,true,true,false,56,280,600,[0.698, 0.556, 0.419],"Generator_DZ",0.1] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf";

Being stalked by several zombies through a dimly lit night time village..? 

Link to comment
Share on other sites

Recommended Posts

  • 0

I have no reference to any kind of lighting in my init.sqf. I see the files in dayz_code\compile but I can't find where they are called from.

 

I'm trying to disable the building lighting completely for now.  I can't find any information how to do so?

Link to comment
Share on other sites

  • 0

Anyone ever get an answer to the big question: How do we turn off the lights? Axeman! 

 

I've been asking this question since last year. Nobody on here ever gives a straight answer and the one guy that can, seems to ignore the question altogether.  Seriously, does anyone actually know how to turn off the bloody lighting system?  In my init.sqf , the lighting system line is commented out. So where else do I look to change it? We all now you're proud of your lighting system, Axeman.  it really is truly amazing (from a programming point of view).  But some of us don't like it, non of my players like it.  So can I please turn it off !!!!!!

 

I'm pretty sure i'm not the only person get frustrated with the lack of straight answers on this type of question.

Link to comment
Share on other sites

  • 0

Anyone ever get an answer to the big question: How do we turn off the lights? Axeman! 

 

I've been asking this question since last year. Nobody on here ever gives a straight answer and the one guy that can, seems to ignore the question altogether.  Seriously, does anyone actually know how to turn off the bloody lighting system?  In my init.sqf , the lighting system line is commented out. So where else do I look to change it? We all now you're proud of your lighting system, Axeman.  it really is truly amazing (from a programming point of view).  But some of us don't like it, non of my players like it.  So can I please turn it off !!!!!!

 

I'm pretty sure i'm not the only person get frustrated with the lack of straight answers on this type of question.

Thanks, no one is ignoring you.

The streetlights are all on by default. The quoted out lighting system deals with houses only, now a cut down verson .

Since the lights were introduced the config was set to allow street lights to be turned off, will have a look at adding an option to remove them.

Most of the lighting is handled client side so is not always straight forward, avoiding lag issues etc.

Link to comment
Share on other sites

  • 0

I can't seem to get the lights on the Napf server I manage off, no matter what. I've even gone through and added the p3d names for the ASC lighting used on the Napf map to the fn_lightfunctions hoping that would make a difference, but nothing. Seems no matter what I put in the init.sqf all the street and house lights are on. Any ideas?

Link to comment
Share on other sites

  • 0

The streetlights are set in the config. The problem is simply checking them is costly as they are map objects. I have code to switch them off within a certain range of the player. Problem is there is no sensible way to then eliminate them from further checks. I can live with an initial cost to turn them off once but constantly running the check will most likely cause lag issues.
 
The options, as I see them:
 
1: run a routine at server start up that loops through the map turning all lights off manually. Probably too time consuming..
 
2: leave remote streetlights on, eg. distant streets, motorways and villages. Then deal with each town / city individually. A point in the centre can be used as a control, by applying a variable, then the lights are all switched off within a radius as the first player comes within range. This way when another player arrives in the area a check can be made against the central control point before going into the costly routine of looping through all the lights again.. adding custom locations can be built in allowing editing for other maps.
 
In light of this (pun intended) it may be wise to split up Street lights and house / tower lights into separate routines ..
 
I've done a fair bit since the last update on this, have also been busy with Epoch 3. Believe me, there is no simple off switch. Add in the generator checks and handling how every player sees the lights it gets very messy.

 

Question: is it in the main cities where you would prefer the lights off for the immersion ?

Link to comment
Share on other sites

  • 0

I can't seem to get the lights on the Napf server I manage off, no matter what. I've even gone through and added the p3d names for the ASC lighting used on the Napf map to the fn_lightfunctions hoping that would make a difference, but nothing. Seems no matter what I put in the init.sqf all the street and house lights are on. Any ideas?

 

 

What are you using in your init.sqf ?

Link to comment
Share on other sites

  • 0

//Lights
[0,0,true,true,false,56,280,600,[0.698, 0.556, 0.419],"Generator_DZ",0.1] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf";

 

That ^

 

Before that we had [true,12] execVM "lights\local_lights_init.sqf";//[REQUIRE GENERATOR (true/false),Light Chance %]

 

Neither worked.

Link to comment
Share on other sites

  • 0

Thanks, I have a server for testing. Was more for stress testing on a populates server and get some feedback on performance. The way the lights work it needs at least two or three in the same area. And getting tired of being shot by my HC ;)

Link to comment
Share on other sites

  • 0

Awesome thanks Axeman, I just put this in and tested it, set everything to false with 0 chance of lighting and all the lights were still on, I noticed there's now dusk detection in there, do I have to wait for it to hit dusk naturally or will making it night time with Infistar still work ok? The default lighting system I have in there now successfully turns off most of the street lights and when I switched back to that and made it night time again it worked just fine, of course some street lights were still on here and there and the house and tower lights were on, but that's normal.

 

I'm trying to get as many lights off as possible and require generators for any kind of lighting.

Link to comment
Share on other sites

  • 0

So random question.

We have extended crafting and plot pole radius on our server.

 

We've allowed players to build wall lamps as part of this but this doesn't light up at night, how would I go about adding this is a light source, is this even possible without extensive messing about? (Misc_Wall_lamp)

 

Alternatively we want to make Lightpoles more powerful as currently they are pretty weak, the camp fires give out better light than these and they are pretty useless for base lighting if the base is large.

Is this possible?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
×
×
  • Create New...