Merge remote-tracking branch 'origin/main'

This commit is contained in:
Daniella / Tove 2024-06-03 10:49:21 +02:00
commit b267004b5d
3 changed files with 45 additions and 0 deletions

View file

@ -41,6 +41,8 @@ public class Setup {
new ChatExtras(),
new ChatFilter(),
new ClickGUI(),
new Connect(),
new Disconnect(),
new ElytraFly(),
new ElytraBot(),
new FastBreak(),

View file

@ -0,0 +1,20 @@
package com.baseband.client.feature.command;
import com.baseband.client.feature.Feature;
import com.baseband.client.feature.category.Command;
import net.minecraft.client.multiplayer.GuiConnecting;
@Command
public class Connect extends Feature {
@Override
public String toString() {
return "Connect";
}
@Override
public void onCommand(String[] args) {
if(args.length == 1 && notIngame()) {
mc.displayGuiScreen(new GuiConnecting(mc.currentScreen, mc, args[0], 25565));
}
}
}

View file

@ -0,0 +1,23 @@
package com.baseband.client.feature.command;
import com.baseband.client.feature.Feature;
import com.baseband.client.feature.category.Command;
import net.minecraft.network.play.server.SPacketDisconnect;
import net.minecraft.util.text.TextComponentString;
@Command
public class Disconnect extends Feature {
@Override
public String toString() {
return "Disconnect";
}
@Override
public void onCommand(String[] args) {
if (mc.getConnection() != null) {
mc.getConnection().handleDisconnect(new SPacketDisconnect(new TextComponentString("[BaseBand] Disconnected.")));
}
}
}