xonecas.io
256
Fl

FlyingFunctions / commit c696bdd

populated readme

xonecas2013-03-26 c696bddf8129ba47116feb51b6bc9a0accf25fd6 parent f326d00

1 file changed

README.md+13−7
@@ -12,13 +12,19 @@ Still want to try it out? Ok, just include the `lib/flying-functions.js` in your
1212 After it's loaded you can initialize the engine. There are a options you can pass to the constructor
1313 check out the annotted source code in `docs/` for more on this.
1414
15- <script src="../lib/flying-functions.js"></script>
16- <script>
17- var ff = new FlyingFunctions({
18- width: 640,
19- height: 320
20- });
21- </script>
15+```javascript
16+ var ff = new FlyingFunctions({
17+ width: 640,
18+ height: 320
19+ });
20+
21+ ff.on('frame', function () {
22+ // my drawing code
23+ });
24+
25+ // start the game loop
26+ ff.loop();
27+```
2228
2329 Here is a full example (form the test folder):