| 347 | } |
| 348 | |
| 349 | void NpActor::addConstraintsToSceneInternal() |
| 350 | { |
| 351 | if(!mConnectorArray) |
| 352 | return; |
| 353 | |
| 354 | NpConnectorIterator iter = getConnectorIterator(NpConnectorType::eConstraint); |
| 355 | while (PxBase* ser = iter.getNext()) |
| 356 | { |
| 357 | NpConstraint* c = static_cast<NpConstraint*>(ser); |
| 358 | PX_ASSERT(c->getNpScene() == NULL); |
| 359 | |
| 360 | c->markDirty(); // PT: "temp" fix for crash when removing/re-adding jointed actor from/to a scene |
| 361 | |
| 362 | NpScene* s = c->getSceneFromActors(); |
| 363 | if (s) |
| 364 | { |
| 365 | s->addToConstraintList(*c); |
| 366 | s->getScene().addConstraint(c->getScbConstraint()); |
| 367 | } |
| 368 | } |
| 369 | } |
| 370 | |
| 371 | |
| 372 |
nothing calls this directly
no test coverage detected