CityLanterns
Description
This plugin let selected redstone lanterns of different groups switch on/off at differeren (ingame) times, e.g. at sunset lanterns of group A will toggle on while lanterns of group B will toggle on at midnight.
Lantern Selection / Tutorial
To modify which lanterns belong to which group, do /citylanternsselect
or /citylanternsselect <group>
(If you do not specify a group, "main" will be used), a tool will be added to your inventory. Then you can right-click a redstone lantern with that tool to check which group that lantern belongs to, or left-click to add/remove the lantern to/from the group. After one lantern is added to a new group, you can change the settings of that group in the config. Then wait for the night and see them switching on :D
Config
For a default config with key definitions, see here.
Commands & Permissions
- /citylanternsselect|cls [<group> [new|we]]
-
Will either give (or replace if
new
is not given) a tool for adding/removing lanterns to/from the group<group>
(Will be set to 'main' if not supplied) or, if thewe
argument is given, sets the group of all lanterns to<group>
in the currently selected WorldEdit region.Permission name is
citylanterns.select
(default for ops) - /citylanternsgroups|clg [<group>]
-
Lists all groups or, if
<group>
is given, shows detailed information about that group.Permission name is
citylanterns.groups
(default for ops) - /citylanternssettings|clsetting [<group>] day|night|thunder <number>|true|false
-
Sets config properties for a the group
<group>
, ormain
if not supplied.Permission name is
citylanters.settings
(default for ops) - /citylanternsreload|clr [force]
-
Reloads all lanterns and group settings. If
force
is supplied, this will discard all data and load them from the storage.Permission name is
citylanterns.reload
(default for ops)
(For commands in version <= 1.8.1, see here)
Changelog
v2.1.1:
- Updated to CraftBukkit version 1.7.9-R0.2
v2.1:
- Added Reload command
- Changed Select command
- Added more storage options for lanterns and groups
v2.0.3:
- Added /citylanternssettings command
- Fixed groups
- Faster block updates
v2.0.2:
- Updated to CB 1.7.2
v2.0.1:
- Updated to CB 1.6.4
v2.0:
- Complete command rework
- Selection now by tool
- Ability to form groups of lanterns with different settings (on/off/thunder) (inspiration from fov360)
- WorldEdit hook to set group of all lanterns in the WorldEdit selection
v1.8.1:
- Custom worlds loaded after the plugin will cause a lantern reload to fix a bug
- Fixed bug when lanterns are destroyed
v1.8:
- Updated to 1.6.2
v1.7:
- Updated to Bukkit 1.5.2
- Lanterns which are closer to players will be toggled before lanterns which are farer to players. Idea by dab1983. Thx
v1.6:
- Set the compilance version from 1.7 to 1.6 so that the Bukkit standards are kept.
- Updated to CraftBukkit version 1.5.1-R0.1.
v1.5:
- Added a delay between toggling the lantern states to prevent lags. Idea from John290. Thx.
v1.4:
- Fixed bug lanterns will start flickering rapidly when weather changes. Reported by TheMisterB. Thx.
v1.3:
- Added plugin metrics submit provided by http://mcstats.org/
- Fixed bug config files were not created on startup. Reported by mcferson. Thx.
v1.2:
- Added the function to toggle the redstone lanterns if it's raining/thundering.
- Fixed bug being unable to remove lanterns wich are on.
v1.1:
- Initial version with compatibility to CB 1.4.7-R1.0.
Stats Collection
This plugins automatically sends information for statistic purposes only to MCStats, specifically (quoted from https://forums.bukkit.org/threads/mcstats-plugin-metrics-r7-easy-advanced-plugin-statistics.77352/)
- Metrics revision of the implementing class
- Server's GUID A randomly generated ID to identify the server
- Players currently online (not max player count)
- Server version string (the same version string you see in /version)
- Plugin version of the metrics-supported plugin
To disable data collection, you can set opt-out
to true
in plugins/PluginMetrics/config.yml.
The collected data can be seen by everyone at the MCStats project page.
Source
Source can be found at GitHub.
Not working on Bukkit for 1.9.x or 1.8.x?
Check out
StreetLights Reloaded
UPDATED TO MINECRAFT 1.9.2!
@ase34 Well, that's really sad. I wish I could code Java to update the plugin.
Waiting for someone to take over the project, it's simply the best plugin of this type!
@TheBukor
@FutureForce
For the time being, I am currently unable to provide an update for MC1.8, sorry. However, anyone is free to fork the source code, and potentially taking over the project.
Version 2.1.1 not working on Spigot 1.8. It spams console with errors, like:
Task # for CityLanterns v2.1.1 generated an exception (java weird gibberish)
Even tried compiling the newest in the GitHub, it stopped spitting errors on the console, but it still doesn't work.
An update would be really appreciated.
dosn't work on spigot 1.8.1
[CityLanterns] Task #41 for CityLanterns v2.0.3-BETA generated an exception java.lang.NoClassDefFoundError: net/minecraft/server/v1_7_R1/World at me.ase34.citylanterns.runnable.LanternUpdateThread.addUpdateAction(LanternUpdateThread.java:62) [?:?] at me.ase34.citylanterns.runnable.LanternUpdateThread.run(LanternUpdateThread.java:52) [?:?] at org.bukkit.craftbukkit.v1_8_R1.scheduler.CraftTask.run(CraftTask.java:71) [minecraft_server.jar:git-Spigot-b023457-7017af7] at org.bukkit.craftbukkit.v1_8_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:350) [minecraft_server.jar:git-Spigot-b023457-7017af7] at net.minecraft.server.v1_8_R1.MinecraftServer.z(MinecraftServer.java:694) [minecraft_server.jar:git-Spigot-b023457-7017af7] at net.minecraft.server.v1_8_R1.DedicatedServer.z(DedicatedServer.java:316) [minecraft_server.jar:git-Spigot-b023457-7017af7] at net.minecraft.server.v1_8_R1.MinecraftServer.y(MinecraftServer.java:623) [minecraft_server.jar:git-Spigot-b023457-7017af7] at net.minecraft.server.v1_8_R1.MinecraftServer.run(MinecraftServer.java:526) [minecraft_server.jar:git-Spigot-b023457-7017af7] at java.lang.Thread.run(Thread.java:744) [?:1.7.0_55] Caused by: java.lang.ClassNotFoundException: net.minecraft.server.v1_7_R1.World at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:91) [minecraft_server.jar:git-Spigot-b023457-7017af7] at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:86) [minecraft_server.jar:git-Spigot-b023457-7017af7] at java.lang.ClassLoader.loadClass(ClassLoader.java:425) [?:1.7.0_55] at java.lang.ClassLoader.loadClass(ClassLoader.java:358) [?:1.7.0_55] ... 9 more
Thank you for updating!
Great, I'm looking forward to it. Thank you!
@fov360
I uploaded a new version of this plugin, this should be compatible with CB 1.7.9. It should be available soon as it still needs to get approved.
Unfortunately 2.1 Beta (nor any other version) is working on 1.7.9. As soon as one enters /cls it starts to spam the console with this error:
Groups are not saved. The command /citylanterssetting is not being recognized.
Will there be an update available?
I did everything you said to do but they dont even turn on at night!
@Theitalian828
Could you please describe your problem more precisely? Did you selected the lanterns with the tool? Can you see any errors in the server log? Did it work on version 2.0.3?
This plugin sucks it doesn't even work when it becomes night time none of the lanterns come on and i have done everything to make them work to no avail.
OH MY GOD - this is so wonderfull now! Our City seems to be alive!
Thank you for working over the groups!
Realy nice Plugin. But can you and a function to Set a group of Lamps steady on? I need this for indoor lights.
A reload command is essential.
@fov360
All in all, thx for your comment :D
First of all: thank you for picking up the idea of groups with different settings!
Unfortunately the group-feature does not do the job (yet). Groups are added but the times are ignored. All lanterns turn on and off at the same time. :(
Also a few more commands would be appreciated to make it more customizable from ingame:
Maybe you could even add a setting for the tool item id in the config.
Edit: Also a reload command would be great.
Now my town has lights!
@ase34
thx we love this plugin
@MysticCity
Thx for this report, I'll investigate that.
ATM we use 1.6.4 but my member call me an error. The Lantern is on but no light level.... If any 1 Hit this Lampf the light goes on.