| 234 | } |
| 235 | |
| 236 | void CPHElement::SetTransform(const Fmatrix& m0) |
| 237 | { |
| 238 | VERIFY2(_valid(m0), "invalid_form_in_set_transform"); |
| 239 | Fvector mc; |
| 240 | CPHGeometryOwner::get_mc_vs_transform(mc, m0); |
| 241 | VERIFY_BOUNDARIES2(mc, phBoundaries, PhysicsRefObject(), "mass center in set transform"); |
| 242 | dBodySetPosition(m_body, mc.x, mc.y, mc.z); |
| 243 | Fmatrix33 m33; |
| 244 | m33.set(m0); |
| 245 | dMatrix3 R; |
| 246 | PHDynamicData::FMX33toDMX(m33, R); |
| 247 | dBodySetRotation(m_body, R); |
| 248 | CPHDisablingFull::Reinit(); |
| 249 | |
| 250 | VERIFY2(dBodyGetPosition(m_body), "not valide safe position"); |
| 251 | VERIFY2(dBodyGetLinearVel(m_body), "not valide safe velocity"); |
| 252 | m_flags.set(flUpdate, TRUE); |
| 253 | m_shell->spatial_move(); |
| 254 | } |
| 255 | |
| 256 | void CPHElement::getQuaternion(Fquaternion& quaternion) |
| 257 | { |
nothing calls this directly
no test coverage detected