Esempio n. 1
0
 public void Init(PathGame pathGame)
 {
     this.pathGame = pathGame;
     parameters    = pathGame.parameters;
     foreach (Param p in parameters)
     {
         p.pValue = 0;
         if (ChainPlayer)
         {
             p.OnParamActivation += ChainPlayer.ActivateStateFromParam;
         }
         OnParamChanging.Invoke(p);
     }
 }
Esempio n. 2
0
 public void SetParam(string name, float value, bool check = true)
 {
     if (check)
     {
         parameters.First(x => x.name == name).PValue = value;
     }
     else
     {
         parameters.First(x => x.name == name).pValue = value;
     }
     foreach (ConditionChange pch in parameters.First(x => x.name == name).autoActivatedChangesGUIDS)
     {
         if (ExpressionSolver.CalculateBool(pch.condition.conditionString, pch.condition.Parameters))
         {
             foreach (ParamChanges pcha in pch.changes)
             {
                 SetParam(pcha.aimParam.name, pcha.changeString, pcha.parameters, false);
             }
         }
     }
     OnParamChanging.Invoke(parameters.First(x => x.name == name));
 }
Esempio n. 3
0
 public void CheckParam(string name)
 {
     OnParamChanging.Invoke(parameters.First(x => x.name == name));
 }