@@ -24,27 +24,28 @@ public void init(CallbackInfo ci) {
2424 if (SharedVariables .enabled ) {
2525 ScreenAccessor accessor = (ScreenAccessor ) this ;
2626
27- // Center X position
28- int centerX = this . width / 2 ;
27+ // Position in bottom-left corner
28+ int leftX = 5 ;
2929 int buttonWidth = 160 ;
30+ int bottomY = this .height - 30 ; // First button from bottom
3031
31- // Bypass Resource Pack Toggle - positioned above the server list area
32- accessor .invokeAddRenderableWidget (Button .builder (
33- Component .literal ("Bypass Resource Pack: " + (SharedVariables .bypassResourcePack ? "ON" : "OFF" )),
34- (button ) -> {
35- SharedVariables .bypassResourcePack = !SharedVariables .bypassResourcePack ;
36- button .setMessage (Component .literal (
37- "Bypass Resource Pack: " + (SharedVariables .bypassResourcePack ? "ON" : "OFF" )));
38- }).bounds (centerX - buttonWidth / 2 , 50 , buttonWidth , 20 ).build ());
39-
40- // Force Deny Toggle
32+ // Force Deny Toggle - bottom button
4133 accessor .invokeAddRenderableWidget (Button .builder (
4234 Component .literal ("Force Deny: " + (SharedVariables .resourcePackForceDeny ? "ON" : "OFF" )),
4335 (button ) -> {
4436 SharedVariables .resourcePackForceDeny = !SharedVariables .resourcePackForceDeny ;
4537 button .setMessage (Component
4638 .literal ("Force Deny: " + (SharedVariables .resourcePackForceDeny ? "ON" : "OFF" )));
47- }).bounds (centerX - buttonWidth / 2 , 75 , buttonWidth , 20 ).build ());
39+ }).bounds (leftX , bottomY , buttonWidth , 20 ).build ());
40+
41+ // Bypass Resource Pack Toggle - above Force Deny
42+ accessor .invokeAddRenderableWidget (Button .builder (
43+ Component .literal ("Bypass Resource Pack: " + (SharedVariables .bypassResourcePack ? "ON" : "OFF" )),
44+ (button ) -> {
45+ SharedVariables .bypassResourcePack = !SharedVariables .bypassResourcePack ;
46+ button .setMessage (Component .literal (
47+ "Bypass Resource Pack: " + (SharedVariables .bypassResourcePack ? "ON" : "OFF" )));
48+ }).bounds (leftX , bottomY - 22 , buttonWidth , 20 ).build ());
4849 }
4950 }
5051}
0 commit comments