tutorial:blockentityrenderers
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
tutorial:blockentityrenderers [2022/06/07 09:08] – Correct type arguments of DemoBlockEntityRenderer daomephsta | tutorial:blockentityrenderers [2023/02/09 13:14] (current) – "you wants" -> "you want" mschae23 | ||
---|---|---|---|
Line 52: | Line 52: | ||
@Override | @Override | ||
public void onInitializeClient() { | public void onInitializeClient() { | ||
- | BlockEntityRendererRegistry.INSTANCE.register(DEMO_BLOCK_ENTITY, | + | BlockEntityRendererRegistry.register(DEMO_BLOCK_ENTITY, |
} | } | ||
</ | </ | ||
Line 77: | Line 77: | ||
// Rotate the item | // Rotate the item | ||
- | matrices.multiply(Vec3f.POSITIVE_Y.getDegreesQuaternion((blockEntity.getWorld().getTime() + tickDelta) * 4)); | + | matrices.multiply(RotationAxis.POSITIVE_Y.rotationDegrees((blockEntity.getWorld().getTime() + tickDelta) * 4)); |
} | } | ||
</ | </ | ||
Line 110: | Line 110: | ||
===== Rendering according to block entity data ===== | ===== Rendering according to block entity data ===== | ||
- | Sometimes you wants to render according to the block entity data (nbt), and you find they are all empty, even if you can access the data through ''/ | + | Sometimes you want to render according to the block entity data (nbt), and you find they are all empty, even if you can access the data through ''/ |
tutorial/blockentityrenderers.txt · Last modified: 2023/02/09 13:14 by mschae23