Skip to content

Commit

Permalink
Allow untouchable entities to be unloaded
Browse files Browse the repository at this point in the history
  • Loading branch information
Gegy committed Nov 20, 2024
1 parent 748f850 commit 461681f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public void moveTo(double x, double y, double z, float yRot, float xRot, Callbac

@Inject(method = "setRemoved", at = @At("HEAD"), cancellable = true)
public final void setRemoved(Entity.RemovalReason removalReason, CallbackInfo ci) {
if(this.tags.contains(lTExtras$UNTOUCHABLE)) {
if(removalReason == Entity.RemovalReason.KILLED && this.tags.contains(lTExtras$UNTOUCHABLE)) {
ci.cancel();
}
}
Expand Down

0 comments on commit 461681f

Please sign in to comment.