Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
import com.mojang.brigadier.suggestion.Suggestions;
import meteordevelopment.meteorclient.systems.commands.Commands;
import meteordevelopment.meteorclient.systems.config.Config;
import meteordevelopment.meteorclient.systems.modules.Modules;
import meteordevelopment.meteorclient.systems.modules.render.NoRender;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.gui.screen.CommandSuggestor;
import net.minecraft.client.gui.widget.TextFieldWidget;
Expand All @@ -22,6 +24,7 @@
import org.spongepowered.asm.mixin.injection.Inject;
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
import org.spongepowered.asm.mixin.injection.callback.LocalCapture;
import net.minecraft.client.util.math.MatrixStack;

import java.util.concurrent.CompletableFuture;

Expand Down Expand Up @@ -71,4 +74,9 @@ public void onRefresh(CallbackInfo ci, String string, StringReader reader) {
}
}

@Inject(method = "render", at = @At(value = "HEAD"), cancellable = true)
public void render(MatrixStack matrices, int mouseX, int mouseY, CallbackInfo info) {
if (Modules.get().get(NoRender.class).noCommandSuggestions()) info.cancel();
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,13 @@ public class NoRender extends Module {
.build()
);

private final Setting<Boolean> noCommandSuggestions = sgOverlay.add(new BoolSetting.Builder()
.name("command-suggestions")
.description("Disables command suggestions in chat.")
.defaultValue(false)
.build()
);

// HUD

private final Setting<Boolean> noBossBar = sgHUD.add(new BoolSetting.Builder()
Expand Down Expand Up @@ -336,6 +343,10 @@ public boolean noEatParticles() {
return isActive() && noEatParticles.get();
}

public boolean noCommandSuggestions() {
return isActive() && noCommandSuggestions.get();
}

// HUD

public boolean noBossBar() {
Expand Down