mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-03 21:45:33 +00:00
Remove duplicate parameter.
This commit is contained in:
parent
8c6890c682
commit
12511778d1
3 changed files with 6 additions and 7 deletions
|
@ -244,7 +244,7 @@ namespace CSVRender
|
||||||
!QString(result.first.c_str()).contains(QRegExp("^Pathgrid")))
|
!QString(result.first.c_str()).contains(QRegExp("^Pathgrid")))
|
||||||
{
|
{
|
||||||
pos.z -= result.second;
|
pos.z -= result.second;
|
||||||
pos.z += 2; // arbitrary number, lift up slightly (maybe change the nif?)
|
pos.z += 1; // arbitrary number, lift up slightly (maybe change the nif?)
|
||||||
// FIXME: rather than just updating at the end, should
|
// FIXME: rather than just updating at the end, should
|
||||||
// consider providing visual feedback of terrain height
|
// consider providing visual feedback of terrain height
|
||||||
// while dragging the pathgrid point (maybe check whether
|
// while dragging the pathgrid point (maybe check whether
|
||||||
|
|
|
@ -267,7 +267,7 @@ namespace CSVWorld
|
||||||
}
|
}
|
||||||
|
|
||||||
std::pair<std::string, float> PhysicsSystem::distToGround(const Ogre::Vector3 &position,
|
std::pair<std::string, float> PhysicsSystem::distToGround(const Ogre::Vector3 &position,
|
||||||
Ogre::uint32 visibilityMask, const float limit, bool ignorePgPoint)
|
Ogre::uint32 visibilityMask, const float limit)
|
||||||
{
|
{
|
||||||
btVector3 _from, _to;
|
btVector3 _from, _to;
|
||||||
_from = btVector3(position.x, position.y, position.z);
|
_from = btVector3(position.x, position.y, position.z);
|
||||||
|
@ -275,8 +275,7 @@ namespace CSVWorld
|
||||||
|
|
||||||
bool ignoreHeightMap = !(visibilityMask & (Ogre::uint32)CSVRender::Element_Terrain);
|
bool ignoreHeightMap = !(visibilityMask & (Ogre::uint32)CSVRender::Element_Terrain);
|
||||||
bool ignoreObjects = !(visibilityMask & (Ogre::uint32)CSVRender::Element_Reference);
|
bool ignoreObjects = !(visibilityMask & (Ogre::uint32)CSVRender::Element_Reference);
|
||||||
bool ignorePathgrid = ignorePgPoint ||
|
bool ignorePathgrid = !(visibilityMask & (Ogre::uint32)CSVRender::Element_Pathgrid);
|
||||||
!(visibilityMask & (Ogre::uint32)CSVRender::Element_Pathgrid);
|
|
||||||
|
|
||||||
std::pair<std::string, float> result = std::make_pair("", -1);
|
std::pair<std::string, float> result = std::make_pair("", -1);
|
||||||
short mask = OEngine::Physic::CollisionType_Raycasting;
|
short mask = OEngine::Physic::CollisionType_Raycasting;
|
||||||
|
@ -303,7 +302,7 @@ namespace CSVWorld
|
||||||
return std::make_pair(result.first, limit*result.second);
|
return std::make_pair(result.first, limit*result.second);
|
||||||
}
|
}
|
||||||
|
|
||||||
// tries to find the distance to the "top" of the closest object
|
// tries to find the distance to the "top" of the closest object (ignores pathgrid points)
|
||||||
std::pair<std::string, float> PhysicsSystem::distToClosest(const Ogre::Vector3 &position,
|
std::pair<std::string, float> PhysicsSystem::distToClosest(const Ogre::Vector3 &position,
|
||||||
Ogre::uint32 visibilityMask, const float limit)
|
Ogre::uint32 visibilityMask, const float limit)
|
||||||
{
|
{
|
||||||
|
@ -311,7 +310,7 @@ namespace CSVWorld
|
||||||
|
|
||||||
std::pair<std::string, float> resDown =
|
std::pair<std::string, float> resDown =
|
||||||
distToGround(Ogre::Vector3(position.x, position.y, position.z+thickness),
|
distToGround(Ogre::Vector3(position.x, position.y, position.z+thickness),
|
||||||
visibilityMask, limit+thickness, true);
|
visibilityMask&(~CSVRender::Element_Pathgrid), limit+thickness);
|
||||||
|
|
||||||
if(resDown.first != "")
|
if(resDown.first != "")
|
||||||
return std::make_pair(resDown.first, resDown.second-thickness);
|
return std::make_pair(resDown.first, resDown.second-thickness);
|
||||||
|
|
|
@ -76,7 +76,7 @@ namespace CSVWorld
|
||||||
float mouseY, Ogre::SceneManager *sceneMgr, Ogre::Camera *camera);
|
float mouseY, Ogre::SceneManager *sceneMgr, Ogre::Camera *camera);
|
||||||
|
|
||||||
std::pair<std::string, float> distToGround(const Ogre::Vector3 &position,
|
std::pair<std::string, float> distToGround(const Ogre::Vector3 &position,
|
||||||
Ogre::uint32 visibilityMask, const float limit = 300000, bool ignorePgPoint = false);
|
Ogre::uint32 visibilityMask, const float limit = 300000);
|
||||||
|
|
||||||
std::pair<std::string, float> distToClosest(const Ogre::Vector3 &position,
|
std::pair<std::string, float> distToClosest(const Ogre::Vector3 &position,
|
||||||
Ogre::uint32 visibilityMask, const float limit = 100.0f);
|
Ogre::uint32 visibilityMask, const float limit = 100.0f);
|
||||||
|
|
Loading…
Reference in a new issue