Skip to content

Commit

Permalink
just give up and mixin to except spectator
Browse files Browse the repository at this point in the history
  • Loading branch information
andantet committed Dec 15, 2022
1 parent feccdf9 commit 5455791
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 23 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,13 @@ private static void onValidLivingEntity(Entity entity, CallbackInfoReturnable<Bo
}
}

@Inject(method = "method_24517", at = @At("TAIL"), cancellable = true)
private static void onExceptSpectator(Entity entity, CallbackInfoReturnable<Boolean> cir) {
if (cir.getReturnValueZ()) {
if (entity instanceof ClippingEntity clippingEntity && clippingEntity.isClipping()) cir.setReturnValue(false);
}
}

/**
* Removes collision entirely from clipping players.
*/
Expand Down
1 change: 0 additions & 1 deletion src/main/resources/noclip.mixins.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
"package": "me.andante.noclip.mixin",
"mixins": [
"AreaEffectCloudEntityMixin",
"EndGatewayBlockEntityMixin",
"EntityMixin",
"EntityPredicatesMixin",
"ExplosionMixin",
Expand Down

0 comments on commit 5455791

Please sign in to comment.