the argument vertexConsumer is started on the drawBlockOutline of the RenderLayer.getLines().
and then if some one(yep is me) use getBuffer and RenderLayer.getTripwire() in WorldRenderEvents.BLOCK_OUTLINE event, the vertexConsumer will immediately end.
although fabric calls getBuffer with RenderLayer.getLines() again, but it not the same object (1.21 changed).
so the vertexConsumer still is end state, the game will throw java.lang.IllegalStateException: Not building! and crash.
https://github.com/FabricMC/fabric/blob/716be681fb0a5277cd600d92dc63bf26aa79cc6a/fabric-rendering-v1/src/client/java/net/fabricmc/fabric/mixin/client/rendering/WorldRendererMixin.java#L129
the argument
vertexConsumer
is started on thedrawBlockOutline
of theRenderLayer.getLines()
.and then if some one(yep is me) use
getBuffer
andRenderLayer.getTripwire()
inWorldRenderEvents.BLOCK_OUTLINE
event, thevertexConsumer
will immediately end.although fabric calls
getBuffer
withRenderLayer.getLines()
again, but it not the same object (1.21 changed).so the vertexConsumer still is end state, the game will throw
java.lang.IllegalStateException: Not building!
and crash.logs demo.zip