Coder Social home page Coder Social logo

fishingbot's People

Contributors

amoraschi avatar artoria2e5 avatar bluscream avatar dankrank avatar dependabot[bot] avatar hoshino0881118 avatar kokoropie avatar mrkinau avatar mrmelon54 avatar nutjob4life avatar nycodeghg avatar p3tch avatar pisich avatar planetguy32 avatar summerfeeling avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fishingbot's Issues

Please add atributes to jar file

Can you please add the transfer of attributes to the jar file it will be very useful.

For example, pass the file path with config or pass attributes without a file.

error connecting to server

I believe the issue is the server has a queue system that makes you wait about 5 - 10 seconds to be connected, i read in a another error that it might be fixable by disabling fishingrod check how could i do that?

[2019-11-11 10:04:58] [INFO ] fantasy.vanitymc.co
[2019-11-11 10:04:58] [INFO ] Module "FishingModule" enabled!
[2019-11-11 10:04:58] [INFO ] Module "HandshakeModule" enabled!
[2019-11-11 10:04:58] [INFO ] Module "LoginModule" enabled!
[2019-11-11 10:04:58] [INFO ] Module "ChatCommandModule" enabled!
[2019-11-11 10:04:58] [INFO ] Module "ClientDefaultsModule" enabled!
[2019-11-11 10:04:59] [SEVERE ] Error while trying to send: PacketOutPosition
[2019-11-11 10:05:00] [SEVERE ] Error while trying to send: PacketOutPosition
512
[2019-11-11 10:05:00] [INFO ] Login successful!
[2019-11-11 10:05:00] [INFO ] Name: FgtEric
[2019-11-11 10:05:00] [INFO ] UUID: d63e675a-d0d1-40fb-bd8e-fcb373f93b88
[2019-11-11 10:05:00] [SEVERE ] No fishing rod equipped. Retrying later!
[2019-11-11 10:05:00] [SEVERE ] No fishing rod equipped. Retrying later!
[2019-11-11 10:05:00] [SEVERE ] No fishing rod equipped. Retrying later!
[2019-11-11 10:05:01] [SEVERE ] Error while trying to send: PacketOutPosition
Exception in thread "Thread-13" com.github.kevinsawicki.http.HttpRequest$HttpRequestException: java.net.MalformedURLException: no protocol: true
at com.github.kevinsawicki.http.HttpRequest.(HttpRequest.java:1475)
at com.github.kevinsawicki.http.HttpRequest.post(HttpRequest.java:1044)
at com.mrpowergamerbr.temmiewebhook.TemmieWebhook$1.run(TemmieWebhook.java:24)
at java.lang.Thread.run(Unknown Source)
Caused by: java.net.MalformedURLException: no protocol: true
at java.net.URL.(Unknown Source)
at java.net.URL.(Unknown Source)
at java.net.URL.(Unknown Source)
at com.github.kevinsawicki.http.HttpRequest.(HttpRequest.java:1473)
... 3 more
[2019-11-11 10:05:01] [INFO ] Starting fishing!
java.lang.RuntimeException: VarInt too big
at systems.kinau.fishingbot.network.protocol.Packet.readVarInt(Packet.java:203)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:366)
at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:218)
at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:144)
at systems.kinau.fishingbot.Main.main(Main.java:12)
[2019-11-11 10:05:02] [WARNING] Could not receive packet! Shutting down!
[2019-11-11 10:05:02] [INFO ] FishingBot restarts in 10 seconds...
[2019-11-11 10:05:02] [SEVERE ] Error while trying to send: PacketOutArmAnimation
[2019-11-11 10:05:02] [SEVERE ] Error while trying to send: PacketOutPosition
Exception in thread "Thread-10" java.lang.NullPointerException
at systems.kinau.fishingbot.FishingBot.lambda$connect$0(FishingBot.java:210)
at java.lang.Thread.run(Unknown Source)
Exception in thread "Thread-3" java.lang.NullPointerException
at systems.kinau.fishingbot.FishingBot.lambda$connect$0(FishingBot.java:210)
at java.lang.Thread.run(Unknown Source)

Please implement AutoEject

It would be nice if this bot could throw away junk items from user-defined list (for example bowls, leather boots etc...) and keep only needed items (enchanted books, bows, etc)

Add an option every 2-3 minutes it goes side from side

If possible could you add a feature where if will move left or right every 2-3 minutes, the servers i play on all have some sort of anti afk fishing plugins and so they prevent fishing from the same spot every like 3 minutes or so

Command-line flag to specify config file?

Is there any way to pass a specific config file to the bot? I've built a large fishing complex with thousand of chests and it's been lagging my computer like mad to run many instances of Minecraft. Thus, I need to be able to spawn the bot with a number of different configs.

I can't seem to find usage details about how to specify which config file to load, though.

Bot is synchronized data or something

when i use 2 or 3 bot sometime they are sync data or something just 1 fishing and the others does not and they chat all the samething when the one fishing caught something.
Sorry for my bad english. Btw where can i see the tutorial about making minecraft bot like this

Caught items not registerign properly

Just got a message in chat saying "FishingBot 2.4 - Caught "dirt"

I was just digging out some dirt in the area - guess it thought the entity from me digging was it's drop? Not sure if there is a workaround, but wanted to bring it into your attention :)

Cant import source code in IntelliJ IDEA correctly

I can't import the source code in IntelliJ IDEA and almost every class is full of errors such as:

Cannot resolve method 'getInstance' in FishingBot
Cannot resolve method 'getConfig' in FishingBot

and so on, but compiling and running works fine. Also it show this warning while compiling etc:

Some problems were encountered while building the effective model for systems.kinau:FishingBot:jar:1.0-SNAPSHOT
'dependencies.dependency.version' for com.flowpowered:flow-nbt:jar is either LATEST or RELEASE (both of them are being deprecated) @ line 64, column 22
It is highly recommended to fix these problems because they threaten the stability of your build.
For this reason, future Maven versions might no longer support building such malformed projects.

I really do not know what I did wrong, this is the first time I used Maven. It would be really nice if someone could help me. (Also sorry for my bad english, I am from Germany)

Can't make bot work

I filled in the Config.properties.
I changed the account-username and account-password to the informations of my minecraft account, changed the default protocol to 1.15 and the server ip to the ip of my server (its a minehut server).
I ran the fishinbot.jar trought the cmd, but the bot didn't seem to work.
Here is the log: log0.log

I probably just don't know how to properly set the bot up, but I tried changing everything i could in the Config.properties and i couldn't figure it out, so I'm seeking help

Auto-reconnect not working properly

On the server I'm on we have an agreement to kick the bot when other players want to sleep (ingame). This is supposed to work on the premise that the bot automatically reconnects 20 or so seconds after being kicked, but that isn't the case, as it just spews out a bunch of
[SEVERE ] Error while trying to send: PacketOutPosition
with the occasional
java.net.SocketException: Connection reset
instead of properly connecting (although that second one doesn't seem to be related to the actual problem. I did some testing, and it seems to actually manage to connect to the server, but the error messages just keep on coming instead of it actually starting to fish. It might be noteworthy that I'm running the bot on a Raspberry Pi 3.

add auto-command

When I disconnect, I have to login again
I want to add auto-command. . .
ex. auto-reconnect-command

Fishing bot [feature request]

Hi, I was just wandering around looking for bots, and I was wondering if you would be able to add a function to fish for pixelmon. I know it's a forge mod, but I was just wondering if that would work. It goes off the system whereby it uses exclamation to indicate the catch and the amount of exclamation marks (1-3) indicates the level of catch. It drops important items, and the encountering of pokemon can be avoided with a fainted pokemon in the team. So I was just wondering if it would be possible? # #

Bot not working properly on slow server

I've been getting [WARNING] Bot is slow (maybe stuck). Trying to restart! in the console for a while now, and I've been trying to figure out why it keeps happening. What I think is going on is that the server detects that a long while has passed without a fish being caught (because of the slow ping), and then recasts the fishing rod. The issue is that this basically kills the productivity of the bot once more than two people are on at the same time (yes, it's pretty bad). So, in case that feature works the way I think it does, is there a way to turn it off? If it works differently from how I think it works, how does it work?

Auto-reconnect

Would be nice if it had an auto-reconnect feature that reconnects every time it gets kicked (server restarts).

Can't start bot

When I try to start the bot, I get this error message: (both with the one I compiled and with the latest release)
Authentication failed with code 403 from https://authserver.mojang.com/authenticate: HTTP/1.1 403 Forbidden
If I wait 10 minutes, it usually works again. Is this an error from the bot or is it only the Minecraft Authentication server? (sorry for wasting ur time, im just dumb)

Connection refused

What information can I provide you for troubleshooting?

I'm on Ubunut 18.04. and MC java v. 1.15.2. I'm getting this:

[2020-04-18 19:26:16] [SEVERE ] Could not start bot: Connection refused (Connection refused)
[2020-04-18 19:26:16] [INFO ] FishingBot restarts in 3 seconds...

chat

pls do that you can do commands with the bots

Auto-reconnect

Would be nice if it had an auto-reconnect feature that reconnects every time it gets kicked (server restarts).

Error during first start, unable to generate config file

When running the jar downloaded via readme I get the following error.
Not a java developer, am I doing something wrong?

java -jar Fishingbot.jar
Exception in thread "main" java.lang.NoClassDefFoundError: com/sun/corba/se/impl/io/TypeMismatchException
	at systems.kinau.fishingbot.io.Config.init(Config.java:14)
	at systems.kinau.fishingbot.io.SettingsConfig.<init>(SettingsConfig.java:60)
	at systems.kinau.fishingbot.FishingBot.<init>(FishingBot.java:66)
	at systems.kinau.fishingbot.Main.main(Main.java:11)
Caused by: java.lang.ClassNotFoundException: com.sun.corba.se.impl.io.TypeMismatchException
	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)
	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
	... 4 more

Support spoofing forge

When trying to sign into a forge server, this error presents itself.

java.net.SocketException: Software caused connection abort: recv failed
        at java.net.SocketInputStream.socketRead0(Native Method)
        at java.net.SocketInputStream.socketRead(Unknown Source)
        at java.net.SocketInputStream.read(Unknown Source)
        at java.net.SocketInputStream.read(Unknown Source)
        at java.net.SocketInputStream.read(Unknown Source)
        at java.io.FilterInputStream.read(Unknown Source)
        at systems.kinau.fishingbot.network.protocol.Packet.readVarInt(Packet.java:108)
        at systems.kinau.fishingbot.network.protocol.NetworkHandler.readUncompressed(NetworkHandler.java:425)
        at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:419)
        at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:210)
        at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:143)
        at systems.kinau.fishingbot.Main.main(Main.java:12)
[2020-04-05 12:09:44] [WARNING] Could not receive packet! Shutting down!
[2020-04-05 12:09:44] [INFO   ] Module "ClientDefaultsModule" disabled!
[2020-04-05 12:09:44] [INFO   ] Module "FishingModule" disabled!
[2020-04-05 12:09:44] [INFO   ] FishingBot restarts in 3 seconds...
[2020-04-05 12:09:47] [INFO   ] Module "FishingModule" enabled!
[2020-04-05 12:09:47] [INFO   ] Module "HandshakeModule" enabled!
[2020-04-05 12:09:47] [INFO   ] Module "LoginModule" enabled!
[2020-04-05 12:09:47] [INFO   ] Module "ChatCommandModule" enabled!
[2020-04-05 12:09:47] [INFO   ] Module "ClientDefaultsModule" enabled!
[2020-04-05 12:09:47] [SEVERE ] Login failed: {"text":"This server has mods that require Forge to be installed on the client. Contact your server admin for more details."}
[2020-04-05 12:09:47] [INFO   ] Module "ClientDefaultsModule" disabled!
[2020-04-05 12:09:47] [INFO   ] Module "FishingModule" disabled!
[2020-04-05 12:09:47] [INFO   ] FishingBot restarts in 3 seconds...
Exception in thread "Thread-5" Exception in thread "Thread-3" java.lang.NullPointerException
        at systems.kinau.fishingbot.FishingBot.lambda$connect$0(FishingBot.java:202)
        at java.lang.Thread.run(Unknown Source)
java.lang.NullPointerException
        at systems.kinau.fishingbot.FishingBot.lambda$connect$0(FishingBot.java:202)
        at java.lang.Thread.run(Unknown Source)

https://wiki.vg/Minecraft_Forge_Handshake#Pre-1.13

https://github.com/PrismarineJS/node-minecraft-protocol-forge this is an offering for node-protocol (which doesn't support 1.15 grumble grumble).

I might take a look into implementing this, but we'll see

CMD errors

Hello and sorry im not sure if I'm doing this wrong but I download Fishingbot.jar and use cmd and type java -jar Fishingbot.jar and I get a ton of Warnings and I dont know how to fix it.
Problem

error

[2020-04-19 18:44:30] [INFO ] Module "ClientDefaultsModule" disabled!
[2020-04-19 18:44:30] [INFO ] Module "FishingModule" disabled!
[2020-04-19 18:44:30] [INFO ] FishingBot restarts in 3 seconds...
[2020-04-19 18:44:33] [INFO ] Module "FishingModule" enabled!
[2020-04-19 18:44:33] [INFO ] Module "HandshakeModule" enabled!
[2020-04-19 18:44:33] [INFO ] Module "LoginModule" enabled!
[2020-04-19 18:44:33] [INFO ] Module "ChatProxyModule" enabled!
[2020-04-19 18:44:33] [INFO ] Module "ChatCommandModule" enabled!
[2020-04-19 18:44:33] [INFO ] Module "ClientDefaultsModule" enabled!
[2020-04-19 18:44:34] [INFO ] Login successful!
[2020-04-19 18:44:34] [INFO ] Name: IOwenronal
[2020-04-19 18:44:34] [INFO ] UUID: 0b2caed5-f05f-4a64-8f96-3886eb973ee6
Exception in thread "Thread-11" java.lang.NullPointerException
at systems.kinau.fishingbot.network.protocol.play.PacketOutUseItem.write(PacketOutUseItem.java:28)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.sendPacket(NetworkHandler.java:371)
at systems.kinau.fishingbot.modules.FishingModule.lambda$onSetDifficulty$7(FishingModule.java:224)
at java.lang.Thread.run(Unknown Source)
systems.kinau.fishingbot.network.utils.InvalidPacketException: VarInt too big
at systems.kinau.fishingbot.network.protocol.Packet.readVarInt(Packet.java:112)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:409)
at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:210)
at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:143)
at systems.kinau.fishingbot.Main.main(Main.java:12)
[2020-04-19 18:44:35] [WARNING] Could not receive packet! Shutting down!
[2020-04-19 18:44:35] [INFO ] Module "ClientDefaultsModule" disabled!
[2020-04-19 18:44:35] [INFO ] Module "FishingModule" disabled!
[2020-04-19 18:44:35] [INFO ] FishingBot restarts in 3 seconds...

Cast Exception

When I run the program I get this error:

exception in thread "main" java.lang.ClassCastException: com.google.gson.JsonPrimitive cannot be cast to com.google.gson.JsonObject
at com.google.gson.JsonObject.getAsJsonObject (JsonObject.java:205)
at systems.kinau.fishingbot.network.ping.ServerPinger.ping (ServerPinger.java:80)
at systems.kinau.fishingbot.fishingbot.(Fighingbot.java:133)
at systems.kinau.fishingbot.Main.main(Main.java:13)

[Feature request] Passive mode

This feature would allow you to run this in the background (maybe even on a Raspberry Pi), it would passively ping the server to check how many players are online, and if it fits into criteria below a certain amount of players, it will connect and do it's thing :)

settings example:

passive-mode=true
passive-player-treshold=3

(I'm on a slow server and think I'm only going to be using this while only few people are online to prevent causing lag)

Auto Respawn for 1.15.x

I made an automatic respawn function

Implementation:
In NetworkHandler.java:

getPlayRegistryIn().get(ProtocolConstants.MINECRAFT_1.15).registerPacket(0x49, PacketInSetHealth.class);//added, done
getPlayRegistryOut().get(ProtocolConstants.MINECRAFT_1.15).registerPacket(0x04, PacketOutRespawn.class); //added, done

Add this to the other @Getter @Setter annotations in Player.java:

@Getter @Setter private int health;
@Getter @Setter private int food;
@Getter @Setter private int saturation;

Add this to the other events in Player.java:

@EventHandler
    public void onUpdateHP(UpdateHealthEvent event) {
        this.health = event.getHealth();
        this.food = event.getSaturation();
        if(this.health <= 0) {
            double posX = FishingBot.getInstance().getPlayer().x;
            double posY = FishingBot.getInstance().getPlayer().y;
            double posZ = FishingBot.getInstance().getPlayer().z;
            posX = Math.round(posX);
            posY = Math.round(posY);
            posZ = Math.round(posZ);
            FishingBot.getLog().info("DIED! Respawning ... (Position: " + posX + " " + posY + " " + posZ + ")");
            if(!FishingBot.getInstance().getConfig().getDeathMessage().equalsIgnoreCase("false")) {
                String deathMessage = FishingBot.getInstance().getConfig().getDeathMessage();
                deathMessage = deathMessage.replace("{X}", String.valueOf(posX));
                deathMessage = deathMessage.replace("{Y}", String.valueOf(posY));
                deathMessage = deathMessage.replace("{Z}", String.valueOf(posZ));
                FishingBot.getInstance().getNet().sendPacket(new PacketOutChat(deathMessage));
            }

            if(FishingBot.getInstance().getConfig().isAutoRespawnEnabled()) {
                FishingBot.getInstance().getNet().sendPacket(new PacketOutRespawn());
            }
        }

        FishingBot.getLog().info("Health: " + this.health);
        FishingBot.getLog().info("Food Level: " + this.food);
        FishingBot.getLog().info("Saturation Level: " + this.saturation);
    }

Create the class PacketInSetHealth in systems.kinau.fishingbot.network.protocol.play with the following code:

/*
 * Credits to MrKinau for the code base.
 * I've just stolen half the class lol.
 */

package systems.kinau.fishingbot.network.protocol.play;

import com.google.common.io.ByteArrayDataOutput;
import lombok.Getter;
import systems.kinau.fishingbot.FishingBot;
import systems.kinau.fishingbot.event.play.UpdateHealthEvent;
import systems.kinau.fishingbot.network.protocol.NetworkHandler;
import systems.kinau.fishingbot.network.protocol.Packet;
import systems.kinau.fishingbot.network.utils.ByteArrayDataInputWrapper;

public class PacketInSetHealth extends Packet {

    @Getter private int food;
    @Getter private int saturation;
    @Getter private int health;

    @Override
    public void write(ByteArrayDataOutput out, int protocolId) {
        //Only incoming packet
    }

    @Override
    public void read(ByteArrayDataInputWrapper in, NetworkHandler networkHandler, int length, int protocolId) {
        health = (int)in.readFloat();
        food = Packet.readVarInt(in);
        saturation = (int)in.readFloat();

        FishingBot.getLog().info("Health: " + health);
        FishingBot.getLog().info("Food: " + food);
        FishingBot.getLog().info("Saturation: " + saturation);

        FishingBot.getInstance().getEventManager().callEvent(new UpdateHealthEvent(health, food, saturation));
    }
}

Create the class PacketOutRespawn in systems.kinau.fishingbot.network.protocol.play with the following code: (you probably have to use the switch (protocolId) for versions with other packet stuff)

package systems.kinau.fishingbot.network.protocol.play;

import com.google.common.io.ByteArrayDataOutput;
import systems.kinau.fishingbot.network.protocol.NetworkHandler;
import systems.kinau.fishingbot.network.protocol.Packet;
import systems.kinau.fishingbot.network.utils.ByteArrayDataInputWrapper;

public class PacketOutRespawn extends Packet {

    @Override
    public void write(ByteArrayDataOutput out, int protocolId) {
        Packet.writeVarInt(0, out);
    }

    @Override
    public void read(ByteArrayDataInputWrapper in, NetworkHandler networkHandler, int length, int protocolId) {
        //nothing.
    }
}

In SettingsConfig.java insert this to the other @properties annotations:

@Property(key = "auto-respawn") private boolean AutoRespawnEnabled = true;
@Property(key = "death-msg") private String DeathMessage = "I died at X: {X}, Y: {Y}, Z: {Z}!";

Create the class UpdateHealthEvent in systems.kinau.fishingbot.event.play with this code:

package systems.kinau.fishingbot.event.play;

import lombok.AllArgsConstructor;
import lombok.Getter;
import systems.kinau.fishingbot.event.Event;

@AllArgsConstructor
public class UpdateHealthEvent extends Event {

    @Getter private int health;
    @Getter private int food;
    @Getter private int saturation;
}

I hope you can use my code and/or improve it! Do whatever you want with it!
Note: You will have to add some imports in the modified files. (Also the code is a bit buggy, but I hope you can still use it)

Error at ClientDefaultsModule

I get the following error when trying to start the bot.
[2020-04-28 16:58:11] [INFO ] Module "ClientDefaultsModule" enabled!
[2020-04-28 16:58:12] [SEVERE ] Login failed: {"extra":[{"text":"Not authenticated with "},{"clickEvent":{"action":"open_url","value":"http://Minecraft.net"},"text":"Minecraft.net"},{"text":""}],"text":""}
[2020-04-28 16:58:12] [INFO ] Module "ClientDefaultsModule" disabled!
Capture

server message not registering causing error

when the error happens it does not catch fish so im assuming its a easy fix on your end

[2019-11-13 19:55:42] [INFO ] Achieved level 36
[2019-11-13 19:55:46] [INFO ] Caught "RAW_FISH"
java.lang.IllegalStateException: Not a JSON Object: "?7"
at com.google.gson.JsonElement.getAsJsonObject(JsonElement.java:91)
at systems.kinau.fishingbot.network.protocol.play.PacketInChat.read(PacketInChat.java:37)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readPacket(NetworkHandler.java:446)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readUncompressed(NetworkHandler.java:396)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:371)
at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:218)
at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:144)
at systems.kinau.fishingbot.Main.main(Main.java:12)
java.lang.IllegalStateException: Not a JSON Object: "?e?lDonate"
at com.google.gson.JsonElement.getAsJsonObject(JsonElement.java:91)
at systems.kinau.fishingbot.network.protocol.play.PacketInChat.read(PacketInChat.java:37)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readPacket(NetworkHandler.java:446)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readUncompressed(NetworkHandler.java:396)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:371)
at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:218)
at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:144)
at systems.kinau.fishingbot.Main.main(Main.java:12)
java.lang.IllegalStateException: Not a JSON Object: "?7"
at com.google.gson.JsonElement.getAsJsonObject(JsonElement.java:91)
at systems.kinau.fishingbot.network.protocol.play.PacketInChat.read(PacketInChat.java:37)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readPacket(NetworkHandler.java:446)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readUncompressed(NetworkHandler.java:396)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:371)
at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:218)
at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:144)
at systems.kinau.fishingbot.Main.main(Main.java:12)

Add auth token-based login, as well as command-line flags and usage

I keep getting my IP tempbanned by Mojang's auth service from logging in to Minecraft. I've done a lot of work with Minecraft automation in the past and the solution is always the same: switch to using authentication tokens. I built a tool to help automate and manage this: https://github.com/sudofox/minecraft-alt-manager

Now, along with being able to simply pass an authentication token to the bot to avoid unnecessary re-auths (it tries to auth over and over again if it fails which quickly worsens the length of the auth ban), it would be excellent to have a full set of command line flags I can use to override the config file.

For example:

-c  --config		Path to config file (default: config.properties)
-u  --username		Account username or email
-p  --password		Account password
-t  --token		Auth token (overrides username/password)
-h  --server-ip		Server IP
-P  --server-port	Server Port

This way you can put all your preferred config stuff into your config file and override it with command-line flags.

mining bot

please do that they can put items they catch in chest and please make automine bots

Command To empty Inventory

It would be much easier to allow the bot to empty it's inventory on command so the other player can just pick the items up. Empty its inventory as in pressing "ctrl" and "Q" on every inventory slot (except the fishing rod equipped).

Bot too slow! and other errors, what's causing this?

I'm constantly getting these errors:

  • Bot is slow (Maybe stuck). Trying to restart!
  • Could not receive packet! Shutting down!

What's causing these errors? The server is not shutting down, all other clients are unaffected.

Edit: New issue arose, this is the output:
Exception in thread "main" java.lang.NoClassDefFoundError: javafx/util/Pair
at systems.kinau.fishingbot.network.protocol.play.PacketInEntityMetadata.readNBT(PacketInEntityMetadata.java:512)
at systems.kinau.fishingbot.network.protocol.play.PacketInEntityMetadata.readWatchableObjects_1_14(PacketInEntityMetadata.java:131)
at systems.kinau.fishingbot.network.protocol.play.PacketInEntityMetadata.defaultLoop(PacketInEntityMetadata.java:89)
at systems.kinau.fishingbot.network.protocol.play.PacketInEntityMetadata.read(PacketInEntityMetadata.java:48)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readPacket(NetworkHandler.java:411)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readUncompressed(NetworkHandler.java:362)
at systems.kinau.fishingbot.network.protocol.NetworkHandler.readData(NetworkHandler.java:337)
at systems.kinau.fishingbot.FishingBot.connect(FishingBot.java:142)
at systems.kinau.fishingbot.FishingBot.start(FishingBot.java:104)
at systems.kinau.fishingbot.Main.main(Main.java:12)
Caused by: java.lang.ClassNotFoundException: javafx.util.Pair
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
... 10 more

My guess is that the game sees something that it can't detect, or understand, so it quits. That's my BEST guess though, please help LOL :)

Announce level ups

"If you could announce leveling up along with the current level both chat and console / discord that would be fantastic"

Wont work

When i click to open the Fishing Bot java... it makes it seem as if something is loading.. due to the revolving circle next to the mouse.. but nothing happens

Auto-select fishing rod from inventory when available

I've been having an odd issue where sometimes a mending rod will break (maybe the bot gets stuck or something.) However tossing it another fishing rod doesn't seem to make it autoselect the rod unless the currently selected hotbar slot happens to be the one with the rod in it, which can only be changed as an actual player.

Would be great if it could automatically pull rods from the inventory in certain conditions, such as if it fishes or picks up a better rod than the one it's currently using.

Here is a mod with a reference implementation of the "select better rod" functionality: AutoFish

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.