RailSwitcher
RailSwitcher
Allows you to rotate rail pieces so that you can turn that one annoying piece that won't go the way you want it to. To do this, right click on a rail with the type of rail you are trying to change or with shears. It also allows you switch out one type of rail for another by right clicking with another type of rail. An example would be that you placed a powered rail and want a detector rail, just right click on the placed powered rail with a detector rail and you are set.
Download: BukkitDev
Source Code: Github
Permissions
- railswitcher.admin - Allows use of admin commands.
- railswitcher.switch: Sets all swap and rotate perms
- railswitcher.swap: Allows swapping of rails.
- railswitcher.rotate.tool: Allows rotating using the tool defined in config.yml
- railswitcher.rotate.rail: Allows rotating using the same rail type.
Commands
- /railswitcher - Main Command
- Alias: /rs
- /railswitcher reload - Reloads all config files.
- /railswitcher perms - Op's and Admin's can use this to see the plugin's permissions.
Changelog
See the full changelog on github.
PROBLEM OR BUG?
If you are having any issues or encounter any bugs, check the issue tracker on github first, and submit a new one if needed.
If you like my plugins or want to see me make more plugins, please consider donating. There's a donate button at the top of the page.
@ChillerKraft
The changelog may be a bit confusing about this, sorry. This plugin only allows you to rotate rails. The blocks list mentioned in the changelog is the blocks that rails can attach to.
this plugins not working well with me when it comes to stairs, unable to rotate... im using 1.7.9 ro2 beta, i tried using 1.1 and 1.0.9 and they both work with rails and that stuff but not stairs
@CommodoreAlpha
Just uploaded version 1.0.8. I have tested it with CoreProtect and WorldGuard, but it should theoretically work with any protection and block logging plugins now. Please let me know if it works for your plugins.
Thanks, Haveric
@haveric
I use Residences, so Residences support would be nice. Thank you for your support - I really appreciate it. :)
The big four region-protection plugins would be Grief Prevention, Towny, WorldGuard, and Residence. There are more that are routinely used, I know, like Regios, but they're not nearly as "big".
@CommodoreAlpha
A bit more about protection plugins. RailSwitcher currently support Towny and WorldGuard. If there are others that you would like to see supported, let me know.
@CommodoreAlpha
Shield unfortunately hasn't been updated for almost a year. Also, it only hooks into 4 protection plugins. This would be a great project if there was a team working on it and is actually something I considered doing myself, but the scope of it is too big for just one person.
It also is not ridiculous to have protection plugins supported even for small things like this, I would love to get full support of protection plugins for all of my own plugins, but at this time, that just isn't possible.
Hmm, have you considered looking into Shield to automatically send the event to all protection plugins too? I know it sounds ridiculous to have to consider protection plugins for such a small feature like switching rails, but it's not an entirely invalid idea to consider.
@CommodoreAlpha
Currently, it will send events to CoreProtect and LogBlock. I don't currently know of a way to send a BlockChangeEvent so that every plugin will catch it, but if someone else does, I'd be willing to implement it. Otherwise, let me know what plugin you'd like to see supported and I can look into it.
Does this fire off some sort of BlockChangeEvent so that any kind of protection plugin can catch it?
@CommodoreAlpha
This was caused by the client changing how right clicking worked and not providing the same information that it used to. I attempted to fix it which is why it sorta works, but the bukkit function doesn't work as I expected it to.
I haven't looked into solutions for a while so there may be new ways to fix it, but if anyone can show me a plugin that works correctly for right clicking, it might help.
There's an annoying bug, but it's not serious at all. Whenever I try to switch a set of rails with another type of rail (e.g. I right click a "Rail" block with "Powered Rail"), it will switch the rails around it, rather than the rails I'm looking at. If this description is too abstract, then look at this example.
P A B C
-----------------------------------------------------> (Line of Sight)
Distance
P = player; A = rails that are closer to me; B = rails I'm looking at; C = the furthest set of rails
If me, the player, tries to flip out the rails at point B with another type of rails, the action will be applied to the rails at point A, rather than the rails at point B. The set of rails at point C is completely unaffected.
@haveric
That would be awesome and I'd be happy to test it for you :)
@Iomega0318
I don't use custom items, so I'm not sure how easy it would be to handle. It might be possible with a custom id list and I'll see if I can implement that in the next version.
@haveric
Well I am still on 1.2.5 waiting on my mods to update so it still works fine for me lol, I love being able to switch the tracks around! I also did find out that it does not work on switching out rails with custom ones, for example Tracks from Railcraft..
Other than that though works great and love it, awesome work!
@Iomega0318
There actually is a bug with Bukkit so right clicking with rails in hand won't work, but using shears still will. Hopefully that will be fixed soon, and when it is, I'll push an update with a few other changes as well.
@haveric
Ahh ok I didn't know if it worked on 1.3+ there's no comments lol! I am still on 1.2.5, does this work with custom rails as well?
@Iomega0318
What would you like to see updated? The plugin still works fine on the latest versions of Bukkit and there is nothing I can think of to add currently.
Is this going to be updated?