Will my game engine be compatible with physics engines?
- by Bane
My engine supports Scene handling, Cameras, and has a Renderer. Also, it has a class called Drawable, which has the position, the shape and the picture of an object. The picture property has width, height, rotation and a draw method. All game objects are supposed to inherit from this Drawable class, and are added to the Scene, along with a Map (collection of Tiles, that also inherit from Drawable), lights, and so on and so forth.
The shape property of a Drawable is a Polygon, a collection of user defined vertices around the position of a Drawable (this is a relative coordinate system, so [0, 0] is the position of the Drawable.
With this setup, will the users of my engine (probably only me) still be able to intergrate physics engines such as Box2DJS into their games?