Files
bitburner-src/markdown/bitburner.go.makemove.md
T
2025-03-22 23:59:46 -07:00

41 lines
1.2 KiB
Markdown

<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) &gt; [bitburner](./bitburner.md) &gt; [Go](./bitburner.go.md) &gt; [makeMove](./bitburner.go.makemove.md)
## Go.makeMove() method
Make a move on the IPvGO subnet game board, and await the opponent's response. x:0 y:0 represents the bottom-left corner of the board in the UI.
**Signature:**
```typescript
makeMove(
x: number,
y: number,
playAsWhite?: boolean,
): Promise<{
type: "move" | "pass" | "gameOver";
x: number | null;
y: number | null;
}>;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| x | number | x coordinate of move to make |
| y | number | y coordinate of move to make |
| playAsWhite | boolean | _(Optional)_ optional. If true, attempts to play as white and then wait for black's move. Can only be used when playing as white when the opponent is set to "No AI" |
**Returns:**
Promise&lt;{ type: "move" \| "pass" \| "gameOver"; x: number \| null; y: number \| null; }&gt;
a promise that contains the opponent move's x and y coordinates (or pass) in response, or an indication if the game has ended
## Remarks
RAM cost: 4 GB