ProximityDetector
Proximity Detector
Description
Proximity detector is a mechanics plugin for redstone circuits. When a proximity detector is created, it has a radius value attached to it. If any players enter that radius, the detector is activated and any redstone surrounding the detector is powered. When all players have left the radius, it is deactivated and the redstone is no longer powered.
Creation
Any player with the proper permissions will be able to create proximity detector. To create a proximity detector, the player must place a sign with the top line reading [proximity] and the second line with the radius of the detector.
Example,
[proximity]
5
This would create a proximity detector with a radius of 5.
Destruction
To destroy a proximity detector simply break it and a message will confirm it's destruction.
Permissions
'proximity.create' - Required to create a ProximityDetector
Config
LagRestricter: The processing speed of the plugin. A higher value means more responsive proximities and more processing power used by the plugin.
MaxProximity: The max range allowed on Proximity Detectors. A value of 0 allows infinite range.
EnforceOnExistingSigns: If true, any existing signs over the MaxProximity value will be lowered to match it.
database: The database type, flatfile or MySQL. If you plan on giving this plugin to all players and are expecting lots or sensors I would recommend MySQL, otherwise flatfile works fine.
mysql etc: Your MySQL settings. Only needed if using MySQL.
Optional Dependencies
MySQL
MySQL is an optional database for ProximityDetector. Upon first run a config file will be generated, place your MySQL information there.
@Waslay
I'll see what I can do.
Any chance you could make it so the signs act like redstone torches? I want to place a detector under a door/fence gates/etc. so that when you walk into it it opens without pressure plates. This is difficult at the moment because I need to place a detector, then redstone, then a repeater, then a block with a torch on top, and even then it's still backwards... which makes the whole set up worthless...
Also, could you make an option to have it inverted? That would at least make it so the set up I just mentioned isn't backwards.
@huntershenep
Done. I've added a couple settings in the config file that allow you to set a maximum range for proximity sensors as well as the ability to enforce this range on all prexisting proximities.
Hope this suits your needs.
Very nice plugin! could you add a config for maximum proximity?
@Kahanamoku78
I just compiled a new version that has been error free for me on 1.7.2 and 1.7.9. If you still use this and are still having trouble let me know.
Sorry for the absence.
Any chance you're going to look at the Null Pointers at any stage on 1.7.2?
[08:44:53 INFO]: [ProximityDetector] Enabling ProximityDetector v1.3 [08:44:53 INFO]: [ProximityDetector] LagValue set to: 100 [08:44:53 INFO]: [ProximityDetector] ProximityDetector Enabled [08:44:53 ERROR]: Error occurred while enabling ProximityDetector v1.3 (Is it up to date?) java.lang.NullPointerException at ca.shaw.andrewbailey.Proximity.getBlock(Proximity.java:64) [?:?] at ca.shaw.andrewbailey.ProximityDetector.checkDuds(ProximityDetector.java:243) [?:?] at ca.shaw.andrewbailey.ProximityDetector.onEnable(ProximityDetector.java:63) [?:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:250) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:350) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:389) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at org.bukkit.craftbukkit.v1_7_R1.CraftServer.loadPlugin(CraftServer.java:439) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at org.bukkit.craftbukkit.v1_7_R1.CraftServer.enablePlugins(CraftServer.java:375) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.m(MinecraftServer.java:342) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.g(MinecraftServer.java:319) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.a(MinecraftServer.java:275) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at net.minecraft.server.v1_7_R1.DedicatedServer.init(DedicatedServer.java:175) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.run(MinecraftServer.java:424) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks] at net.minecraft.server.v1_7_R1.ThreadServerApplication.run(SourceFile:617) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-b3020jnks]
I LOVE YOU ROKER, YOU ARE Awesome! This plugin works and is amazing!! I can finally make my dream adventure map without piles of redstone :D
Huehuehue Roker has a plugin
Plugin updated to 1.6.4 with this, @Felix_The_Ghost feature added.
Sorry for the absence.
Is this project dead?
Why am I not seeing the permissions folder for this plugin. I restarted the server......
Update?
Question: Could you update this plugin to support floating point values? For the value I need, 3 is too soon and 4 is too late, so 3.5 would work. Is this possible?
Great plugin bro :)
@Enkious
Gotcha
Can you please make MySQL not a Dependence.