
Hi! I won't have my PC until tomorrow but I'll see if I can help you troubleshoot.
It seems the Node eval console is running. What command(s) did you enter to run PS?
stream.write(`>p1 move 1`);
stream.write(`>p2 switch 2`);
cd
commandnode pokemon-showdown simulate-battle
. You might not see any output but the sim has started and is accepting input.>start {"formatid":"gen9randombattle"}
>player p1 {"name":"Alice"}
>player p2 {"name":"Bob"}
>p1 move 1
and >p2 switch 2
In that case, you will write to the sim using lines such as:
Code:stream.write(`>p1 move 1`); stream.write(`>p2 switch 2`);
However, I've provided a tutorial on how to get an interactive sim console below, which is probably closer to what you want:
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 thecd
command
3. Use the commandnode 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
to start a random battleCode:>start {"formatid":"gen9randombattle"} >player p1 {"name":"Alice"} >player p2 {"name":"Bob"}
5. Control the battle with lines such as>p1 move 1
and>p2 switch 2
In that case, you will write to the sim using lines such as:
Code:stream.write(`>p1 move 1`); stream.write(`>p2 switch 2`);
However, I've provided a tutorial on how to get an interactive sim console below, which is probably closer to what you want:
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 thecd
command
3. Use the commandnode 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
to start a random battleCode:>start {"formatid":"gen9randombattle"} >player p1 {"name":"Alice"} >player p2 {"name":"Bob"}
5. Control the battle with lines such as>p1 move 1
and>p2 switch 2