88import net .minecraft .network .chat .Component ;
99import net .minecraft .world .InteractionHand ;
1010import net .minecraft .world .InteractionResult ;
11- import net .minecraft .world .entity .EntityType ;
11+ import net .minecraft .world .entity .EntityTypes ;
1212import net .minecraft .world .entity .player .Player ;
1313import net .minecraft .world .entity .vehicle .minecart .MinecartChest ;
1414import net .minecraft .world .item .ItemStack ;
2020import net .minecraft .world .level .block .entity .ChestBlockEntity ;
2121import net .minecraft .world .level .block .state .BlockState ;
2222import net .minecraft .world .phys .BlockHitResult ;
23+ import net .minecraft .world .phys .Vec3 ;
2324import org .cyclops .capabilityproxy .Reference ;
2425import org .cyclops .capabilityproxy .RegistryEntries ;
2526import org .cyclops .capabilityproxy .block .BlockCapabilityProxy ;
@@ -194,7 +195,7 @@ public void testBlockProxyForwardGuiHopper(GameTestHelper helper) {
194195 helper .succeedIf (() -> {
195196 // Open screen of target
196197 BlockState blockState = helper .getBlockState (POS .offset (2 , 2 , 3 ));
197- InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (POS .offset (2 , 2 , 3 ). getBottomCenter ( ), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 3 )), false ));
198+ InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (Vec3 . atBottomCenterOf ( POS .offset (2 , 2 , 3 )), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 3 )), false ));
198199 helper .assertTrue (result .equals (InteractionResult .SUCCESS ), Component .literal ("Interaction failed" ));
199200 });
200201 }
@@ -234,7 +235,7 @@ public void testBlockProxyForwardChainGuiHopper(GameTestHelper helper) {
234235 helper .succeedWhen (() -> {
235236 // Open screen of target
236237 BlockState blockState = helper .getBlockState (POS .offset (3 , 5 , 5 ));
237- InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (POS .offset (3 , 5 , 5 ). getBottomCenter ( ), Direction .NORTH , helper .absolutePos (POS .offset (3 , 5 , 5 )), false ));
238+ InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (Vec3 . atBottomCenterOf ( POS .offset (3 , 5 , 5 )), Direction .NORTH , helper .absolutePos (POS .offset (3 , 5 , 5 )), false ));
238239 helper .assertTrue (result .equals (InteractionResult .SUCCESS ), Component .literal ("Interaction failed" ));
239240 });
240241 }
@@ -260,7 +261,7 @@ public void testBlockProxyCycleGui(GameTestHelper helper) {
260261 helper .succeedWhen (() -> {
261262 // Open screen of target
262263 BlockState blockState = helper .getBlockState (POS .offset (2 , 2 , 2 ));
263- InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (POS .offset (2 , 2 , 2 ). getBottomCenter ( ), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 2 )), false ));
264+ InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (Vec3 . atBottomCenterOf ( POS .offset (2 , 2 , 2 )), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 2 )), false ));
264265 helper .assertTrue (result .equals (InteractionResult .FAIL ), Component .literal ("Interaction did not fail" ));
265266 });
266267 }
@@ -391,7 +392,7 @@ public void testBlockProxyRangedForwardGuiHopper(GameTestHelper helper) {
391392 helper .succeedIf (() -> {
392393 // Open screen of target
393394 BlockState blockState = helper .getBlockState (POS .offset (2 , 2 , 4 ));
394- InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (POS .offset (2 , 2 , 4 ). getBottomCenter ( ), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 4 )), false ));
395+ InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (Vec3 . atBottomCenterOf ( POS .offset (2 , 2 , 4 )), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 4 )), false ));
395396 helper .assertTrue (result .equals (InteractionResult .SUCCESS ), Component .literal ("Interaction failed" ));
396397 });
397398 }
@@ -431,7 +432,7 @@ public void testBlockProxyRangedForwardChainGuiHopper(GameTestHelper helper) {
431432 helper .succeedWhen (() -> {
432433 // Open screen of target
433434 BlockState blockState = helper .getBlockState (POS .offset (3 , 5 , 6 ));
434- InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (POS .offset (3 , 5 , 6 ). getBottomCenter ( ), Direction .NORTH , helper .absolutePos (POS .offset (3 , 5 , 6 )), false ));
435+ InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (Vec3 . atBottomCenterOf ( POS .offset (3 , 5 , 6 )), Direction .NORTH , helper .absolutePos (POS .offset (3 , 5 , 6 )), false ));
435436 helper .assertTrue (result .equals (InteractionResult .SUCCESS ), Component .literal ("Interaction failed" ));
436437 });
437438 }
@@ -457,7 +458,7 @@ public void testBlockProxyRangedCycleGui(GameTestHelper helper) {
457458 helper .succeedWhen (() -> {
458459 // Open screen of target
459460 BlockState blockState = helper .getBlockState (POS .offset (2 , 2 , 2 ));
460- InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (POS .offset (2 , 2 , 2 ). getBottomCenter ( ), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 2 )), false ));
461+ InteractionResult result = blockState .useWithoutItem (helper .getLevel (), player , new BlockHitResult (Vec3 . atBottomCenterOf ( POS .offset (2 , 2 , 2 )), Direction .NORTH , helper .absolutePos (POS .offset (2 , 2 , 2 )), false ));
461462 helper .assertTrue (result .equals (InteractionResult .PASS ) || result .equals (InteractionResult .FAIL ), Component .literal ("Interaction did not pass" ));
462463 });
463464 }
@@ -633,7 +634,7 @@ public void testBlockProxyEntityFillChestMinecartFromHopper(GameTestHelper helpe
633634
634635 // Place chest minecart at target
635636 helper .setBlock (POS .offset (2 , 0 , 2 ), Blocks .RAIL .defaultBlockState ());
636- MinecartChest minecart = helper .spawn (EntityType .CHEST_MINECART , POS .offset (2 , 0 , 2 ));
637+ MinecartChest minecart = helper .spawn (EntityTypes .CHEST_MINECART , POS .offset (2 , 0 , 2 ));
637638
638639 // Make hopper target proxy
639640 helper .setBlock (POS .offset (2 , 0 , 4 ), Blocks .HOPPER
0 commit comments