2424import net .minecraft .ChatFormatting ;
2525import net .minecraft .util .Util ;
2626import net .minecraft .client .player .AbstractClientPlayer ;
27- import net .wurstclient .util .WurstBufferSource ;
2827import net .minecraft .client .gui .components .toasts .SystemToast ;
2928import net .minecraft .util .StringUtil ;
3029import net .minecraft .core .registries .BuiltInRegistries ;
@@ -1212,7 +1211,6 @@ private void drawWorldLabel(PoseStack matrices, String text, double x,
12121211 matrices .scale (s , -s , s );
12131212 matrices .translate (0 , offsetPx , 0 );
12141213
1215- WurstBufferSource vcp = RenderUtils .getVCP ();
12161214 float w = MC .font .width (text ) / 2F ;
12171215 int baseAlpha = (argb >>> 24 ) & 0xFF ;
12181216 int bgAlpha =
@@ -1221,23 +1219,10 @@ private void drawWorldLabel(PoseStack matrices, String text, double x,
12211219 var matrix = matrices .last ().pose ();
12221220 int strokeColor =
12231221 (Math .max (0 , Math .min (255 , baseAlpha )) << 24 ) | 0x000000 ;
1224- net .wurstclient .util .RenderUtils .drawTextInBatch (MC .font , text , -w - 1 ,
1225- 0 , strokeColor , false , matrix , vcp ,
1226- net .minecraft .client .gui .Font .DisplayMode .SEE_THROUGH , 0 , 0xF000F0 );
1227- net .wurstclient .util .RenderUtils .drawTextInBatch (MC .font , text , -w + 1 ,
1228- 0 , strokeColor , false , matrix , vcp ,
1229- net .minecraft .client .gui .Font .DisplayMode .SEE_THROUGH , 0 , 0xF000F0 );
1230- net .wurstclient .util .RenderUtils .drawTextInBatch (MC .font , text , -w , -1 ,
1231- strokeColor , false , matrix , vcp ,
1232- net .minecraft .client .gui .Font .DisplayMode .SEE_THROUGH , 0 , 0xF000F0 );
1233- net .wurstclient .util .RenderUtils .drawTextInBatch (MC .font , text , -w , 1 ,
1234- strokeColor , false , matrix , vcp ,
1235- net .minecraft .client .gui .Font .DisplayMode .SEE_THROUGH , 0 , 0xF000F0 );
1236- net .wurstclient .util .RenderUtils .drawTextInBatch (MC .font , text , -w , 0 ,
1237- argb , false , matrix , vcp ,
1222+ net .wurstclient .util .RenderUtils .drawOutlinedTextInBatch (MC .font , text ,
1223+ -w , 0 , argb , strokeColor , matrix ,
12381224 net .minecraft .client .gui .Font .DisplayMode .SEE_THROUGH , bg ,
12391225 0xF000F0 );
1240- vcp .endBatch ();
12411226 matrices .popPose ();
12421227 }
12431228
0 commit comments