mirror of
https://github.com/TotalFreedomMC/TF-LibsDisguises.git
synced 2025-02-12 03:57:03 +00:00
Add isBaby and setBaby to ageable watcher
This commit is contained in:
parent
40c41fe1d0
commit
f5c48eb264
1 changed files with 10 additions and 2 deletions
|
@ -9,12 +9,20 @@ public class AgeableWatcher extends LivingWatcher {
|
|||
}
|
||||
|
||||
public boolean isAdult() {
|
||||
return !isBaby();
|
||||
}
|
||||
|
||||
public boolean isBaby() {
|
||||
return (Integer) getValue(12, 0) >= 0;
|
||||
}
|
||||
|
||||
public void setAdult(boolean isAdult) {
|
||||
setValue(12, isAdult ? 0 : -24000);
|
||||
public void setBaby(boolean isBaby) {
|
||||
setValue(12, isBaby ? 0 : -24000);
|
||||
sendData(12);
|
||||
}
|
||||
|
||||
public void setAdult(boolean isAdult) {
|
||||
setBaby(!isAdult);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue