WorldGuard Region Commands
WorldGuard Region Commands
"WorldGuard" extension to make the server/a player automatically execute a command when he enters or leaves a WorldGuard region.
How to use this?
this plugin adds some new region flags to worldguard: player-enter-command, player-leave-command, server-enter-command and server-leave-command.
Each of these flags can store multiple commands that are separated with a comma. The player-enter-command and player-leave-command commands will be executed by the player who enters/leaves a region. The server-enter-command and server-leave-command commands will be executed by the server if a player enters/leaves the region.
so simply use the usual WorldGuard region command, like this:
/region flag <region> player-enter-command /list
to make the player execute /list, or
/region flag <region> server-leave-command /say Someone left the region.
to make the server execute the /say command when a player leaves the region.
You can use
/region flag <region> player-leave-command
to clear the value of the flag.
Additionally some substrings will be replaced:
- {player} will be replaced with the name of the player who entered/left the region
- {region} will be replaced with the name of the region the player entered/left
- {comma} will be replaced with a comma as it is normally used to execute multiple commands
Permissions
- none yet
Dependencies
The plugin requires the latest WorldGuard Custom Flags and WorldGuard Region Events.
Click here for some other plugins using WorldGuard Custom Flags.
Problems ?
If you have problems with this plugin read the F.A.Q.. If this did not help you, you can receive help here.
@YanPerez
Why? Doesn't it work for you? If yes please create a thread in the forum.
please update
It's not working, it broken. Please update.
Why can't people who enter or leave a region (that i configured) see the messages i configured? please help.
@LHfreeman
yes, use comma
Is that possible to, set more than one Command?
Why don't the flags work on global regions ? I want players to have their fly turned off when they enter any part part of a specific world, but I cant disable it on the ' global ' region.
@FakeTheRealHD
Are you using MyCommand? If so, use /mycmd-runas player <player> <command>
Yes, a cooldown would be great. Or make it so that it performs a separate command when they first enter the region? That would be awesome! :)
Any way I can make it do /server <Server-name>?? When I execute this even with CommandSigns plugin it says "Unknown Command...." Why is this happening?
@diannetea
I would be also happy to have a cooldown
@diannetea
Its not possible yet, but I could maybe add it.
Hi, I'm trying to use this to set up invitations to private warps in locations, however it invites them every single time they run through the warp. Is there any way to limit the number of times it runs the command on the player? Or could one be added?
@BensDaMan You need to install WG Custom Flags & WG Region Events
@der_mewin
The plugin is not working. I can create the region, flag it but when i enter the region this error shows up on console! The box has Java 7.
2013-12-14 17:49:42 [SEVERE] Could not pass event PlayerMoveEvent to WorldGuard org.bukkit.event.EventException
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:304) at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:482) at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:467) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:215) at net.minecraft.server.Packet10Flying.handle(SourceFile:126) at net.minecraft.server.NetworkManager.b(NetworkManager.java:234) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:119) at net.minecraft.server.NetworkListenThread.a(NetworkListenThread.java:83) at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:579) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:467) at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
Caused by: java.util.ConcurrentModificationException
at java.util.HashMap$HashIterator.nextEntry(HashMap.java:894) at java.util.HashMap$KeyIterator.next(HashMap.java:928) at com.mewin.WGRegionEvents.WGRegionEventsListener.updateRegions(WGRegionEventsListener.java:117) at com.mewin.WGRegionEvents.WGRegionEventsListener.onPlayerMove(WGRegionEventsListener.java:51) at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:302) ... 11 more
@TheCoolGuy123_5_Minecraft
I know its a little late, but its {player}, not {name} .
This plugin have strange problem, on some restart, they will completly erase all the custom flag of all regions, for no reason... Please fix it !
Working fine on 1.6.2
One problem through is, I made it when you go into the spawn, the server will do /heal {name} and it does nothing. The variables are broken.
Isn't working for me, running 1.6.2
This plugin breaks igates.
would be nice if there was compatibility with 1.2.5