public void Clone(ContactEdge contactEdge)
        {
            this.contactKey = contactEdge.Contact.Key;
            this.body       = contactEdge.Other;

            this.contactEdgeCloneKey.Set(contactKey, body.BodyId);

            if (contactEdge.Next != null)
            {
                this.nextEdge.Set(contactEdge.Next.Contact.Key, contactEdge.Next.Other.BodyId);
            }
            else
            {
                this.nextEdge.Set(this.nextEdge.contactKey, -1);
            }

            if (contactEdge.Prev != null)
            {
                this.previousEdge.Set(contactEdge.Prev.Contact.Key, contactEdge.Prev.Other.BodyId);
            }
            else
            {
                this.previousEdge.Set(this.previousEdge.contactKey, -1);
            }
        }
Exemplo n.º 2
0
 public void Set(ContactCloneKey contactKey, int bodyId)
 {
     this.contactKey = contactKey;
     this.bodyId     = bodyId;
 }
Exemplo n.º 3
0
 public ContactEdgeCloneKey(ContactCloneKey contactKey, int bodyId)
 {
     this.contactKey = contactKey;
     this.bodyId     = bodyId;
 }