PvpBotdocs
Help

Troubleshooting

The usual reasons a bot won't move, won't take damage or won't attack, and how to fix them.

Always start here /pvpbot diagnose <bot> checks the bot and tells you what's blocking it: game mode, damage immunity, login plugins, plugins cancelling damage, movement or knockback, and the last knockback it took. /pvpbot diagnose <player> does the same from the other side: why bots can't hurt a particular player (below). To see what a bot is thinking while it fights, use /pvpbot debugview.

The bot hops on the spot and won't move

It's almost always a login plugin (AuthMe, LoginTo…). A bot can't type /login, so the plugin keeps it locked.

  1. Check that auth-autologin is true (it is by default): it registers bots as already logged in.
  2. If your login plugin isn't one PvpBot recognises, /pvpbot diagnose shows it. In that case set the login plugin to ignore players with the bots' names, or disable it to test.

The bot takes no damage

  • Invulnerable flag: some login plugins set it and never clear it. With force-vulnerable: true (the default) PvpBot clears it. diagnose tells you if this is the cause.
  • Region protection or PvP off: WorldGuard, safe zones and the like cancel damage. It's better to move the fight out of the protected area. As a last resort there's /pvpbot set bypass-damage-protection true, but it overrides all protection, legitimate protection included.
  • Game mode: a bot in creative or spectator takes no damage.

The bot won't attack me

  • It was just spawned: it waits spawn-grace seconds, then sizes you up for reaction-ticks.
  • It can't see you: with detection on it needs line of sight. Crouching or invisible, you're noticed from closer.
  • You're in creative or spectator (attack-invincible is off).
  • A preset made it passive (/pvpbot preset shows which is active), or auto-target or target-players are off, perhaps just for its faction (/pvpbot faction info).
  • You're allies or at peace: see Factions.
  • It's paused, hiding or retreating.

Bots can't hurt a player

/pvpbot diagnose <player> [reset]

It reads the player's state the way the game's damage checks see it: game mode, the invulnerable flag, the "client still loading" protection, hit invulnerability, a raised shield, a shared scoreboard team, PvP in the world, and the client version. It lists every bot within 48 blocks, with whether it would fight them and whether it can see them.

From server start, every bot hit aimed at a real player is logged, and the report shows what became of each one:

OutcomeWhat it means
Turned awayThe game refused the hit before any plugin saw it. The reason is checked on the spot.
CancelledA plugin stopped it, and the report says at which event priority.
ShieldTheir raised shield took it.
ZeroedIt went through with no damage left.
LandedIt hurt them.

It ends with a one-line verdict. reset starts a fresh log.

The bot fights with its fists

It has no weapons. Give it a kit or /pvpbot givebow <bot>. auto-equip must be on for it to hold the best weapon by itself.

Lag with lots of bots

  • Raise target-scan-interval (say from 10 to 20): looking for targets is the most expensive thing a bot does. When its target dies or leaves, a bot still looks again at once.
  • Lower max-target-distance.
  • Turn wander off for bots that don't need to move, or pause them.

Measured numbers are on Benchmarks.

Odd stats or speed after a boss or an item

Another plugin added an attribute modifier (health, speed, damage) and never removed it. /pvpbot resetattr <player|bot> removes every modifier and restores a player's correct base values. It works on real players too.

The world folder fills up with bot files

Bots are real players, so the server saves data, stats and advancements for them like anyone else. /pvpbot clearplayerdata deletes those files for bots that no longer exist. It leaves active bots, kits, factions, scripts and config alone.

The plugin loads but nothing works

  • Check you installed the right jar for your platform and version (see Installation). The wrong one says so in the console and won't spawn bots.
  • Read the console at startup. A kits.yml copied from another server may fail to load: PvpBot still starts, without kits, and says so in the console.

Companions aren't put away

Check companions.holding-world: it must be the name of a world that exists on your server. See Companions.