Git Product home page Git Product logo

ox's People

Contributors

aerze avatar thaisrobba avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ox's Issues

Sprite speed problems

I need to fix the frame rate - it is getting sped up and down when returning to a scene.

EDIT: I think I will have to refactor the sprite entity.

Load data files

It should be possible to load data files like json and maybe txt with ease, simply by adding them to the assets manifest.

Add timers

It should be possible to:

  • reset timers
  • call a function when they end (with bound this)
  • pause/resume timers
  • remove/add timers

Submit to npm

Installing should be as easy as npm install ox2d or something like that.

ox.keyboard.isDown?

Maybe expose the keyboard the same way that ox.mouse is exposed? Perhaps expose ox.mouse further?

Perhaps think in terms of pointers (mouse + touch)? Hmmm.

Fix preloader

Right now it bugs out when loading things from outside the regular folders. Gotta fix that.

Also, loading bar looks weird and we probably shouldn't say "loading", looks meh.

Offer an options file

Perhaps an options file would be a good idea. People would be able to set up:

  • Plugins
  • Canvas size
  • Cursor
  • Debug (boolean)
  • ???

Some npm scripts fail in windows

Some of the build scripts return errors.

npm run assets
npm run entities
npm run scenes
$ npm run assets

> [email protected] assets c:\Users\aerze\projects\ox
> ./src/tools/assetsWatcher.js

'.' is not recognized as an internal or external command,
operable program or batch file.

npm ERR! Windows_NT 6.1.7601
npm ERR! argv "c:\\Program Files\\nodejs\\node.exe" "c:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "assets"
npm ERR! node v0.12.0
npm ERR! npm  v2.5.1
npm ERR! code ELIFECYCLE
npm ERR! [email protected] assets: `./src/tools/assetsWatcher.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] assets script './src/tools/assetsWatcher.js'.
npm ERR! This is most likely a problem with the ox2d package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     ./src/tools/assetsWatcher.js
npm ERR! You can get their info via:
npm ERR!     npm owner ls ox2d
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     c:\Users\aerze\projects\ox\npm-debug.log

Simple solution, I think, is to just but node in front of the string. windows doesn't read the hash bang and the top of the files.

{
        "assets": "node ./src/tools/assetsWatcher.js",
        "entities": "node ./src/tools/entitiesWatcher.js",
        "scenes": "node ./src/tools/scenesWatcher.js"
}

Define the Sprite API

Ideally, a sprite should offer the following options:

  • Anchor/Pivot
  • Masking
  • Crop
  • Scale
  • Rotation
  • Transform
  • Animation
  • Event listeners.

API for Canvas

By default, the context is acessible through ox.ctx. It should and could be better though.
Perhaps this?

ox.Shape('rectangle', {
  x: 100, y: 100, w: 100, h: 100, fill: "lightblue"
});

or this?

ox.fillStyle('lightblue').fillRect(100,100,100,100);

Tweening

There should be basic support for tweening properties.

Modularize sprite

Right now, if someone doesn't want the sprite entity, they are hosed. This should not be the case.

Add audio system

Right now it is just stubbed - need to actually implement it.

Basic site for 0.2 launch

It should highlight ox features by showcasing a simple demo of the engine. Doesn't need many pages. API docs should be hugely simple if at all available.

A simple and consistent API

Right now things don't seem too clear. I've been devising a new API that should make the developer's intention crystal clear and allow for a certain level of "self documenting code".

  • Scenes (Create, Set)
    ox.createScene
    ox.setScene
  • Entities
    ox.createEntity
    ox.removeEntity
    ox.spawnEntity

...

Offer extra functionality through plugins

I think the main engine should be kept as small as possible - some games don't need camera systems, some don't need particles, some don't need physics and so on.

ox should offer a clean and easy api to hook in plugins.

Official plugins should be developed and offered in a special repo, along with community made plugins.

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.