Skip to content

Commit

Permalink
Formatting code
Browse files Browse the repository at this point in the history
  • Loading branch information
Hendrix-Shen committed May 4, 2021
1 parent bd67de6 commit 322dafd
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@

@Mixin(ClientPlayerEntity.class)
public class MixinClientPlayerEntity {
@Shadow private boolean usingItem;
@Shadow
private boolean usingItem;

@Redirect(
method = "tickMovement",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,12 @@ public class MixinCobwebBlock {
method = "onEntityCollision",
at = @At(
value = "INVOKE",
target = "Lnet/minecraft/entity/Entity;slowMovement(Lnet/minecraft/block/BlockState;Lnet/minecraft/util/math/Vec3d;)V"
target = "Lnet/minecraft/entity/Entity;slowMovement(Lnet/minecraft/block/BlockState;Lnet/minecraft/util/math/Vec3d;)V"
),
cancellable = true
)
private void onWalkInCobWebBlock(BlockState state, World world, BlockPos pos, Entity entity, CallbackInfo ci)
{
if ((Configs.Disable.DISABLE_SLOWDOWN.getBooleanValue()) && entity instanceof PlayerEntity)
{
private void onWalkInCobWebBlock(BlockState state, World world, BlockPos pos, Entity entity, CallbackInfo ci) {
if ((Configs.Disable.DISABLE_SLOWDOWN.getBooleanValue()) && entity instanceof PlayerEntity) {
ci.cancel();
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package top.hendrixshen.TweakMyClient.mixin;

import net.minecraft.client.MinecraftClient;
import net.minecraft.client.gui.screen.DeathScreen;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
Expand All @@ -17,8 +16,8 @@ public class MixinDeathScreen {
value = "TAIL"
)
)
private void onTick(CallbackInfo ci){
if(Configs.Feature.FEATURE_AUTO_RESPAWN.getBooleanValue()) {
private void onTick(CallbackInfo ci) {
if (Configs.Feature.FEATURE_AUTO_RESPAWN.getBooleanValue()) {
assert TweakMyClient.minecraftClient.player != null;
TweakMyClient.minecraftClient.player.requestRespawn();
TweakMyClient.minecraftClient.openScreen(null);
Expand Down

0 comments on commit 322dafd

Please sign in to comment.