NightLantern

Automatically turns ON and OFF lanterns after sunset and sunrise

Total Downloads: 20,623 - First Release: Jun 27, 2015 - Last Update: Jun 11, 2018

5/5, 52 likes
  1. can we make it so this only works in range of tc? to prevent campfires around the map from turning on?
     
  2. Hello,

    I can't seem to this mod to work. (oxide and rust are both up-to-date)


    My config file:
    {
    "ConsumeFuel": false,
    "LightTypes": {
    "Campfires": true,
    "CeilingLight": true,
    "Furnace": true,
    "JackOLantern": true,
    "Lanterns": true,
    "LargeFurnace": true,
    "Searchlights": true,
    "TunaLight": true
    },
    "SunriseHour": 0,
    "SunsetHour": 23.9
    }

    Where am I going wrong?
     
  3. Code:
    "SunriseHour":0,
    "SunsetHour":23.9
    leave these settings at default change to the below settings
    Code:
    "SunriseHour":7.5,
    "SunsetHour":18.5
     
  4. So are you saying that we can’t change the on/off times?

    Is there a way of having the lights on 24/7?
     
  5. Two questions the coder needs to answer but I would say
    1) leave it as default for the plugin to work
    2) no need to have it on 24/7
     
  6. 1. Then what is the point of a config file if you can’t change the on/off times.
    2. We want it on so we can see when inside our bunkers. Even during the day it’s super dark.
     
  7. remove this plugin and try this one Smart Homes for Rust | Oxide
     
  8. Code:
    {
      "ConsumeFuel": false,
      "LightTypes": {
        "Campfires": false,
        "CeilingLight": true,
        "Furnace": false,
        "JackOLantern": true,
        "Lanterns": true,
        "LargeFurnace": false,
        "TunaLight": true
      },
      "SunriseHour": 8.0,
      "SunsetHour": 7.5
    }
    Works perfect.
     
  9. @k1lly0u Brand new server build from scratch on Windows dedi.

    Code:
    Protocol: 2024.152.1
    Build Date: 10/23/2017 13:43:03
    Unity Version: 2017.1.2f1
    Changeset: 23432
    Branch: main
    Getting this when plugin starts.

    Code:
    [10/25/2017 14:37:24] Loaded plugin NightLantern v2.0.8 by k1lly0u
    [10/25/2017 14:37:24]   at Oxide.Plugins.NightLantern.OnPluginLoaded (Oxide.Core.Plugins.Plugin plugin) [0x00000] in <filename unknown>:0  at Oxide.Plugins.NightLantern.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00000] in <filename unknown>:0 
    My config looks like this.

    Code:
    {
      "ConsumeFuel": true,
      "LightTypes": {
        "Campfires": false,
        "CeilingLight": true,
        "Furnace": false,
        "JackOLantern": true,
        "Lanterns": true,
        "LargeFurnace": false,
        "Searchlights": true,
        "TunaLight": true
      },
      "SunriseHour": 10.0,
      "SunsetHour": 10.01
    }
    Any ideas? Thanks.
     
  10. i bet you its this: "SunsetHour": 10.01 change that too: "SunsetHour": 10.5

    bet you don't get the error again
     
  11. Thank you, I've just made that change assuming you meant 10.05 not 10.5? Anyway, no error using 10.05, so that seems to be it. :)

    The funny thing is, we've had that setting of 1 minute (ish) for about 5-6 months (I think) and it's been fine. But... Lots of things playing up since last Thursday's update and I've been carefully rebuilding our servers from scratch one plugin at a time and dealing with each problem as it arises.

    Thanks again!
     
  12. any way to add hobobarrel to the list ? they give off the best light so far.
    I tried adding "hobobarrel": ture but that did not work.
     
  13. "SunriseHour": 7.5,
    "SunsetHour": 18.5
    Wulf!!!...Help me understand sir please. By changing these numbers. "I know it turns the lights on and off! That's obvious as you have written. But..By changing those numbers can I also make my DayLight and NightTime longer or shorter using this Plugin? By this. I mean. Can I control the length of my days with this as well as turning on and off the Lights? I just don't want Night to be as Long as it is and want to make it a bit shorter. So can I change how long Night Time lasts? And make my Nights Shorter with this to?
     
  14. No you can't with this plugin, it only controls when the lights go on and off. You need the Time Of Day plugin to control day/night lengths.

    TimeOfDay for Rust | Oxide
     
  15. Thank you.
     
  16. 04:33 [Error] Failed to call hook 'OnPluginLoaded' on plugin 'NightLantern v2.0.8' (NullReferenceException: Object reference not set to an instance of an object)
    04:33 [Stacktrace] at Oxide.Plugins.NightLantern.OnPluginLoaded (Oxide.Core.Plugins.Plugin plugin) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.NightLantern.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00000] in <filename unknown>:0
     

  17. I found a conflict when I also had NoFuelRequirements at the same time. But what I did was pull out nightlantern altogether. And reloaded it. And Config'd the brand new .json it created. I did not swap to the old json. I used the new one to config.
     
  18. Thanks. I recreated all the .jsons and it now works.
     
  19. did you ever get an answer? Because i would like to know also
    Good to hear sir!!!!!....lololololo.....your welcome. Im new. But this server thing has taught me about Patience. And alot of hit/miss and backtracking sometimes......Kinda that: "Murphy's Law" concept!....lolololol. take care man
     
  20. NightLantern quits working on night to day to night cycle. I reloaded it twice and both times it starts to work again but it stops again.

    Anyone else having this issue ?