Structure
structure of orbs js and how you should structure your project
The structure of orbs js is simple with each sprite, image, scene, renderer, script, vector being an object or also known as object oriented.
There are multiple objects at your disposal each having small and large functions that can save you time during development.
Another main feature of orbs js is its values system which allows you to choose values, reuse values, not type inverted commas and no misspelling. An example might be you need to define 'down'
in your code for mouse button down and your collision detection also needs it, instead of writing the word 'down'
all you need is to use the variable down, this also can be used to e consistent with the engine and cause less errors, but now a days this method adds a lot of dead weight to the code base and might be discontinued in the future.
Your Project Structure
Your project structure should be simple with importing values and functions in the top, setting up render and scene next and adding any images before rendering, a cool feature in orbs is the css to make your project full screen with this (sorry for no docs on this coming later), then creating and defining objects and adding to scene, lastly attaching scene to renderer and staring render cycle.
Last updated