Пример #1
0
 public void RemoveProvider(AComponentData provider)
 {
     providers.Remove(provider);
     if (provider is LeftFootData)
     {
         leftFoot = null;
     }
     else if (provider is RightFootData)
     {
         rightFoot = null;
     }
     else if (provider is HipData)
     {
         hipData = null;
     }
     else if (provider is LeftHandData)
     {
         leftHand = null;
     }
     else if (provider is RightHandData)
     {
         rightHand = null;
     }
     else if (provider is HeadData)
     {
         headData = null;
     }
 }
Пример #2
0
 public void AddProvider(AComponentData provider)
 {
     providers.Add(provider);
     if (provider is LeftFootData)
     {
         leftFoot = (LeftFootData)provider;
     }
     else if (provider is RightFootData)
     {
         rightFoot = (RightFootData)provider;
     }
     else if (provider is HipData)
     {
         hipData = (HipData)provider;
     }
     else if (provider is LeftHandData)
     {
         leftHand = (LeftHandData)provider;
     }
     else if (provider is RightHandData)
     {
         rightHand = (RightHandData)provider;
     }
     else if (provider is HeadData)
     {
         headData = (HeadData)provider;
     }
 }
Пример #3
0
 private void HandleHands(AComponentData hand)
 {
     if (hand == leftHand)
     {
         leftHandPosition = hand.Position();
         leftHandRotation = hand.Rotation();
     }
     else
     {
         rightHandPosition = hand.Position(); // rightHand.Position();
         rightHandRotation = hand.Rotation();
     }
 }
Пример #4
0
 private void HandleFeet(AComponentData foot)
 {
     if (foot == leftFoot)
     {
         leftFootPosition = foot.Position();
         leftFootRotation = foot.Rotation();
     }
     else
     {
         rightFootPosition = foot.Position();
         rightFootRotation = foot.Rotation();
     }
 }
Пример #5
0
 private void HandleHead(AComponentData head)
 {
     headPosition = head.Position();
     headRotation = head.Rotation();
 }
Пример #6
0
 private void HandleHip(AComponentData hip)
 {
     hipPosition = hip.Position();
     hipRotation = hip.Rotation();
 }