Esempio n. 1
0
 public static BSShape GetReference(BSScene physicsScene)
 {
     // Base compound shapes are not shared so this returns a raw shape.
     // A built compound shape can be reused in linksets.
     BSShapeCompound ret = new BSShapeCompound(CreatePhysicalCompoundShape(physicsScene));
     CompoundShapes.Add(ret.AddrString, ret);
     return ret;
 }
Esempio n. 2
0
 public static bool TryGetCompoundByPtr(BulletShape pShape, out BSShapeCompound outCompound)
 {
     lock (CompoundShapes)
     {
         string addr = pShape.AddrString;
         return CompoundShapes.TryGetValue(addr, out outCompound);
     }
 }