Skip to content

Commit

Permalink
fix the bug caused by setting interactable to false in old versions
Browse files Browse the repository at this point in the history
  • Loading branch information
qouteall committed Apr 16, 2023
1 parent 442ca22 commit 6be686c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions src/main/java/qouteall/mini_scaled/MiniScaledPortal.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ public MiniScaledPortal(EntityType<?> entityType, Level world) {
public void tick() {
super.tick();

// in old versions it set interactable to false.
// change it to true
setInteractable(true);

if (level.isClientSide()) {
tickClient();
}
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/qouteall/mini_scaled/ScaleBoxGeneration.java
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ private static void createScaleBoxPortals(
portal.hasCrossPortalCollision = true;
portal.portalTag = "mini_scaled:scaled_box";
PortalExtension.get(portal).adjustPositionAfterTeleport = true;
portal.setInteractable(false);
portal.setInteractable(true);
portal.boxId = boxId;
portal.generation = generation;
portal.recordEntry = entry;
Expand All @@ -143,7 +143,7 @@ private static void createScaleBoxPortals(
reversePortal.fuseView = false;
reversePortal.renderingMergable = true;
reversePortal.hasCrossPortalCollision = true;
reversePortal.setInteractable(false);
reversePortal.setInteractable(true);
reversePortal.boxId = boxId;
reversePortal.generation = generation;
reversePortal.recordEntry = entry;
Expand Down

0 comments on commit 6be686c

Please sign in to comment.