1. Clone Pokemon Showdown. You can use git from your command prompt if you have it installed, GitHub Desktop, etc
2. Go inside the pokemon-showdown directory with the
cd command
3. Use the command
node pokemon-showdown simulate-battle. You might not see any output but the sim has started and is accepting input.
4. Start the battle. Write some lines such as
Code:
>start {"formatid":"gen9randombattle"}
>player p1 {"name":"Alice"}
>player p2 {"name":"Bob"}
to start a random battle
5. Control the battle with lines such as
>p1 move 1 and
>p2 switch 2