1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-30 03:45:32 +00:00

Merge pull request #3074 from akortunov/warnfix

Declare separate constructors with const reference and rvalue arguments for OscillatingRecastMeshObject
This commit is contained in:
Roman Siromakha 2021-04-28 17:15:29 +02:00 committed by GitHub
commit 68ddde84fe
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 2 deletions

View file

@ -4,13 +4,20 @@
namespace DetourNavigator
{
OscillatingRecastMeshObject::OscillatingRecastMeshObject(RecastMeshObject impl, std::size_t lastChangeRevision)
OscillatingRecastMeshObject::OscillatingRecastMeshObject(RecastMeshObject&& impl, std::size_t lastChangeRevision)
: mImpl(std::move(impl))
, mLastChangeRevision(lastChangeRevision)
, mAabb(BulletHelpers::getAabb(mImpl.getShape(), mImpl.getTransform()))
{
}
OscillatingRecastMeshObject::OscillatingRecastMeshObject(const RecastMeshObject& impl, std::size_t lastChangeRevision)
: mImpl(impl)
, mLastChangeRevision(lastChangeRevision)
, mAabb(BulletHelpers::getAabb(mImpl.getShape(), mImpl.getTransform()))
{
}
bool OscillatingRecastMeshObject::update(const btTransform& transform, const AreaType areaType,
std::size_t lastChangeRevision)
{

View file

@ -12,7 +12,8 @@ namespace DetourNavigator
class OscillatingRecastMeshObject
{
public:
explicit OscillatingRecastMeshObject(RecastMeshObject impl, std::size_t lastChangeRevision);
explicit OscillatingRecastMeshObject(RecastMeshObject&& impl, std::size_t lastChangeRevision);
explicit OscillatingRecastMeshObject(const RecastMeshObject& impl, std::size_t lastChangeRevision);
bool update(const btTransform& transform, const AreaType areaType, std::size_t lastChangeRevision);