Skip to main content

Module agents

Module agents 

Source
Expand description

Agent frameworks: batteries-included event loops for the three RLBot interface kinds.

Pick the trait that matches what your interface controls:

  • BotAgent + run_bot_agents: one agent instance per controllable (usually one per car), each ticked on its own thread. This is what most bots want.
  • HivemindAgent + run_hivemind_agent: a single instance that sees every car on the team and ticks on one thread. Use this when your cars need shared state or coordinated decisions.
  • ScriptAgent + run_script_agent: no controllables at all, for match management, state setting, and rendering scripts.

All three runners handle the handshake (ConnectionSettings, InitComplete), answer PingRequests, and exit cleanly on DisconnectSignal. If you need full control over the socket instead, use RLBotConnection directly.

See the atba_agent, atba_hivemind, and high_jump_script examples in rlbot/examples for complete programs.

Enums§

AgentError

Traits§

BotAgent
The behavior of a single bot controlling one controllable (usually a car).
HivemindAgent
The behavior of a hivemind: one agent instance controlling a whole team.
ScriptAgent
The behavior of a script: an interface with no controllables.

Functions§

run_bot_agents
Run multiple agents with n agents per thread. They share a connection. Ok(()) means a successful exit; one of the bots received a None packet.
run_hivemind_agent
Run a single HivemindAgent for a whole team on one thread. Ok(()) means a successful exit, i.e. core sent a disconnect.
run_script_agent
Run a single ScriptAgent with no controllables on one thread. Ok(()) means a successful exit, i.e. core sent a disconnect.