mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-23 16:56:31 +01:00
Fixed Ocelot.Type lookup - this fixes BUKKIT-952
By: Nathan Adams <dinnerbone@dinnerbone.com>
This commit is contained in:
parent
d3a1476775
commit
577152ebd1
1 changed files with 6 additions and 0 deletions
|
@ -31,6 +31,12 @@ public interface Ocelot extends Animals, Tameable {
|
|||
private static final Type[] types = new Type[Type.values().length];
|
||||
private final int id;
|
||||
|
||||
static {
|
||||
for (Type type : values()) {
|
||||
types[type.getId()] = type;
|
||||
}
|
||||
}
|
||||
|
||||
private Type(int id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue