Add jail timer and jail event, count down the prisoners time.

This commit is contained in:
graywolf336
2014-01-03 14:10:38 -06:00
parent 738f8bc057
commit f5bf76ec46
9 changed files with 164 additions and 5 deletions

View File

@ -11,12 +11,12 @@ import org.bukkit.Location;
*
* @author graywolf336
* @since 2.x.x
* @version 2.0.1
* @version 3.0.0
*/
public class Prisoner {
private String name, reason, inventory, armor;
private boolean muted, offlinePending, teleporting;
private long time;
private long time, afk;
private Location previousPosition;
private GameMode previousGameMode;
@ -38,6 +38,7 @@ public class Prisoner {
this.previousGameMode = GameMode.SURVIVAL;
this.inventory = "";
this.armor = "";
this.afk = 0;
}
/** Gets the name of this player. */
@ -175,4 +176,14 @@ public class Prisoner {
public void setArmor(String armor) {
this.armor = armor;
}
/** Gets the time, in milliseconds, this prisoner has been afk. */
public long getAFKTime() {
return this.afk;
}
/** Sets the time, in milliseconds, this prisoner has been afk. */
public void setAFKTime(long time) {
this.afk = time;
}
}