Giter Site home page Giter Site logo

uatc's Introduction

UATC - Ultimate Algorithm Test Client

note: This is a work in progress

This is a small test package for testing the socialgorithm platform.

Getting started

To install and run this util clone this repo and:

npm i
npm run build
node ./dist/uatc.js help

This expects that @socialgorithm/uabc is installed globally.

You will also need a player(s) that is ready to connect and play games.

Commands

uatc init - Spits out a scaffolding config file.

uatc play - Play a tournament.

uatc start-servers - Starts the game servers.

uatc stop-servers - Stops the game servers.

uatc validate-servers - Prints the status of the game servers

Config

This package is configured via a uatc.js file in the directory your running the command.

The best way to create this is to run uatc init which will give you the basic scaffolding.

Config:

{
	playTournament: {                                       // The config for the play mode. 
		players: [                                      // A collection of players to run against the game
			{
				command: 'node example.js',     // The command to run to start this player. See uabc file arg
				number: 5,                      // The number of players of this type to connect
				name: 'example'                 // The name to use when connecting to the game
			}
		],
		tournamentServerAddress: 'http://localhost:3141',
		autoplay: true,
		tournamentSettings: {                           // Settings to use when playing the tournament
			timeout: 100,
			numberOfGames: 50,
			type: "DoubleElimination",
			autoPlay: false
		}
	},
	servers: {      // config for the servers
		tournament: {
			location: '../tournament-server',       // relative location of the server. Must be npm installed and built
			startupCommand: 'node ./dist/index.js', // ensure this command starts the server rather than runs a script that spawns it like an npm command
			expectedPort: 3141                      // where it is expected to be once started. Used for validation
		},
		game: {
			location: '../tic-tac-toe-game-server',
			startupCommand: 'node ./dist/index.js',
			expectedPort: 5433
		}
	}
}

uatc's People

Contributors

confuddledpenguin avatar dependabot[bot] avatar reddyalready avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.