Exemplo n.º 1
0
        public override void AddModel(IHandModel model)
        {
            // Check is Remote or not
            if (model.isRemote != this.IsRemote_)
            {
                return;
            }

            if (handModels == null)
            {
                handModels = new List <IHandModel>();
                // 有Bug????
            }
            handModels.Add(model);
            if (model.GetLeapHand() == null)
            {
                model.SetLeapHand(MostRecentHand);
                model.InitHand();
                model.BeginHand();
                model.UpdateHand();
            }
            else
            {
                model.SetLeapHand(MostRecentHand);
                model.BeginHand();
            }
        }
Exemplo n.º 2
0
    public override void AddModel(IHandModel model) {
      if (handModels == null) {
        handModels = new List<IHandModel>();
      }
      handModels.Add(model);
      if (model.GetLeapHand() == null) {
        model.SetLeapHand(MostRecentHand);
        model.InitHand();
        model.BeginHand();
        model.UpdateHand();
      }
      else {
        model.SetLeapHand(MostRecentHand);
        model.BeginHand();

      }
    }
Exemplo n.º 3
0
 public override void AddModel(IHandModel model)
 {
     if (handModels == null)
     {
         handModels = new List <IHandModel>();
     }
     handModels.Add(model);
     if (model.GetLeapHand() == null)
     {
         model.SetLeapHand(MostRecentHand);
         model.InitHand();
         model.BeginHand();
         model.UpdateHand();
     }
     else
     {
         model.SetLeapHand(MostRecentHand);
         model.BeginHand();
     }
 }
Exemplo n.º 4
0
 /** Calls Updates in IHandModels that are part of this HandRepresentation */
 public override void UpdateRepresentation(Hand hand, ModelType modelType)
 {
     handModel.SetLeapHand(hand);
     handModel.UpdateHand();
 }