Coder Social home page Coder Social logo

commandovmgit / jocly Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aclap-dev/jocly

0.0 0.0 0.0 81.43 MB

Javascript library and tools to provide user interface (2D, 3D, VR) and engine for playing board games

Home Page: https://jocly.com/

License: Other

JavaScript 78.57% CSS 0.51% HTML 20.92%

jocly's Introduction

Jocly is a library and set of tools to integrate boards games into Web environments. It comes with a large collection of abstract strategy games, 2D and 3D user interface, artificial intelligence to play against.

Demos

Controlled interface for playing Chess. Click Other Jocly games to switch to other games.

Simple human vs computer: Classic chess, Circular chess, Multi layers chess, Hexagonal chess, Chinese chess, Middle-age chess, Scrum

Or see and try all available games

JoclyBoard is a multi-platform desktop application based on Jocly and Electron.

Install

npm install jocly

Using Jocly in a Web page

Insert this line to your HTML source code:

<script src="node_modules/jocly/dist/browser/jocly.js"></script>

You are now ready to use the Jocly API through the Jocly global object.

Using Jocly in a node.js application

const Jocly = require("jocly");

You are now ready to use the Jocly API through the Jocly entry point.

Building

  • install the node.js environment (using nvm is probably a good idea)
  • install gulp: npm install -g gulp
  • install git
  • clone Jocly from github: git clone https://github.com/mi-g/jocly.git
  • enter the jocly directory
  • download required modules: npm install
  • build: gulp build
  • dist/browser contains the javascript library to build web applications, dist/node is the module to be used for node.js applications

Notes:

  • using gulp build watch instead of gulp build makes gulp start watching files after the build. Whenever a file is changed, a build is automatically generated
  • you can use --no-default-games to prevent including the game modules from directory, and --modules <colon-separated-directories> to specify additional game modules to include. For instance, gulp --no-default-games --modules src/games/chessbase:src/games/checkers build will only generate distribution for Chess and checkers games
  • you can specify the games to be built in the distribution with the --games option. For instance, gulp --no-default-games --modules src/games/chessbase --games xiangqi:classic-chess build only generates Jocly for Classic Chess and XiangQi
  • using the no-obsolete option filters out the games marked as obsolete

API Documentation

Jocly offers two distinct APIs:

jocly's People

Contributors

mi-g avatar jcfrog avatar ecobabush 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.