summaryrefslogtreecommitdiff
path: root/indra/newview/llpathfindinglinksetlist.cpp
diff options
context:
space:
mode:
authorWilliam Todd Stinson <stinson@lindenlab.com>2012-02-25 22:27:06 -0800
committerWilliam Todd Stinson <stinson@lindenlab.com>2012-02-25 22:27:06 -0800
commit9b06300e2c94eae83a29637073f65d4ffc73bf6d (patch)
tree8d109a1e072f066fa2739b063291c05a95983f8e /indra/newview/llpathfindinglinksetlist.cpp
parent8bfb24373b429b752d4b2b1ca6452f0eb755e383 (diff)
PATH-292: Adding the ability to view and edit pathfinding attributes of the terrain.
Diffstat (limited to 'indra/newview/llpathfindinglinksetlist.cpp')
-rw-r--r--indra/newview/llpathfindinglinksetlist.cpp30
1 files changed, 25 insertions, 5 deletions
diff --git a/indra/newview/llpathfindinglinksetlist.cpp b/indra/newview/llpathfindinglinksetlist.cpp
index 7facf88c40..57febbf0f2 100644
--- a/indra/newview/llpathfindinglinksetlist.cpp
+++ b/indra/newview/llpathfindinglinksetlist.cpp
@@ -83,20 +83,40 @@ void LLPathfindingLinksetList::update(const LLPathfindingLinksetList &pUpdateLin
}
}
-LLSD LLPathfindingLinksetList::encodeAlteredFields(LLPathfindingLinkset::ELinksetUse pLinksetUse, S32 pA, S32 pB, S32 pC, S32 pD) const
+LLSD LLPathfindingLinksetList::encodeObjectFields(LLPathfindingLinkset::ELinksetUse pLinksetUse, S32 pA, S32 pB, S32 pC, S32 pD) const
{
LLSD listData;
for (LLPathfindingLinksetMap::const_iterator linksetIter = begin(); linksetIter != end(); ++linksetIter)
{
const LLPathfindingLinksetPtr linksetPtr = linksetIter->second;
- LLSD linksetData = linksetPtr->encodeAlteredFields(pLinksetUse, pA, pB, pC, pD);
- if (!linksetData.isUndefined())
+ if (!linksetPtr->isTerrain())
{
- const std::string& uuid(linksetIter->first);
- listData[uuid] = linksetData;
+ LLSD linksetData = linksetPtr->encodeAlteredFields(pLinksetUse, pA, pB, pC, pD);
+ if (!linksetData.isUndefined())
+ {
+ const std::string& uuid(linksetIter->first);
+ listData[uuid] = linksetData;
+ }
}
}
return listData;
}
+
+LLSD LLPathfindingLinksetList::encodeTerrainFields(LLPathfindingLinkset::ELinksetUse pLinksetUse, S32 pA, S32 pB, S32 pC, S32 pD) const
+{
+ LLSD terrainData;
+
+ for (LLPathfindingLinksetMap::const_iterator linksetIter = begin(); linksetIter != end(); ++linksetIter)
+ {
+ const LLPathfindingLinksetPtr linksetPtr = linksetIter->second;
+ if (linksetPtr->isTerrain())
+ {
+ terrainData = linksetPtr->encodeAlteredFields(pLinksetUse, pA, pB, pC, pD);
+ break;
+ }
+ }
+
+ return terrainData;
+}