RedProtect Anti-Grief

RedProtect Anti-Grief

73.3k Downloads

[BUG] Player can't teleport from region with "can-move" false

Krosta8 opened this issue ยท 6 comments

commented

Describe the bug
Player is in a region. Owner of the region change flag "can-move" to false. Player can't move, that's expected, but also can't teleport outside of the region (/home, /tpa, etc.. tried with CMI plugin, but I think, that is not related).

To Reproduce
Steps to reproduce the behavior:

  1. Create region
  2. Another player step into the region
  3. Flag "can-move" change from true to false
  4. Player without permissions can't teleport outside of the region.

Expected behavior
Player should be able to teleport out of the region or kick all non-members from the region, if this flag is set to true, but there could be problem with the kick, that it should kick them in a danger place (lava, etc..)

Server and plugins versions (please complete the following information):

  • Server: Mohist 1.12.2 (build 532)
  • Plugin Version: RedProtect-7.6.7-b325-Universal.jar
  • Java Version: Java 1.8
commented

Jup they get stuck, but Redprotect is doing no nothing wrong here. If your using nether portals on your server i suggest to l gibe your players permission in the gui to the portal flags portal-enter (allows entering portal on a zone for stangers) portal-exit (allow entering a portal if the exit leads into a region) and allow-create-portal (allow building Portals in Region and deny it if exit would be created in a region on the exit site)

Its a problem of wrong handling if you allow netherpotals + cant move in one region and wonder why player gets stucked when he enters this, also fabrizio is right. Teleporting is also some kind of moving. I would not give a cant move flag to Player to prevent trolling. I suggest giving them other flags to manage their region. It can be setup so stangers have no chance to do to nasty things or handle wrong like in your Situation with the netherpotals

Finaly Redprotect does nothing wrong, so its no bug. Think of a better way for the Configs to avoid this Problem you got. It can be manged :)

commented

Oh, so sorry, didn't know, that this flag can solve my problem. I set in config portal-exit=false and remove players permission to change this flag, so I can give them back permission for can-move flag and the problem with stuck in portal will never happen again.
Thanks! :)

commented

i recomment to define it in your enabled flags for the GUI - waht means its defined for there regons when new created or someone open the GUIflag in the region.
Snag_b0169d
you fine the flags here in the wiki
Since these are adminflags your dont need to give permission for this if you dont want your players to change it.
if you want this then you nedd to define it in config, in the GUI (slot,icon, description,name)
give players the Permission
Permission: redprotect.flag.(flagname) (so 3 permissions for the 3 adminsflags to become userflags)
then they are able to see the flags in the GUI and are allowed to change them in their regions.

commented

Ok, good to know, thanks

commented

This is intended. If cant move it cant teleport too

commented

But the problem is with portals.
Player can go through portal from Nether to overworld and got stuck in Nether portal, can't do anything.

EDIT:// Maybe add check before teleport to the location, if the player has permission to move in the region on the other side of the portal or kick the player from the region, if gets into the specific region.