2.14.9 • Published 2 years ago

@dxos/chess-bot v2.14.9

Weekly downloads
-
License
AGPL-3.0
Repository
-
Last release
2 years ago

Game Bot

This is a Bot for playing chess games. Core model is located at Chess Core. Currently the bot is a player of black pieces, making random moves.

Run the Bot locally

Use two terminals.

First terminal

  1. Run the factory:
cd examples/chess-bot
yarn wire bot factory start --local-dev

Copy the bot factory topic.

Second terminal

  1. Create or join a party:
yarn wire party create
// or
yarn wire party join <party ID> --url <copied invite URL>
  1. Create or join a chess game:
chess create
// or
chess join 1588764145416
  1. Spawn the bot:
bot spawn --bot-id="wrn:bot:wireline.io/chess" --topic <bot-factory-topic> --spec='{"id":1588764145416}'
  1. Keep playing as a white player, as using CLI or App

  2. The bot will be responding as a black player

Publishing

Assuming MacOS at this point

  1. Pulish and register
yarn package:macos-x64
yarn wire bot publish
yarn wire bot register
  1. Query to make sure it's there
yarn wire bot query --name 'wireline.io/chess'
  1. Run the bot factory NOT-locally:
cd examples/chess-bot
yarn wire bot factory start
  1. Spawn the bot as before. It will be downloaded from WNS/IPFS