Properly validate player experience bar progress

Dieser Commit ist enthalten in:
Parker Hawke 2017-03-19 18:31:40 -04:00
Ursprung dfee3d9f9f
Commit b80055abfb

Datei anzeigen

@ -821,6 +821,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@Override
public void setExp(float exp) {
Preconditions.checkArgument(exp >= 0.0 && exp <= 1.0, "Experience progress must be between 0.0 and 1.0 (%s)", exp);
getHandle().exp = exp;
getHandle().lastSentExp = -1;
}