summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKHobbits <rob@khobbits.co.uk>2012-06-13 02:51:47 +0100
committerKHobbits <rob@khobbits.co.uk>2012-06-13 02:51:47 +0100
commit0436962ee74f8769bbd42910cc0f4b07a03e6b91 (patch)
treeb8f5868d3d14218caa3a653cdc82d34c92beeaea
parent2bebb0bd61df65a30de210d57d4e46e1334a65d0 (diff)
downloadEssentials-0436962ee74f8769bbd42910cc0f4b07a03e6b91.tar
Essentials-0436962ee74f8769bbd42910cc0f4b07a03e6b91.tar.gz
Essentials-0436962ee74f8769bbd42910cc0f4b07a03e6b91.tar.lz
Essentials-0436962ee74f8769bbd42910cc0f4b07a03e6b91.tar.xz
Essentials-0436962ee74f8769bbd42910cc0f4b07a03e6b91.zip
Invert teleport timer.
-rw-r--r--Essentials/src/com/earth2me/essentials/Teleport.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/Essentials/src/com/earth2me/essentials/Teleport.java b/Essentials/src/com/earth2me/essentials/Teleport.java
index a920544cb..198ffab15 100644
--- a/Essentials/src/com/earth2me/essentials/Teleport.java
+++ b/Essentials/src/com/earth2me/essentials/Teleport.java
@@ -169,8 +169,8 @@ public class Teleport implements Runnable, ITeleport
else if (lastTime > earliestLong && !user.isAuthorized("essentials.teleport.cooldown.bypass"))
{
time.setTimeInMillis(lastTime);
- time.add(Calendar.SECOND, (int)delay);
- time.add(Calendar.MILLISECOND, (int)((delay * 1000.0) % 1000.0));
+ time.add(Calendar.SECOND, (-1) * (int)delay);
+ time.add(Calendar.MILLISECOND, (-1) * (int)((delay * 1000.0) % 1000.0));
throw new Exception(_("timeBeforeTeleport", Util.formatDateDiff(time.getTimeInMillis())));
}
}