Trying to integrate Box2D without inheritance of cocos2d::Node

I tried to create the component class to integrate Box2D without either using PhysicsSprite or inheritaton of cocos2d::Node.

  • Attach the physics body to a Sprite by adding B2NodeComponent.
  • Maybe able to define multiple independent physics layer (for what ?).
  • Translating the physics position and rotation with simply setting owner node’s position and rotation.
  • Sorry for commenting in Japanese. I’ll rewrite to English sooner or later.
  • If there is any idea for simplification, optimization, multi-threading or improvements, tell me please…

Why is using Node an issue for you?