Fix a few edge cases with Bungee gates

This commit is contained in:
Steven Scott 2012-11-24 15:58:47 -08:00
parent ac520665e6
commit d464a16e38
3 changed files with 10 additions and 2 deletions

View File

@ -49,3 +49,4 @@ chargefreedestination: true
freegatesgreen: false freegatesgreen: false
debug: false debug: false
permdebug: false permdebug: false
enableBungee: false

View File

@ -1366,7 +1366,7 @@ public class Portal {
if (!portal.isFixed()) continue; if (!portal.isFixed()) continue;
if (portal.isBungee()) { if (Stargate.enableBungee && portal.isBungee()) {
OpenCount++; OpenCount++;
portal.open(true); portal.open(true);
portal.drawSign(); portal.drawSign();

View File

@ -814,6 +814,13 @@ public class Stargate extends JavaPlugin {
Stargate.sendMessage(player, Stargate.getString("teleportMsg"), false); Stargate.sendMessage(player, Stargate.getString("teleportMsg"), false);
if (portal.isBungee()) { if (portal.isBungee()) {
if (!enableBungee) {
player.sendMessage(Stargate.getString("bungeeDisabled"));
portal.close(false);
return;
}
portal.teleport(player, portal, event); portal.teleport(player, portal, event);
// Teleport player via BungeeCord // Teleport player via BungeeCord