Esempio n. 1
0
    protected virtual void InformGameResultActions(GameProperties.GameState state)
    {
        if (emotionalModule != null)
        {
            //Fatima calls
            int currSpeakingPlayerId = gameManagerRef.GetCurrSpeakingPlayerId();
            if (state == GameProperties.GameState.VICTORY)
            {
                emotionalModule.Perceive(new Name[] {
                    EventHelper.PropertyChange("State(Game)", "GameEnd", name),
                    EventHelper.PropertyChange("Game(Result)", "Victory", name)
                });
            }
            else if (state == GameProperties.GameState.LOSS)
            {
                emotionalModule.Perceive(new Name[] {
                    EventHelper.PropertyChange("State(Game)", "GameEnd", name),
                    EventHelper.PropertyChange("Game(Result)", "Loss", name)
                });
            }

            if (currSpeakingPlayerId == id)
            {
                emotionalModule.Decide();
            }
            else
            {
                emotionalModule.GazeAt("Player");
            }
        }
    }
Esempio n. 2
0
 public override void InformGameResult(GameProperties.GameState state)
 {
     //base.InformRollDicesValue(invoker, maxValue, obtainedValue, speakingRobotId);
     if (!GameProperties.configurableProperties.isSimulation)
     {
         playerMonoBehaviourFunctionalities.StartCoroutine(DelayedInformGameResultActions(state, informGameResultDelay, true));
     }
     else
     {
         InformGameResultActions(state);
     }
 }
Esempio n. 3
0
    private IEnumerator DelayedInformGameResultActions(GameProperties.GameState state, float delay, bool isInformDelayed)
    {
        yield return(new WaitForSeconds(delay));

        InformGameResultActions(state);
    }
Esempio n. 4
0
 public override void InformGameResult(GameProperties.GameState state)
 {
 }
Esempio n. 5
0
 public abstract void InformGameResult(GameProperties.GameState state);