Inactive [MECH/FUN] TorchArrow v0.9 - Makes an arrow to emit light and spawn a torch on impact [1.2.5-R1.0]

Discussion in 'Inactive/Unsupported Plugins' started by KillerFox, Aug 18, 2011.

  1. Offline

    KillerFox

    TorchArrow - In thy light shall we see light

    Version: v0.9 (Supports CraftBukkit RB 1.2.5-R1.0)
    (Migrated to dev.bukkit.org, but I will post all the updates here too until BukkitDev takes over completely)


    [​IMG]
    Description:
    Adds three new arrow types that emit light while flying: a torch arrow, a redstone torch arrow and a flare arrow. While flying in the air, the torch arrows illuminate the blocks around them and finally spawn a torch when the target is reached. The torch arrow will place a normal torch on impact and redstone torch places a redstone torch. The normal torch arrow can be also set to melt ice and snow instantly in arrow glow radius by changing permissions. With redstone torch arrow you can also e.g solve different kind of redstone circuit puzzles or activate circuitry from distance. Finally, you can set the torch arrows to burn hit enemies by a defined change by tuning values in the config-file. The flare arrow does not spawn any torches, but emits light and goes out after a predefined time. Check out the full feature list below and read the instructions!

    Features:
    • An arrow with a cool dynamic light effect that illuminates dark places in air or water in predefined radius.
    • Light around player that illuminates the blocks around and follows the player. The light can be turned on by charging the bow or by right clicking the mouse while the bow is active and the required materials are in place.
    • A torch or a redstone torch is placed on the block that the arrow hit.
    • Placed torches can be removed by shooting them with a normal arrow.
    • Torch Arrow glow melts ice and evaporates snow.
    • Set block on fire with flare arrow or with torch arrows when torch placing is disabled
    • Hit enemies can catch fire by a defined chance.
    • The arrow light of flare arrows will go out after impact and after a predefined time has passed
    • Customize your arrows by changing the settings!
    • Supports Bukkit permissions API
    Possible Future Features (open)


    Usage:
    One can shoot arrows of one of the torch arrow type if he has an arrow stack in any slot in the inventory and a torch stack, a redstone stack or a glowstone dust stack on the right side of the bow. If previously mentioned conditions are not met, the bow will shoot arrows normally.

    Torch arrow works best in very dark places and in night time on the surface area, and can be also used to brighten dark areas under water to see what is in the bottom of the watery grave.
    The Arrow Types (open)

    • Torch Arrow:
      • Places a normal torch on impact.
      • Melts ice and evaporates snow instantly.
      • Sets enemy on fire by a predefined chance.
      • Does more damage than a normal arrow. (Compensating the shooting delay and not being able to charge the bow)
      • Emits light around it while flying.
      • Sets blocks on fire (if setting enabled and torch spawning disabled)
    [​IMG]
    • Redstone Torch Arrow:
      • Emits light while flying.
      • Places a redstone torch on impact.
      • Sets enemy on fire. (Half time on fire compared to torch arrow)
      • Does half of the damage compared to normal arrow.
      • Sets blocks on fire (if setting enabled and torch spawning disabled)
    [​IMG]
    • Flare Arrow:
      • You can change the flare arrow material (default material is glowstone dust)
      • Emits light while flying.
      • Goes out after predefined time has passed after impact.
      • Does no damage.
      • Has bigger light radius on impact than while flying
      • Sets blocks on fire (if setting enabled)
    [​IMG]

    Light around player
    Before you shoot one of the torch arrow types, the arrow illuminates the area around the player for a predefined time period. The light has same intensity and radius as the active torch arrow type and it will follow the player while it is on. When the light turns off it will consume one piece of the material needed for the active arrow type, but no arrows will be consumed. This feature can be turned off by changing playerLightTime-setting to 0 in config.
    • How to activate the light?
      • Charge the bow while torch arrow materials are in place: If you keep the bow charged the light will illuminate the area around you and it will go out after a defined time (defined in config).
      • Click the right mouse button once fast while the torch arrow materials are in place: Same as above.
    • How to turn off the light?
      • The light will turn off automatically when a certain time has passed (defined in config) and it will consume a piece of the required material.
      • Click the left mouse button when the bow is in hand: The light will turn off and it will consume a piece of the required material.
      • Change the active item from bow to another item in hand inventory: Same as above
      • Shoot the active arrow type: The light will go off and a piece of material and an arrow will be consumed normally.
    Commands:
    • /torcharrow reload (Reloads the config file)
    Settings explained (open)

    • spawnTorches: Enable/disable torch spawning on arrow impact. If set to false, this overrides the preset permissions
    • smoothLighting: Activates a smoother lighting effect. This may slow down your server a bit.
    • playerLightTime: The time (in seconds) that the arrow will light the area surrounding the player while charging the bow (or otherwise activated). IF set to 0, this light effect will not be used.
    • arrowGlowIntensity: Intensity of the light coming out from the arrow while it is flying. (allowed values: 0-15)
    • lightRadiusFactor: Increases or decreases the light radius around a flying arrow (values: 0.1-3.0). (NOTE: Setting this too big will make your server cry :C)
    • delay: The delay affects on how rapidly you can shoot the torch arrows. A normal arrow is used if trying to shoot before the delay timer is finished! (unit: milliseconds) It doesn't affect the usage of normal arrows. (The delay is added to avoid spamming of the torch arrows because the lighting effect of the arrow can be computationally expensive and slow down the server.)
    • dmgMultiplier: Damage multiplier for the arrow. (Dmg = Normal arrow dmg * multiplier)
    • burnChance: Chance that the arrow lights hit entity on fire. Values: 0.0 - 1.0
    • burnDuration: Indicates how long time (in seconds) the hit entity is on fire.
    • setBlockOnFire: Sets block on fire (if no torches spawn).
    • flareGlowTime: Defines the time (in seconds approximately) how long the flare will glow after impact.
    • impactRadius: Works like the 'lightRadiusFactor'. This affects the light radius of the flare when it hits the ground. (NOTE: Setting this too big will make your server cry :C)
    • material: Material used for the flare arrow (use item IDs)
    • warningMsg: Warns if you try to shoot without arrows. (leave empty to remove warning)
    Default Permissions (open)

    Code:
    permissions:
        torcharrow.melt:
            description: Allow/disallow player to melt snow, snow blocks and ice blocks instantly with tArrow.
            default: active for op only
        torcharrow.burn:
            description: Allow/disallow player to set enemy on fire
            default: active for every player
        torcharrow.setBlockOnFire:
            description: Allow/disallow player to set block on fire (if no torch is spawned)
            default: active for every player
        torcharrow.torch:
            description: Allow/disallow normal torches to be spawned.
            default: active for every player
        torcharrow.redstone:
            description: Allow/disallow redstone torches to be spawned.
            default: active for every player
        torcharrow.tArrow:
            description: Allow/disallow normal torch arrows
            default: active for every player
        torcharrow.rArrow:
            description: Allow/disallow redstone torch arrows
            default: active for every player
        torcharrow.fArrow:
            description: Allow/disallow flare arrows
            default: active for every player
        torcharrow.reloadcmd:
            description: Allows player to use "/torcharrow reload" in game to reload config.
            default: active for op only
        torcharrow.enable:
            description: Enable/disable the whole plugin for a player.
            default: Enabled for every player 


    Download the plugin
    (If BukkitDev doesn't have the newest version yet, get the plugin from here.)


    Changes:
    Full Changelog

    Version 0.9
    • Support for CraftBukkit Beta Build 1.2.3-R0.1 #2034
    • Bow charging supported
    • Arrows can set blocks on fire (check out the setting in config-file and the new permission setting (torcharrow.setBlockOnFire)
    • Added light effect that follows the player
    • Rewrote the config-file: - Each arrow type can now be customized much better! (e.g bows now have separate delays) - Added some new settings
    • Added new permission-setting: torcharrow.setBlockOnFire
    • Refactored the whole code and made some big changes under the hood.
    • Flare arrow has now impact light radius that can be changed in the settings
    Did you find a bug? (open)
    I would be happy if you could read this guide before posting bug reports. It's waste of time to ask every detail of the problem as you could just post all the relevant details in one message. Also, I would recommend you to use the fresh devBukkit ticket system, because with it you can categorize the error more easily, and there are some clever questions in which you can answer to describe the problem effectively. The tickets are also emailed to me daily.
    Known bugs (open)

    • If flare arrows are spammed too much on the same area, some blocks may stay lit after the torch arrows are burned out. The glow can be removed afterwards by shooting a new glowing arrow on the area. One should use flare arrow in more relaxed game play, not in all-out war.
    • If a glowing arrow is shot into water, a faint glow will remain on the bottom after the arrow is died out. This bug is most probably related with this vanilla minecraft bug: http://www.minecraftwiki.net/wiki/Known_bugs#Torches]] (at torches under water section)
     
  2. Offline

    Pwnsaucier

    First, and most importantly, thank you for creating this plugin. I love the idea, and I really want to be able to integrate it into my server.

    I have a problem, though. The torcharrow.disable permission node is causing me serious grief in trying to get this plugin working properly. I'm using PermissionsEX. I use the simple '*' as a quick and easy way to have access to everything for my superadmin group, but in doing that, it also seems to enable torcharrow.disable, meaning that everyone BUT superadmins can use torcharrow. This seems backwards to permission node configurations of other plugins I've used. I've searched for a way to exclude 'torcharrow.disable' for the superadmin group in PEX, but is either impossible or undocumented. I 100% agree with CapnObvious' suggestion to change it to 'torcharrow.enable', or just remove it altogether so that one must be given the correct permission nodes to be able to use torcharrow in the first place. Seems like that would be pretty normal to me, yes?
     
    KillerFox likes this.
  3. Offline

    KillerFox

    Hi, I would be happy if you could read this guide before posting bug reports afterwards. It's waste of time to ask every detail of the problem as you could just post all the relevant details in one message. Also, I would recommend you to use the fresh devBukkit ticket system, because you can categorize the error more easily and there are some clever questions which you can answer to describe the problem effectively. The tickets are also emailed to me daily.

    Now, getting back to the business. I never encountered your problem while testing it extensively. The error message you had, hints that you don't have the newest craftbukkit build (1060) or there is a some other problem that is not related to this plugin. I however, changed the way the torch arrow impact with enemy is handled, so I don't think this error will come up anymore.

    Thank you, I appreciate your compliment. Anyhow, you were a tad late with the suggestion ;) I already changed "torcharrow.disable" to "torcharrow.enable" in the new 0.7 update. Hopefully the plugin works better now with the pEX '*'-notation.

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

    -jaras-

    good photo [creeper][arrow]
     
  5. Offline

    Pwnsaucier

    Thanks for the 0.7 update. I'm now happily using this plugin on my server! :D
     
  6. Offline

    Hoot215

    Will this work in 1.8 with the new lighting engine? About to test anyway... Fingers crossed.
    EDIT: Unfortunately, it does not work in 1.8 (Probably because of the new bow mechanics). When I try to fire a torch-arrow, it begins to start the pulling back animation, and then restarts the animation a split second later and keeps repeating. However, the bow will only actually fire an arrow approximately 1/4 times. And the the arrow doesn't light anything up. Oh also, I got this error in the console:
    Show Error
    18:02:17 [SEVERE] Could not pass event PLAYER_INTERACT to TorchArrow
    java.lang.NoSuchMethodError: net.minecraft.server.WorldServer.b(Lnet/minecraft/server/EnumSkyBlock;IIII)V
    at me.KillerFox.torchArrow.TorchArrow.lightUpBlocks(TorchArrow.java:361)
    at me.KillerFox.torchArrow.TorchArrow.lightArrow(TorchArrow.java:395)
    at me.KillerFox.torchArrow.TorchArrowPlayerListener.onPlayerInteract(TorchArrowPlayerListener.java:130)
    at org.bukkit.plugin.java.JavaPluginLoader$11.execute(JavaPluginLoader.java:314)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338)
    at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:161)
    at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:132)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:558)
    at net.minecraft.server.Packet15Place.a(SourceFile:57)
    at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:91)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:108)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:464)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    18:02:23 [WARNING] Task of 'TorchArrow' generated an exception
    java.lang.NoSuchMethodError: net.minecraft.server.WorldServer.b(Lnet/minecraft/server/EnumSkyBlock;IIII)V
    at me.KillerFox.torchArrow.TorchArrow.lightUpBlocks(TorchArrow.java:361)
    at me.KillerFox.torchArrow.TorchArrowEntityListener$1.run(TorchArrowEntityListener.java:187)
    at org.bukkit.craftbukkit.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:137)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:439)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
     
  7. Offline

    KillerFox

    Hi, thanks for the report. I will start fixing the plugin when the bukkit crew has stabilized the new bukkit version. It's also probable that the Minecraft crew will still publish some more bug fixes for the 1.8 update in near future. I have also planned some nice new features for the new v0.8 update, so stay tuned :) (ps. could you also publish a detailed bug report ticket at here, so I can easily see all the reported bugs listed in one place.)
     
  8. Offline

    mrgreaper

    hi, i was looking at a large chasm and thinking if only i could shoot a light up there.... and searched torch arrow... i didnt expect to find a plugin so spot on lol

    we are on torch arrow 0.7
    craftbukkit 1124 (non rb i know but theres no rb for 1.8 yet and this is more a heads up then a please please please make this work)

    with the bow arrow torch setup and default settings when the bow is fired it wont let you charge the bow it fires instantly, the arrow and the torch decrease by one but the torch is sent to silicone heaven (to be with all the little calculators) and doesnt appear, the arrow also does not emit light.
    the server log shows
    Code:
    06:17:58 [SEVERE] Could not pass event PLAYER_INTERACT to TorchArrow
    java.lang.NoSuchMethodError: net.minecraft.server.WorldServer.b(Lnet/minecraft/server/EnumSkyBlock;IIII)V
            at me.KillerFox.torchArrow.TorchArrow.lightUpBlocks(TorchArrow.java:361)
            at me.KillerFox.torchArrow.TorchArrow.lightArrow(TorchArrow.java:395)
            at me.KillerFox.torchArrow.TorchArrowPlayerListener.onPlayerInteract(TorchArrowPlayerListener.java:130)
            at org.bukkit.plugin.java.JavaPluginLoader$11.execute(JavaPluginLoader.java:314)
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338)
            at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:161)
            at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:132)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:558)
            at net.minecraft.server.Packet15Place.a(SourceFile:57)
            at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:91)
            at net.minecraft.server.NetworkListenThread.a(SourceFile:108)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:464)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    
    im off to sleep, hope this helps, ill certainly be keeping an eye on this plugin!
     
    Omen likes this.
  9. Offline

    Mercury

    1.8.1 RB released :p
     
  10. Offline

    KillerFox

    Yes, I have been working on the update for a few days now (and also made an another plugin) I will release the v0.8 update today or tomorrow :)
     
    mrgreaper likes this.
  11. Offline

    Mercury

    @KillerFox
    This plugin also uses lightning like your one does and you should be familiar with that.
    Could you please update it for 1.8.1?
     
  12. Offline

    KillerFox

    Sure I can if I can find enough free time for that. I have however, planned a similar functionality for TorchArrow after I can somehow hook the bow charge event to my plugin. (Might have to wait a bit for that) With the functionality a player could keep the bow in charged mode and the torch arrow light would follow the player, maybe a certain predefined time, and the light would then die. And if the light dies the bow would just shoot a normal arrow when the charge is released. Much like a real fire arrow.
     
  13. Offline

    ipaqmaster

    Looks awesome, but I installed it, permissioned it and I can only shoot normal arrows =c
    Is there something im missing?
     
  14. Offline

    mrgreaper

    i followed the download link but only 0.7 is on there is it a typo ?
     
  15. Offline

    KillerFox

    The v0.8 file is still waiting approval in the dev.bukkit. Just download it from the dropbox link below the big download link.

    I have tested the plugin rigorously, so it should work. But if you tried to download it from dev.bukkit (the old 0.7 version is there, because the new version is still waiting approval) it won't work. Download it from here.

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

    mrgreaper

    ah ok will do
    should of known it was a bukkitdev site issue, from a server admin view that site is a disaster!

    well test out 0.8 in a few secs, been looking fwd to this one
     
    KillerFox likes this.
  17. Offline

    ipaqmaster

    That version works much better ^_^ Thanks!
     
    KillerFox likes this.
  18. Offline

    mrgreaper

    works wonderfully my players when they awake will love it

    i have one request for version 0.9, can u allow the shot to be charged like the normal arrows, it will feel more natural and of course go further :)
     
  19. Offline

    KillerFox

    I would have added that feature for 0.8 already, but I couldn't come up with any sensible and reliable method to do that. I'll have to wait that the Bukkit Team approves my feature suggestion, or I'll have to do some magic tricks to get that done. Hopefully I can implement it for v0.9 :)
     
    mrgreaper likes this.
  20. Offline

    Evilhaunting

    screen shot or video please?
     
  21. Offline

    KillerFox

    I would happily make a video about the plugin, but I don't currently have the time and software for creating a quality instructional video. However, I would appreciate if someone could make a video, and post it into youtube, so I can embed it here.
     
  22. hm what about if player has torches with him/her at inventory, starts shooting arrows does it consume / activate this plugin always ? so basicly ppl cannot carry torches with them if they want to fire normal arrows?
     
  23. Offline

    KillerFox

    No. The torch arrow is only activated if torch/redstone torch/glowstone stack is placed on the right side of the bow. The normal arrow stack can be placed in any slot. I wonder if you have read the instructions? :)
     
  24. obviously i havent, im sorry i was in a bit hurry when posting so i had no chance to read the instructions ^^
     
  25. Offline

    cadwal

    Oooh.... this is a nice addon. I'm gonna have to add this to my server soon. Makes for some great Zelda style dungeons.
     
  26. Offline

    Kardocraft

    Nice plguin but can you maybe do that you need to charge the bow and that it then shoot.
     
  27. Offline

    KillerFox

    Yes, I would have done that already for the v0.8 if it could be done sensibly. It's very possible that we'll have to wait that the Bukkit dev team approves my suggestion so the feature can be implemented reasonably. I hope that I can do that feature for v0.9 :)
     
  28. Offline

    Kardocraft

    Ah ha thank you for responding.
     
  29. Offline

    Bseagull

    Am i missing something in the post? How do you craft the arrows? I'm definately going to get this though. :)
     
  30. Offline

    KillerFox

    Yes. You don't have to craft any of the torch arrows :) Just put normal arrow stack anywhere in your inventory and a torch stack or redstone torch stack or glowstone dust stack on the right side of your bow in the hand inventory. Check the different arrow types in the description.
     
  31. Offline

    Bseagull

    Awesome ill get it when it updates and when bukkit updates :)
     

Share This Page