Skip to content

Commit 49d8c25

Browse files
committed
Merge branch 'master' into feature/taskflow
2 parents 670324f + 6de748f commit 49d8c25

File tree

362 files changed

+6721
-624
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

362 files changed

+6721
-624
lines changed

common/src/main/java/com/lambda/mixin/MinecraftClientMixin.java

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@
22

33
import com.lambda.Lambda;
44
import com.lambda.event.EventFlow;
5-
import com.lambda.event.events.*;
5+
import com.lambda.event.events.ClientEvent;
6+
import com.lambda.event.events.ScreenEvent;
7+
import com.lambda.event.events.ScreenHandlerEvent;
8+
import com.lambda.event.events.TickEvent;
69
import com.lambda.module.modules.player.Interact;
710
import net.minecraft.client.MinecraftClient;
811
import net.minecraft.client.gui.screen.Screen;
@@ -18,7 +21,9 @@
1821

1922
@Mixin(MinecraftClient.class)
2023
public class MinecraftClientMixin {
21-
@Shadow @Nullable public Screen currentScreen;
24+
@Shadow
25+
@Nullable
26+
public Screen currentScreen;
2227

2328
@Inject(method = "tick", at = @At("HEAD"))
2429
void onTickPre(CallbackInfo ci) {

common/src/main/java/com/lambda/mixin/entity/ClientPlayInteractionManagerMixin.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,12 @@
2525
@Mixin(ClientPlayerInteractionManager.class)
2626
public class ClientPlayInteractionManagerMixin {
2727

28+
@Shadow
29+
public float currentBreakingProgress;
2830
@Final
2931
@Shadow
3032
private MinecraftClient client;
3133

32-
@Shadow
33-
public float currentBreakingProgress;
34-
3534
@Inject(method = "interactBlock", at = @At("HEAD"))
3635
public void interactBlockHead(final ClientPlayerEntity player, final Hand hand, final BlockHitResult hitResult, final CallbackInfoReturnable<ActionResult> cir) {
3736
if (client.world == null) return;

common/src/main/java/com/lambda/mixin/entity/FireworkRocketEntityMixin.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,8 @@ public class FireworkRocketEntityMixin {
1818
)
1919
)
2020
private void redirectSetVelocity(LivingEntity shooter, Vec3d vec3d) {
21-
if (ElytraFly.getDoBoost()){
21+
if (ElytraFly.getDoBoost()) {
2222
ElytraFly.boostRocket(shooter);
23-
}
24-
else shooter.setVelocity(vec3d);
23+
} else shooter.setVelocity(vec3d);
2524
}
26-
}
25+
}

common/src/main/java/com/lambda/mixin/entity/LivingEntityMixin.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
import com.lambda.event.EventFlow;
55
import com.lambda.event.events.MovementEvent;
66
import com.lambda.interaction.RotationManager;
7-
import net.minecraft.entity.Entity;
87
import net.minecraft.entity.LivingEntity;
98
import net.minecraft.util.math.MathHelper;
109
import net.minecraft.util.math.Vec3d;

common/src/main/java/com/lambda/mixin/network/ClientLoginNetworkMixin.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,12 @@
22

33
import com.lambda.event.EventFlow;
44
import com.lambda.event.events.ConnectionEvent;
5-
import com.lambda.module.modules.client.DiscordRPC;
65
import net.minecraft.client.network.ClientLoginNetworkHandler;
76
import net.minecraft.network.packet.s2c.login.LoginSuccessS2CPacket;
8-
import net.minecraft.text.Text;
97
import org.spongepowered.asm.mixin.Mixin;
108
import org.spongepowered.asm.mixin.injection.At;
119
import org.spongepowered.asm.mixin.injection.Inject;
1210
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
13-
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;
1411

1512
@Mixin(ClientLoginNetworkHandler.class)
1613
public class ClientLoginNetworkMixin {

common/src/main/java/com/lambda/mixin/render/RenderSystemMixin.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,13 @@
1111

1212
@Mixin(RenderSystem.class)
1313
public class RenderSystemMixin {
14-
@Shadow @Final private static float[] shaderFogColor;
14+
@Shadow
15+
@Final
16+
private static float[] shaderFogColor;
1517

16-
@Inject(method = "_setShaderFogColor", at = @At(value ="HEAD"), cancellable = true)
17-
private static void onSetShaderFogColor(float red, float green, float blue, float alpha, CallbackInfo ci){
18-
if (WorldColors.INSTANCE.isEnabled() && WorldColors.getCustomFog()){
18+
@Inject(method = "_setShaderFogColor", at = @At(value = "HEAD"), cancellable = true)
19+
private static void onSetShaderFogColor(float red, float green, float blue, float alpha, CallbackInfo ci) {
20+
if (WorldColors.INSTANCE.isEnabled() && WorldColors.getCustomFog()) {
1921
ci.cancel();
2022
shaderFogColor[0] = WorldColors.getFogColor().getRed() / 255f;
2123
shaderFogColor[1] = WorldColors.getFogColor().getGreen() / 255f;

common/src/main/java/com/lambda/mixin/render/SplashOverlayMixin.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,18 @@
77
import org.spongepowered.asm.mixin.Mixin;
88
import org.spongepowered.asm.mixin.Mutable;
99
import org.spongepowered.asm.mixin.Shadow;
10-
import org.spongepowered.asm.mixin.injection.*;
10+
import org.spongepowered.asm.mixin.injection.At;
11+
import org.spongepowered.asm.mixin.injection.Inject;
12+
import org.spongepowered.asm.mixin.injection.Redirect;
1113
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
1214

1315
import java.util.function.IntSupplier;
1416

1517
@Mixin(SplashOverlay.class)
1618
public class SplashOverlayMixin {
1719
@Mutable
18-
@Shadow @Final
20+
@Shadow
21+
@Final
1922
static Identifier LOGO;
2023

2124
@Redirect(method = "render", at = @At(value = "INVOKE", target = "Ljava/util/function/IntSupplier;getAsInt()I"))

common/src/main/java/com/lambda/mixin/world/BlockCollisionSpliteratorMixin.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
import org.spongepowered.asm.mixin.injection.Redirect;
1515

1616
@Mixin(BlockCollisionSpliterator.class)
17-
public abstract class BlockCollisionSpliteratorMixin <T extends AbstractIterator<T>> {
17+
public abstract class BlockCollisionSpliteratorMixin<T extends AbstractIterator<T>> {
1818
@Redirect(method = "computeNext", at = @At(value = "INVOKE", target = "Lnet/minecraft/block/BlockState;getCollisionShape(Lnet/minecraft/world/BlockView;Lnet/minecraft/util/math/BlockPos;Lnet/minecraft/block/ShapeContext;)Lnet/minecraft/util/shape/VoxelShape;"))
1919
private VoxelShape collisionShapeRedirect(BlockState instance, BlockView blockView, BlockPos blockPos, ShapeContext shapeContext) {
2020
VoxelShape collisionShape = instance.getCollisionShape(blockView, blockPos, shapeContext);

common/src/main/kotlin/com/lambda/Lambda.kt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
/*
2+
* Copyright 2024 Lambda
3+
*
4+
* This program is free software: you can redistribute it and/or modify
5+
* it under the terms of the GNU General Public License as published by
6+
* the Free Software Foundation, either version 3 of the License, or
7+
* (at your option) any later version.
8+
*
9+
* This program is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License
15+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
16+
*/
17+
118
package com.lambda
219

320
import com.google.gson.Gson

common/src/main/kotlin/com/lambda/LoaderInfo.kt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
/*
2+
* Copyright 2024 Lambda
3+
*
4+
* This program is free software: you can redistribute it and/or modify
5+
* it under the terms of the GNU General Public License as published by
6+
* the Free Software Foundation, either version 3 of the License, or
7+
* (at your option) any later version.
8+
*
9+
* This program is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License
15+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
16+
*/
17+
118
package com.lambda
219

320
import dev.architectury.injectables.annotations.ExpectPlatform

0 commit comments

Comments
 (0)