Regarding moonlight

Discussion in 'Scripting Discussions' started by Nextep, Apr 25, 2013.

  1. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    Hello!

    We recently added the "light" script, aswell as roadlight-script that we found on this forum (big kudos to the creator), aswell as we put in a moonlight during night. Now, the problem we have is that the moonlight doesn't come up until a few hours have passed by, meaning we loose a few players because it's pitch black. Is there possible to make the full moon come up as soon as it hits a certain level of blackness? The date we set it on was 15/6/2012.

    Thank's in advance--

    Nextep
     
  2. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    Update;
    We continued to experience, and at the moment we are trying to create another file which will be run at the same time as the restart.bat, which edit's out the hiveext.init and changes the time. Which means, we jump over the "pitch black" - but, we will loose the "fading from daytime to nighttime-phase" but if this is the only work-around we can use, then we'll use it. If anyone has any other good ideas, or tips that will improve our method, please give us a feedback.

    Thanks in advance--

    Nextep
     
  3. SparxOne

    SparxOne Member

    Joined:
    Apr 11, 2013
    Messages:
    59
    Likes Received:
    5
    Maybe you could try and set the date to winter season meaning the nights starts earlier and therefore allow the moon to rise straight away instead of summer time where nights only start late at night and won't give time for the moon to show ?
     
  4. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    Yeah that is a good suggestion, but then it result into longer nights, we want to limit it to say 6-8 hrs. We're still working on our method, and from our test's its going good, we just gotta put it server side and see how it goes.
     
  5. SparxOne

    SparxOne Member

    Joined:
    Apr 11, 2013
    Messages:
    59
    Likes Received:
    5
  6. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    The site wont work for me, for some odd reason - but i guess you are pasting that calendar which shows which dates have moonlight etc? We have our server on 15/6 which should add moonlight now, and we have tested and scripted our script which runs an external bat file, which then again modifies the hiveext.init into changing the day-time. We are still having some small errors though, but atleast we have narrowed it down, and our script works flawless! From what i can see it is the only solution to jump over the "pitch black", which is sad - but i guess it adds realism to the game. If anyone is interested i can provide more details regarding this.
     
  7. Hoplit

    Hoplit Well-Known Member

    Joined:
    Feb 21, 2013
    Messages:
    109
    Likes Received:
    4
    Hi! Follow this tutorial, and set the date to 2013,8,10.
     
  8. SparxOne

    SparxOne Member

    Joined:
    Apr 11, 2013
    Messages:
    59
    Likes Received:
    5
    Yes that was a Lunar Calender for Arma 2 (2011-2012), guess you already knew it :p

    Yes i'd be very much interested in using your script ! If you could tell me step by step on how to set it up and use it ? I'd be glad to actually see the difference with your script since i am also having issues with the date on my server... I am using DayzCC and normally to set a static date you only need to edit the HiveExt.init and set the date to static instead of local, than obviously choose the date you want, but this has no effect on the server since what ever date i use the date ingame still shows local...

    Could you add a link please, you might have forgotten it :p
     
  9. Hoplit

    Hoplit Well-Known Member

    Joined:
    Feb 21, 2013
    Messages:
    109
    Likes Received:
    4
    Oh sorry :) here is the link.
     
  10. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    Thanks for this! At the moment our script works very good as explained above, but we'll test this and see how it goes :)!
     
  11. Cillam

    Cillam New Member

    Joined:
    Mar 30, 2013
    Messages:
    10
    Likes Received:
    0
    I have the date set to 6/6/12 and the moon is always full and always in the sky at night.
     
  12. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    Weird, we tried this date and it didnt work - but as mentioned before our script bypasses the pitch-black-time and goes straight to full moon
     
  13. Freaking Fred

    Freaking Fred OpenDayZ Rockstar!

    Joined:
    Feb 1, 2013
    Messages:
    380
    Likes Received:
    171
    What time does your moonlight reach your preference? You could try editing your dusk/dawn times.

    Step 1: Unpack your dayz_code.pbo and make a copy of your dayz_code folder to use for editing.

    Step 2: Find dayz_code\init\variables.sqf.

    Step 3: Search for the following lines of code.
    Code:
    //DayZ settings
    dayz_dawn = 6;
    dayz_dusk = 18;
    Step 4: Edit dusk to whatever time your moonlight is preferred. (24 hour clock)

    Step 5: If you aren't already using a custom variables.sqf, copy the one you just edited into your mission folder.

    Step 6: In your init.sqf change
    Code:
    call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf";                //Initilize the Variables (IMPORTANT: Must happen very early)
    to
    Code:
    call compile preprocessFileLineNumbers "variables.sqf";                //Initilize the Variables (IMPORTANT: Must happen very early)
    I'm not 100% positive that this will work because I have never tried it before. However, I believe, in theory it should work.
     
    ebay and Excelsior like this.
  14. Saethkept

    Saethkept Well-Known Member

    Joined:
    Mar 17, 2013
    Messages:
    107
    Likes Received:
    15
    @Fred,

    I can confirm that altering the dusk/dawn values in the variables.sqf does indeed work.
     
  15. Freaking Fred

    Freaking Fred OpenDayZ Rockstar!

    Joined:
    Feb 1, 2013
    Messages:
    380
    Likes Received:
    171
    Just curious if what I posted worked out for you.
     
  16. Nextep

    Nextep New Member

    Joined:
    Apr 24, 2013
    Messages:
    16
    Likes Received:
    0
    Holy f*** !!

    Thanks for this, we will not stop using our custom script! thumbs up!
     
  17. Bonux

    Bonux Member

    Joined:
    Mar 27, 2013
    Messages:
    54
    Likes Received:
    2
    does not work for me

    i have these changes

    dayz_dawn = 3;
    dayz_dusk = 23;

    and my sun starts setting at about 18:00 instead of 23.00 if i understood corectly
     
  18. noswal91

    noswal91 New Member

    Joined:
    May 18, 2013
    Messages:
    5
    Likes Received:
    1
    just 1 question. where do you find the dayz_code.pbo?
     
  19. Toft

    Toft New Member

    Joined:
    Feb 6, 2013
    Messages:
    26
    Likes Received:
    0
    you find the dayz_code.pbo in your @dayz/addons folder :)
     

Share This Page