| 469 | } |
| 470 | |
| 471 | void NpShape::setContactOffset(PxReal contactOffset) |
| 472 | { |
| 473 | NP_WRITE_CHECK(getOwnerScene()); |
| 474 | |
| 475 | PX_CHECK_AND_RETURN(PxIsFinite(contactOffset), "PxShape::setContactOffset: invalid float"); |
| 476 | PX_CHECK_AND_RETURN((contactOffset >= 0.0f && contactOffset > mShape.getRestOffset()), "PxShape::setContactOffset: contactOffset should be positive, and greater than restOffset!"); |
| 477 | PX_CHECK_AND_RETURN(isWritable(), "PxShape::setContactOffset: shared shapes attached to actors are not writable."); |
| 478 | |
| 479 | mShape.setContactOffset(contactOffset); |
| 480 | } |
| 481 | |
| 482 | PxReal NpShape::getContactOffset() const |
| 483 | { |
no test coverage detected