wall-hack module

wall-hack: Minecraft 26.3 cheat module, full source for every implementation (1 client: Meteor Client).

1 implementationRender

Clients with this module

Full module source: 1 implementation

Every implementation below is the complete module file, verbatim. Expand a client to read its code.

Meteor ClientRendersrc/main/java/meteordevelopment/meteorclient/systems/modules/render/WallHack.javaJava · 84 lines · 2.6 KB

Makes blocks translucent.

Settingsopacityblocksocclude-chunks
WallHack.javaJava · Minecraft 26.2 · 84 lines · 2.6 KB · complete file, verbatimOriginal ↗
1
/*
2
 * This file is part of the Meteor Client distribution (https://github.com/MeteorDevelopment/meteor-client).
3
 * Copyright (c) Meteor Development.
4
 */
5
6
package meteordevelopment.meteorclient.systems.modules.render;
7
8
import meteordevelopment.meteorclient.MixinPlugin;
9
import meteordevelopment.meteorclient.events.world.ChunkOcclusionEvent;
10
import meteordevelopment.meteorclient.gui.GuiTheme;
11
import meteordevelopment.meteorclient.gui.widgets.WWidget;
12
import meteordevelopment.meteorclient.settings.*;
13
import meteordevelopment.meteorclient.systems.modules.Categories;
14
import meteordevelopment.meteorclient.systems.modules.Module;
15
import meteordevelopment.orbit.EventHandler;
16
import net.irisshaders.iris.api.v0.IrisApi;
17
import net.minecraft.world.level.block.Block;
18
19
import java.util.List;
20
21
public class WallHack extends Module {
22
    private final SettingGroup sgGeneral = settings.getDefaultGroup();
23
24
    public final Setting<Integer> opacity = sgGeneral.add(new IntSetting.Builder()
25
        .name("opacity")
26
        .description("The opacity for rendered blocks.")
27
        .defaultValue(0)
28
        .range(0, 255)
29
        .sliderMax(255)
30
        .onChanged(_ -> {
31
            if (this.isActive()) {
32
                mc.levelExtractor.allChanged();
33
            }
34
        })
35
        .build()
36
    );
37
38
    public final Setting<List<Block>> blocks = sgGeneral.add(new BlockListSetting.Builder()
39
        .name("blocks")
40
        .description("What blocks should be targeted for Wall Hack.")
41
        .defaultValue()
42
        .onChanged(_ -> {
43
            if (isActive()) {
44
                mc.levelExtractor.allChanged();
45
            }
46
        })
47
        .build()
48
    );
49
50
    public final Setting<Boolean> occludeChunks = sgGeneral.add(new BoolSetting.Builder()
51
        .name("occlude-chunks")
52
        .description("Whether caves should occlude underground (may look wonky when on).")
53
        .defaultValue(false)
54
        .build()
55
    );
56
57
    public WallHack() {
58
        super(Categories.Render, "wall-hack", "Makes blocks translucent.");
59
    }
60
61
    @Override
62
    public void onActivate() {
63
        mc.levelExtractor.allChanged();
64
    }
65
66
    @Override
67
    public void onDeactivate() {
68
        mc.levelExtractor.allChanged();
69
    }
70
71
    @Override
72
    public WWidget getWidget(GuiTheme theme) {
73
        if (MixinPlugin.isIrisPresent && IrisApi.getInstance().isShaderPackInUse())
74
            return theme.label("Warning: Due to shaders in use, opacity is overridden to 0.");
75
76
        return null;
77
    }
78
79
    @EventHandler
80
    private void onChunkOcclusion(ChunkOcclusionEvent event) {
81
        if (!occludeChunks.get()) event.cancel();
82
    }
83
}
84