Example #1
0
 public void Awake()
 {
     if (m_instance == null)
     {
         m_instance = this;
     }
 }
Example #2
0
    // This state predetermines all of the trial's task parameters,
    // resets task objects, and prepares the cue.

    // OnStateEnter is called when a transition starts and the state machine starts to evaluate this state
    override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
    {
        WisconsinExperimentController expControl = WisconsinExperimentController.m_instance;

        expControl.ResetObjects();   // Positions, colors, and visibility.
        expControl.PrepareTrial();
        expControl.PrepareTargets();
    }
Example #3
0
    // This is the parent state for this task.
    // Transition from this state to the first trial when the experimenter clicks on "Trial Begin".

    // OnStateEnter is called when a transition starts and the state machine starts to evaluate this state
    override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
    {
        WisconsinExperimentController expControl = WisconsinExperimentController.m_instance;

        expControl.PrepareAllTrials();
    }