mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 07:20:24 +01:00
Add api for spawn egg texture colors
This commit is contained in:
parent
0b0012faf2
commit
e5c2af7f5e
1 changed files with 12 additions and 0 deletions
|
@ -637,6 +637,18 @@ public final class CraftMagicNumbers implements UnsafeValues {
|
||||||
}
|
}
|
||||||
// Paper end
|
// Paper end
|
||||||
|
|
||||||
|
// Paper start - spawn egg color visibility
|
||||||
|
@Override
|
||||||
|
public org.bukkit.Color getSpawnEggLayerColor(final EntityType entityType, final int layer) {
|
||||||
|
final net.minecraft.world.entity.EntityType<?> nmsType = org.bukkit.craftbukkit.entity.CraftEntityType.bukkitToMinecraft(entityType);
|
||||||
|
final net.minecraft.world.item.SpawnEggItem eggItem = net.minecraft.world.item.SpawnEggItem.byId(nmsType);
|
||||||
|
if (eggItem != null) {
|
||||||
|
throw new UnsupportedOperationException("Not yet implemented");
|
||||||
|
}
|
||||||
|
return eggItem == null ? null : org.bukkit.Color.fromRGB(1); // TODO
|
||||||
|
}
|
||||||
|
// Paper end - spawn egg color visibility
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This helper class represents the different NBT Tags.
|
* This helper class represents the different NBT Tags.
|
||||||
* <p>
|
* <p>
|
||||||
|
|
Loading…
Reference in a new issue