| 228 | } |
| 229 | |
| 230 | PhysicsBody* PhysicsBody::createEdgeSegment(const Vec2& a, |
| 231 | const Vec2& b, |
| 232 | const PhysicsMaterial& material, |
| 233 | float border /* = 1*/) |
| 234 | { |
| 235 | PhysicsBody* body = new PhysicsBody(); |
| 236 | if (body->init()) |
| 237 | { |
| 238 | body->addShape(PhysicsShapeEdgeSegment::create(a, b, material, border)); |
| 239 | body->setDynamic(false); |
| 240 | body->autorelease(); |
| 241 | return body; |
| 242 | } |
| 243 | |
| 244 | AX_SAFE_DELETE(body); |
| 245 | return nullptr; |
| 246 | } |
| 247 | |
| 248 | PhysicsBody* PhysicsBody::createEdgeBox(const Vec2& size, |
| 249 | const PhysicsMaterial& material, |
nothing calls this directly
no test coverage detected