summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsnowleo <snowleo@e251c2fe-e539-e718-e476-b85c1f46cddb>2011-03-30 13:28:57 +0000
committersnowleo <snowleo@e251c2fe-e539-e718-e476-b85c1f46cddb>2011-03-30 13:28:57 +0000
commit903ccfc7988abd4aa2cc87844a88a912cd44f6c0 (patch)
tree6b1a756c43de9fdbe54874650af5be0c0ee0fbea
parent79d251893915b758191eb6dd27d4e322a66f3551 (diff)
downloadEssentials-903ccfc7988abd4aa2cc87844a88a912cd44f6c0.tar
Essentials-903ccfc7988abd4aa2cc87844a88a912cd44f6c0.tar.gz
Essentials-903ccfc7988abd4aa2cc87844a88a912cd44f6c0.tar.lz
Essentials-903ccfc7988abd4aa2cc87844a88a912cd44f6c0.tar.xz
Essentials-903ccfc7988abd4aa2cc87844a88a912cd44f6c0.zip
Commit 1001
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1027 e251c2fe-e539-e718-e476-b85c1f46cddb
-rw-r--r--Essentials/src/com/earth2me/essentials/User.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/Essentials/src/com/earth2me/essentials/User.java b/Essentials/src/com/earth2me/essentials/User.java
index 0853975ca..c3fe0ce5f 100644
--- a/Essentials/src/com/earth2me/essentials/User.java
+++ b/Essentials/src/com/earth2me/essentials/User.java
@@ -139,7 +139,7 @@ public class User extends PlayerExtension implements Comparable<User>
long now = Calendar.getInstance().getTimeInMillis();
long cooldown = Essentials.getSettings().getTeleportCooldown();
long left = lastTeleport + cooldown - now;
- if (left > 0 && !isOp() && !isAuthorized("essentials.teleport.cooldown.bypass"))
+ if ((left > 0 && !isOp() && !isAuthorized("essentials.teleport.cooldown.bypass")) | !isJailed())
throw new Exception("Time before next teleport: " + Essentials.FormatTime(left));
// if justCheck is set, don't update lastTeleport; we're just checking
if (!justCheck) lastTeleport = now;
@@ -385,6 +385,7 @@ public class User extends PlayerExtension implements Comparable<User>
public void teleportTo(final Location loc, final String chargeFor)
{
+
final long delay = Essentials.getSettings().getTeleportDelay();
if (delay <= 0 || isOp() || isAuthorized("essentials.teleport.timer.bypass"))
@@ -434,6 +435,7 @@ public class User extends PlayerExtension implements Comparable<User>
public void teleportTo(final Entity entity, final String chargeFor)
{
+
final long delay = Essentials.getSettings().getTeleportDelay();
if (delay <= 0 || isOp() || isAuthorized("essentials.teleport.timer.bypass"))