BulletSim: code rearrangement

integration
Robert Adams 2012-10-29 14:27:48 -07:00
parent 8c9e4c1f7b
commit bc43c7007d
2 changed files with 6 additions and 8 deletions

View File

@ -42,6 +42,12 @@ public abstract class BSConstraint : IDisposable
protected BulletConstraint m_constraint;
protected bool m_enabled = false;
public BulletBody Body1 { get { return m_body1; } }
public BulletBody Body2 { get { return m_body2; } }
public BulletConstraint Constraint { get { return m_constraint; } }
public abstract ConstraintType Type { get; }
public bool IsEnabled { get { return m_enabled; } }
public BSConstraint()
{
}
@ -64,12 +70,6 @@ public abstract class BSConstraint : IDisposable
}
}
public BulletBody Body1 { get { return m_body1; } }
public BulletBody Body2 { get { return m_body2; } }
public BulletConstraint Constraint { get { return m_constraint; } }
public abstract ConstraintType Type { get; }
public virtual bool SetLinearLimits(Vector3 low, Vector3 high)
{
bool ret = false;

View File

@ -143,8 +143,6 @@ public sealed class BSConstraintCollection : IDisposable
// Return 'true' if any constraints were destroyed.
public bool RemoveAndDestroyConstraint(BulletBody body1)
{
// return BulletSimAPI.RemoveConstraintByID(m_world.ID, obj.ID);
List<BSConstraint> toRemove = new List<BSConstraint>();
uint lookingID = body1.ID;
lock (m_constraints)