1.创建有个有物理特性的场景
auto s = Sence::createWithPhysics();
s->getPhysicsWorld()->setGravity(Vec2(0, -50));
auto l = Layer::create();
s->addChild(l);
2.设置物理世界的边界
auto edge = Node::create();
setContentSize(Size());
setPhysicsBody(PyhsicsBody::createEdgeBox(Size()));
edge->setPosition(Point());
3.添加英雄并设置英雄的刚体属性
auto sp = Sprite::create();
sp->setContentSize(Size());
SetPyhsicsBody(PhysicsBody::createBox(Size()));