Skip to content

Framework for making games and not only games in entity system manner.

License

Notifications You must be signed in to change notification settings

tdzienniak/entropy

Repository files navigation

Note: this engine is still in active developement. It lacks many tests, documentation is not complete and breaking API changes are very likely to happen. It is not production ready, but I was able to build a bunch of games with it, so if you want to experiment or help with developement, you are welcome.

Documentation note: all "classes" in docs are not real classes, they are factory functions and should be called without new. JSDocs has no convenient way to describe factory functions.

entropy-logo

Build Status

JavaScript entity system framework for games.

Entropy is literally just a framework, variation on an entity system, that can help you organize and write your game in very specific way. It also does many things for you, such as game state management, input handling. It is not tied to any graphics library, sound library, or other fancy stuff. If you are not familiar with entity system idea, check out these articles: one two.

Key features

  • entity system, which mean very good game code organization and simple constructs
  • easy integration with any library (see examples for p2.js physics library integration)
  • plugins

Installation

Recommended way to install and use Entropy is to use npm:

npm install --save entropy.js

Then require it in your project and use your favourite bundling tool to package your game for browser use.

If you prefer to just include script as standalone lib, put reference to entropy.min.js file in the script tag or add it to you assets loader. Use global variable Entropy to interact with the framework.

Getting started

The best way to get a grasp of Entropy is to read the wiki.

You can also read the docs and check out examples:

  1. Bunnies (benchmark and PIXI.js rendering)
  2. Breakout (complete game with p2.js physics, PIXI rendering and plugins)

Packages

This is monorepo. You can check versions of included packages by looking at the table below.

Package Version
entropy.js npm
entropy.js-state-plugin npm
entropy.js-loader-plugin npm
entropy.js-animation-plugin npm

Building and testing

After cloning the repo run:

npm install

Then you need to bootstrap all packages (install dependencies, etc.):

npm run bootstrap

Bootstraping automatically compiles and builds all packages.

If you want to bundle or build single package, cd into desired package directore and use npm scripts:

cd ./packages/entropy
npm run bundle # bundles package for browser
npm run babel # transpiles source files

To run tests for all packages:

npm test

Docs

Documentation is located in docs folder. You can also read it online: http://tdzienniak.github.io/entropy/docs/entropy.js/1.0.0-alpha.5/.

Testers and people who have helped

@DarkEngineer
@Tanner

License

MIT

About

Framework for making games and not only games in entity system manner.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published