Physics3D/RigidBody3D: Rename [Get|Set]Velocity to [Get|Set]LinearVelocity
This commit is contained in:
@@ -146,6 +146,20 @@ namespace Ndk
|
||||
return m_object->GetLinearDamping();
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the linear velocity of the physics object
|
||||
* \return Linear velocity of the object
|
||||
*
|
||||
* \remark Produces a NazaraAssert if the physics object is invalid
|
||||
*/
|
||||
|
||||
inline Nz::Vector3f PhysicsComponent3D::GetLinearVelocity() const
|
||||
{
|
||||
NazaraAssert(m_object, "Invalid physics object");
|
||||
|
||||
return m_object->GetLinearVelocity();
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the mass of the physics object
|
||||
* \return Mass of the object
|
||||
@@ -218,20 +232,6 @@ namespace Ndk
|
||||
return m_object->GetRotation();
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the velocity of the physics object
|
||||
* \return Velocity of the object
|
||||
*
|
||||
* \remark Produces a NazaraAssert if the physics object is invalid
|
||||
*/
|
||||
|
||||
inline Nz::Vector3f PhysicsComponent3D::GetVelocity() const
|
||||
{
|
||||
NazaraAssert(m_object, "Invalid physics object");
|
||||
|
||||
return m_object->GetVelocity();
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Checks whether the auto sleep is enabled
|
||||
* \return true If it is the case
|
||||
@@ -328,6 +328,20 @@ namespace Ndk
|
||||
m_object->SetLinearDamping(damping);
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Sets the linear velocity of the physics object
|
||||
*
|
||||
* \param velocity New linear velocity of the object
|
||||
*
|
||||
* \remark Produces a NazaraAssert if the physics object is invalid
|
||||
*/
|
||||
inline void PhysicsComponent3D::SetLinearVelocity(const Nz::Vector3f& velocity)
|
||||
{
|
||||
NazaraAssert(m_object, "Invalid physics object");
|
||||
|
||||
m_object->SetLinearVelocity(velocity);
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Sets the mass of the physics object
|
||||
*
|
||||
@@ -389,21 +403,6 @@ namespace Ndk
|
||||
m_object->SetRotation(rotation);
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Sets the velocity of the physics object
|
||||
*
|
||||
* \param velocity Velocity of the object
|
||||
*
|
||||
* \remark Produces a NazaraAssert if the physics object is invalid
|
||||
*/
|
||||
|
||||
inline void PhysicsComponent3D::SetVelocity(const Nz::Vector3f& velocity)
|
||||
{
|
||||
NazaraAssert(m_object, "Invalid physics object");
|
||||
|
||||
m_object->SetVelocity(velocity);
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the underlying physics object
|
||||
* \return A reference to the physics object
|
||||
|
||||
Reference in New Issue
Block a user