[MECH] LightControl v0.4 - RedstoneChips library for control of light sources [1840]

Discussion in 'Inactive/Unsupported Plugins' started by Mordenkainen, Jul 24, 2011.

  1. Offline

    Mordenkainen

    LightControl- A RedstoneChips library for controlling light sources:
    Version: v0.4

    LightControl is a Redstone Chips library that allows control of various light sources.

    Features:
    • Toggle Glowstone on/off (glasslight)
    • Toggle Torches on/off (torchlight)
    • Toggle Pumpkins on/off (pumpkinlight)
    • Toggle Redstone Torches on/off (rstorchlight)
    • Toggle flaming NetherRack on/off (netherlight)
    • All chips support wireless control, address selectable outputs, or directly controlled outputs.
    • Supports lights on posts or any other structure. Allowed materials are configurable.
    • glasslight chip can be configured for dropping/not dropping glowstone when broken
    Usage:

    Indexed (Direct) control of outputs:
    - Create a chip with any number of interface blocks and the same number of input blocks.
    - Attach your output (glass for glasslight, pumpkins for pumpkinlight, etc) to the interface blocks.
    - Attach a sign with the chip name on the first line and "indexed" on the second. For example:
    -----------
    glasslight
    indexed
    -----------

    Addressed control of outputs:
    - Create a chip with any number of interface blocks.
    - This chip will need 2 input blocks, plus enough inputs to address the interface blocks (1 to address 2 interface blocks, 2 to address 4, etc.). The first input is a clock, the second the input value, the rest the address.
    - Attach your output (glass for glasslight, pumpkins for pumpkinlight, etc) to the interface blocks.
    - Attach a sign with the chip name on the first line and"addressed" on the second. For example:
    ------------
    pumpkinlight
    addressed
    ------------

    One input controls all outputs:
    - Create a chip with any number of interface blocks.
    - This chip will need 1 input block.
    - Attach your output (glass for glasslight, pumpkins for pumpkinlight, etc) to the interface blocks.
    - Attach a sign with the chip name on the first line and "all" on the second. For example:
    ------------
    rstorchlight
    all
    ------------

    Wireless control of outputs:
    - Create a chip in the same way as above (Indexed or Addressed), but do not include any input blocks.
    - Add an additional line to the sign with the name of your wireless channel.
    ------------
    netherlight
    mychannel
    ------------
    or
    ------------
    netherlight
    indexed
    mychannel
    ------------
    etc.

    Note that the line identifying the input type (addressed, indexed, all) is optional. If this line is not there the chip will attempt to figure it out automatically using the following rules:
    - If the right number of inputs vs. interface blocks for addressed mode is present, it will attempt to use Addressed mode. (I.E. 3 input and 2 interface, 4 input and 4 interface, 5 input and 7 interface, etc.)
    - If the same number of inputs and interface blocks are present, it will attempt to use Indexed mode.
    - If there is only one input, it will use All mode.
    - If more than one of the above is true, the last one is used. (All is preferred over Indexed, Indexed is preferred over Addressed)

    Lamp Posts:
    You can build complex light setups using various materials. When activated the chips will search through the blocks attached to it's outputs looking for light sources to toggle. This allows you to build lamp posts and chandeliers. The allowed materials for lamp posts defaults to Logs, Wood Planks, Fences, Iron Bars, Nether Fence, and NetherBrick. These can be changed via the configuration.
    Lamp.jpg

    Configuration:
    This plugin adds two new preferences to the RedstoneChips preferences.yml:
    - glasslight.dropGlowstone: false
    This preference controls if breaking glowstone lights drops glowstone dust or not. This defaults to false, meaning glowstone will not be dropped.

    - LightControl.lampPostBlocks: WOOD,LOG,IRON_FENCE,FENCE,NETHER_BRICK,NETHER_FENCE
    This preference is a list of block types that can be used for lamp posts. Additional blocks can be added to this entry to allow more materials to be used.



    Known Issues:
    • None
    ToDo:
    • Allow billboards made of light sources. An example with redstone torches is shown here: (Future)
    • Add CraftBukkitUpToDate support?
    Notes:

    This plugin requires RedstoneChips:
    http://forums.bukkit.org/threads/mech-redstonechips-0-9-integrated-circuits-plugin-1000.1205/

    For the glasslight chip, you may want to use a texture pack that makes Glass and Glowstone more similar to each other. This will make the transition between the on and off states look better.

    Video Demo:


    Download The LightControl Plugin: https://github.com/Mordenkainen/LightControl/raw/master/release/LightControl-0.4.jar
    Source Code: https://github.com/Mordenkainen/LightControl

    Changelog:
    Version 0.4
    • Added support for lamp posts.
    • Added configuration for glowstone drops.
    Version 0.3
    • Updated for RedstoneChips 0.94 (Thanks Eisental!)
    Version 0.2
    • Chips now save state on shutdown
    • Pumpkins maintain facing
    • Breaking Glowstone lights no longer drop anything
    • Torches are now handled properly on server restarts
    • Added "all" mode where a single input toggles all attached lights
    • Rewrote input type detection system. Chips now try to figure out what mode they are in on their own. What has been detected can be overridden by a sign argument.
    Version 0.1
    • Initial Release
     
  2. Offline

    wlwhs321

    its not working :(
     
  3. Offline

    Mordenkainen

    What is happening?

    Are you getting an error in the console?
     
  4. Offline

    wlwhs321

    idk so i just downloaded other one as better one
     
  5. Offline

    Mordenkainen

  6. Offline

    rev0l

    hey,
    nice plugin, exactly what iam looking for.
    i use it for private build sessions with friends.

    but i think there is a bug,
    if i use glasslight wireless, all connected interfaces turn the glowstone into glass when i switch off,
    but when i switch it back on, only the first interface connected to the receiver (glasllight /n mychannel) will turn the glass back to glowstone...

    its the first time i use te redstonechips mod, maybe i try it just on the wrong way...
    ill keep on playing around and try some more ideas...

    have a nice day
     
  7. Offline

    Mordenkainen

    I'll take a look and see what I can find. Thanks for the info.
     
  8. Offline

    7eggert

    (Feature suggestions:)
    I like the description, but I'll want to disable changing glass to glowstone so there will be no easy glowstone to be generated. An other possibility would be disallowing to crash glowstone if it was glass.

    Besides that, I have built a redstone digital clock. Converting it to your chip will require two interface blocks to change each segment, and both interfaces should respond to a one-bit-input value from the segment driver. Maybe you can add a "parallel" mode that will connect the only input to all interfaces.

    (Now I can't use it because R'Chips will trigger a minecraft bug and empty my chests).
     
  9. Offline

    Mordenkainen

    Good suggestions....

    So for the first, I will not be adding a disable setting for individual chips... But that said, I have submitted a change for redstonechips that would make it so that you can control access to individual chip types via permissions, which would give you what you are looking for. It may also be possible to make it so that breaking the glowstone won't drop anything, but I would have to look into how to handle that.

    On the second, it's a very good idea. I will look into implementing it, but for now you should be able to get that functionality by connecting all the inputs together with redstone and sending a single signal to them. Not ideal, but may work in the short term.

    Morden
     
  10. Offline

    rev0l

    ok, i'm just doing it wrong... sorry...
    i thought 1 input is enough to switch all connectet interfaces...

    but it would be great if you can implement the parallel / broadcast mode to turn all connected interfaces on/off with 1 input:D
     
  11. Offline

    kevishou

    dude can u help me i dont understand the controls and does this work with 1.7.3 and can u plz make a tutorial cuz i cant light on/off my glowstone !

    the torches works fine but not this and if i put a repeater would it turn on/off indefinitly ?? if yes would it works for a night club? :D

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 17, 2016
  12. Offline

    Mordenkainen

    the "glasslight' (using glowstone) should be built in the same way as a torchlight chip, so if you got that to work just build the glasslight in the same way.

    As far as automatically changing, you could use a repeater based clock, or any other way to make redstone toggle on/off to trigger this for a strobe effect.

    That will be in rev 2, which I hope to have up by the end of this week.

    EDIT- Updated initial post with known issues and future plans.
     
    kevishou likes this.
  13. Offline

    kevishou

    by the same way what do u mean cuz i make a torchlight just by putting redstone on a normal torch and it'S done
    but i tried on the glowstone and it actually doesnt work .(if u could make a short tuto would bo great :)
    so then i could understand it and promote that crazy bukkkit <3
     
  14. Offline

    Mordenkainen

    For a real simple light, build blocks like this:
    [G][Int][C][IN]

    G = Glowstone
    Int = Interface block (as configured in RedstoneChips. Default is Lapis Block)
    C = Chip block, this can be just about anything
    IN = Input block (as configured in RedstoneChips. Default is Iron Block)

    Put a sign on the side of the chip block that says "glasslight", and click the sign. You should get a message telling you glasslight was activated.

    Now, when you switch redstone on/off at the Input, the Glowstone will change.

    This plugin does require the RedstoneChips plugin. The chips are built in the same manner as other RedstoneChips, so before you start playing with this plugin, you should make sure you know how to use that one.
     
  15. Offline

    kevishou

    I ABSOLUTLY LOVE !!!!!!!!! thankkkkk u sooo muchhhhh i love uuuu imma promote this nice mod <3
     
  16. Offline

    KompotPL

    Does this plugin allow me to control light sources WITH OUT connecting them throught wire to the trigger? Because in most of my buildings it would be hard to connect light sources with trigger. If not, would it be possible to add this? :)
     
  17. Offline

    Mordenkainen

    Yes, that is one of the things it can do.

    It still requires a little more space than the one block for the light, but it does allow you to control it wirelessly.
     
  18. Hey the download link is a little ****
     
  19. Offline

    thewoodminer

    This is not working any ideas i install it correctly and i am not getting any error messages. When in game i am trying to light netherrack but it doesn't work. i also installed redstone chips all 3 of them and it wont light. in the server window it says zero chips loaded how do i load a chip??? Or Do you think just havent set it up correctly in game or i did something else wrong anything will help. Thanks :D
     
  20. Offline

    Mordenkainen

    Fixed! Thanks!
    Can you upload a picture of what you have built?

    Did you click the sign after building the chip?
     
  21. Offline

    rev0l

    thanks for updating your plugin!
    its awesome
     
  22. Offline

    Mordenkainen

    Glad it's useful to you.

    If anyone has any suggestions, let me know!
     
  23. Offline

    sambhur96

    Nice plugin:)
     
  24. Offline

    dannycrafts

    Doesn't work for me...
     
  25. Offline

    Mordenkainen

    You need to provide a bit more info than that.

    What errors did you get, What plugins are you running, etc.
     
  26. Offline

    FarSideX

    Could you post a version that works with RedstoneChips .93 ?

    We just upgraded from a 1.7.3 server and this plug in was used quite a bit, updated RedstoneChips along with the server only to find this not working. I would post more details but you already noted that it doesn't work with versions > .9
     
  27. When I try to start my server with this plugin on, I get the following error -

    Code:
    2011-12-21 13:23:12 [SEVERE] Error occurred while enabling RedstoneChips v0.93a (Is it up to date?): org/tal/redstonechips/channels/ReceivingCircuit
    java.lang.NoClassDefFoundError: org/tal/redstonechips/channels/ReceivingCircuit
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(Unknown Source)
        at java.security.SecureClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.access$100(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:36)
        at org.bukkit.plugin.java.JavaPluginLoader.getClassByName(JavaPluginLoader.java:221)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:32)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:24)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(Unknown Source)
        at java.security.SecureClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.access$100(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:36)
        at org.bukkit.plugin.java.JavaPluginLoader.getClassByName(JavaPluginLoader.java:221)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:32)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:24)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(Unknown Source)
        at java.security.SecureClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.access$100(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:36)
        at org.bukkit.plugin.java.JavaPluginLoader.getClassByName(JavaPluginLoader.java:221)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:32)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:24)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at org.morden.lightcontrol.LightControl.getCircuitClasses(LightControl.java:22)
        at org.tal.redstonechips.RedstoneChips.loadLibraries(RedstoneChips.java:309)
        at org.tal.redstonechips.RedstoneChips.onEnable(RedstoneChips.java:67)
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:188)
        at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:968)
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:280)
        at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:186)
        at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:169)
        at org.bukkit.craftbukkit.CraftServer.<init>(CraftServer.java:128)
        at net.minecraft.server.ServerConfigurationManager.<init>(ServerConfigurationManager.java:52)
        at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:145)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:399)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:457)
    Caused by: java.lang.ClassNotFoundException: org.tal.redstonechips.channels.ReceivingCircuit
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:36)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:24)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        ... 58 more
    if i remove this addin, redstone chips works again.
     
  28. Offline

    bob82604

    Is this plugin going to be developed any more?
    It no longer works with the new version of redstone chips!
     
  29. Offline

    Mordenkainen

    Sorry about the long absence all!
    I have had some work and computer issues and haven't been able to do much of late.

    I hope to have a new version of Lightcontrol up this week.
     
  30. Offline

    Mordenkainen

    Ok, version 0.3 is up. It should be compatible with the latest RC and Bukkit.

    There are no feature changes in this version, it is simply a compatibility update, but I hope to be more active in my development and have some new features in the near future!

    I can't wait until lamposts and chandeliers are working!

    BTW, what are the materials that people most often build their lights out of? I typically use glowstone, fence posts, and wood planks for the normal world and glowstone, nether fence, and nether brick for the nether. Looking for input because the lamp post detection system will be material based.

    Once again, sorry for the long absence, but it was unavoidable!

    Morden.
     

Share This Page