summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerobject.cpp
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2010-10-20 14:39:28 -0500
committerDave Parks <davep@lindenlab.com>2010-10-20 14:39:28 -0500
commit1ca35bb30fa18e2d39aa06247b4478740d82d798 (patch)
tree2624f75a2ecd6408e116d1c9f17d19d4fefe12cc /indra/newview/llviewerobject.cpp
parent7be4856fde3a2b9e2caed4edf6bf65b55aea78b3 (diff)
parent187716a4ee9019b0133de865d9ede3c3abc3cc5b (diff)
merge
Diffstat (limited to 'indra/newview/llviewerobject.cpp')
-rw-r--r--indra/newview/llviewerobject.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp
index 870dd74fc5..9dc3cb9ce1 100644
--- a/indra/newview/llviewerobject.cpp
+++ b/indra/newview/llviewerobject.cpp
@@ -238,6 +238,7 @@ LLViewerObject::LLViewerObject(const LLUUID &id, const LLPCode pcode, LLViewerRe
mPhysicsCost(0.f),
mLinksetPhysicsCost(0.f),
mCostStale(true),
+ mPhysicsShapeUnknown(true),
mAttachmentItemID(LLUUID::null)
{
if (!is_global)
@@ -5186,6 +5187,7 @@ BOOL LLViewerObject::setFlags(U32 flags, BOOL state)
void LLViewerObject::setPhysicsShapeType(U8 type)
{
+ mPhysicsShapeUnknown = false;
mPhysicsShapeType = type;
}
@@ -5209,6 +5211,17 @@ void LLViewerObject::setPhysicsRestitution(F32 restitution)
mPhysicsRestitution = restitution;
}
+U8 LLViewerObject::getPhysicsShapeType() const
+{
+ if (mPhysicsShapeUnknown)
+ {
+ mPhysicsShapeUnknown = false;
+ gObjectList.updatePhysicsFlags(this);
+ }
+
+ return mPhysicsShapeType;
+}
+
void LLViewerObject::applyAngularVelocity(F32 dt)
{
//do target omega here