Skip to content

Game logic and ORM-free models behind SuperTues online board game.

License

Notifications You must be signed in to change notification settings

jonlhouse/super_tues-board

Repository files navigation

SuperTues::Board

SuperTues is a board game created by Peder Lindberg (rights reserved and used here with permission). This gem contains the "game logic" as a series of plain-old ruby objects.

Installation

Add this line to your application's Gemfile:

gem 'super_tues-board'

And then execute:

$ bundle

Or install it yourself as:

$ gem install super_tues-board

Usage

Create a new SuperTues game with the following:

	game = Game.new

An "in-progress" game can be started by passing a GameState object during initialization:

	game = Game.new(GameState.load(...))

Players can be added to the game using:

	player = game.add_player('player_name', Candidate.new("Sen. Barnes"))

Advance the game when a player takes a turn:

	player_updates = game.player_turn(player.actions)

Contributing

  1. Fork it ( http://github.com//super_tues-board/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

About

Game logic and ORM-free models behind SuperTues online board game.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages