# Bot programming wiki

Build a Logic Bot, write the PHP pilot that controls it, and use battle evidence to improve it. Start with a working example or look up the part of the engine you need.

## Build your first bot

- [Getting started](getting-started.md) walks through a complete pilot, from choosing the loadout to landing a shot in Practice.
- [Progressive tutorials](tutorials.md) build a single pilot in five stages, starting with a bot that only collects resources.
- [PHP syntax](php-syntax.md) covers the language subset, helper functions, state, and script limits.
- [Worked examples](examples.md) contains complete scripts for a Railgun scout, a durable Beam Laser build, and a team partner.

## Understand the engine

- [Pilot API](pilot-api.md) explains observations, movement, targeting, commands, and feedback.
- [PHP reference](php-reference.md) lists the supported Pilot methods, PHP functions, constants, and signatures.
- [Glossary](glossary.md) defines terms shared by Bot Builder, the simulator, and replays.
- [Equipment and loadouts](equipment.md) explains mounts, weapon types, defenses, and resource trade-offs.
- [Engine architecture](architecture.md) follows a tick from the PHP interpreter through the simulator to the replay.

## Make it fight better

- [Combat strategy](combat-strategy.md) covers closing distance, holding a useful firing range, choosing targets, and managing resources.
- [Team strategy](team-strategy.md) covers signals, roles, pickup claims, and friendly fire.
- [Testing and iteration](testing.md) shows how to read the decision trace, compare checkpoints, and test beyond a single seed.
- [Troubleshooting](troubleshooting.md) helps diagnose stalls, missed shots, empty reserves, and script errors.
