BotWars
Loading…

Hello tank

Drive your tank to the marker.

BotWars is a programming game. You write one Python class; every tick it steers a tank, sweeps a radar, aims a turret and fires. Then you watch your bot fight other bots in a real-time arena, and replay any tick to see why it won or lost. Everything runs in your browser: no install, no account.

A first bot

from botwars import Bot


class MyBot(Bot):
    def on_tick(self, me, enemies):
        self.forward(8)               # drive at full speed
        self.turn_radar(45)           # sweep the radar
        if enemies:
            self.aim_at(enemies[0])   # point the turret at the first enemy seen
            self.fire(2)

The full bot API, written for people and AI agents alike: /llms-full.txt.