<commit_before># bindlestiff [![experimental](http://hughsk.github.io/stability-badges/dist/experimental.svg)](http://github.com/hughsk/stability-badges) #

A light entity/component system for building JavaScript games. Can
easily be used alongside other libraries/modules such as [d3](http://d3js.org),
[voxel.js](http://voxeljs.org), or
[three.js](http://threejs.org) - if you're looking for something lighter
still, the entity's mixin functionality is using
[bindle](http://github.com/hughsk/bindle) under the hood.

Totally experimental, subject to at least one breaking API change, so think
twice before you use this (for now). Built with
[browserify](http://browserify.org/) in mind.

## Installation ##

``` bash
npm install bindlestiff
```

## Example ##

``` javascript
var bs = require('bindlestiff')
var ticker = require('ticker')

var manager = bs.manager()

var physical = bs.component('physical')
  .on('init', function() {
    this.pos[0] = this.spd[0] = 0
    this.pos[1] = this.spd[1] = 0
  })
  .on('tick', function() {
    this.pos[0] += this.spd[0]
    this.pos[1] += this.spd[1]
  })

var controllable = bs.component('controllable')
  .needs('physical')
  .on('tick', function() {
    this.spd[0] = controls.down - controls.up
    this.spd[1] = controls.left - controls.right
  })<commit_msg>deprecate<commit_after># bindlestiff [![deprecated](http://hughsk.github.io/stability-badges/dist/deprecated.svg)](http://github.com/hughsk/stability-badges) #

**Deprecated**

A light entity/component system for building JavaScript games. Can
easily be used alongside other libraries/modules such as [d3](http://d3js.org),
[voxel.js](http://voxeljs.org), or
[three.js](http://threejs.org) - if you're looking for something lighter
still, the entity's mixin functionality is using
[bindle](http://github.com/hughsk/bindle) under the hood.

## Installation ##

``` bash
npm install bindlestiff
```

## Example ##

``` javascript
var bs = require('bindlestiff')
var ticker = require('ticker')

var manager = bs.manager()

var physical = bs.component('physical')
  .on('init', function() {
    this.pos[0] = this.spd[0] = 0
    this.pos[1] = this.spd[1] = 0
  })
  .on('tick', function() {
    this.pos[0] += this.spd[0]
    this.pos[1] += this.spd[1]
  })

var controllable = bs.component('controllable')
  .needs('physical')
  .on('tick', function() {
    this.spd[0] = controls.down - controls.up
    this.spd[1] = controls.left - controls.right
  })
{'fraction_non_alphanumeric': 0.17092976045473002, 'fraction_numerical': 0.011368250101502234, 'mean_word_length': 4.198312236286919, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '846075', 'n_tokens_mistral': 895, 'n_tokens_neox': 840, 'n_words': 197}