コード例 #1
0
 static void Init()
 {
     foreach (ESignalType button in Enum.GetValues(typeof(ESignalType)))
     {
         if (button != ESignalType.None)
         {
             buttonActions[button]    = new UIButtonClick();
             buttonActionsOne[button] = new UIButtonClickOne();
             buttonActionsTwo[button] = new UIButtonClickTwo();
         }
     }
 }
コード例 #2
0
    //testing to make the cubes disapear onece the player has passed trough it

    // Use this for initialization
    void Start()
    {
        Player = GameObject.FindGameObjectWithTag("Player");                //get the player

        btnInstance = GetComponent <UIButtonClick>();                       //get the list of commands

        path = GameObject.FindObjectOfType(typeof(PathNodes)) as PathNodes; //to get the nodes to move the character

        nodes = path.getNodes();                                            //return the list of nodes

        playerCollider = Player.GetComponent <CapsuleCollider>();
    }
コード例 #3
0
    // Use this for initialization
    void Start()
    {
        //Mairim
        Button submitBtn = submit.GetComponent <Button>();

        submitBtn.onClick.AddListener(AddCommandsToCommandList);

        //Record original position of the player
        originalPos = player.transform.localPosition;
        originalRot = player.transform.localRotation;

        //Create instance of the two player handler classes
        commandProcessor = GetComponent <UIButtonClick>();
        commandExecution = GetComponent <UIPlayCommand1> ();

        attempt = 0;
    }
コード例 #4
0
    // Use this for initialization
    void Start()
    {
        floormask = LayerMask.GetMask("Floor");

        Player = GameObject.FindGameObjectWithTag("Player");
        // playerRigidbody = GetComponent<Rigidbody>();

        //Button btn = playButton.GetComponent<Button>();
        btnInstance   = GetComponent <UIButtonClick>();
        whileInstance = GetComponent <WhileCommand>();
        spawn         = GetComponent <SpawnInstructions>();
        //btn.onClick.AddListener(TaskOnClick);

        //store original position of player
        //originalPos = player.transform.position;
        isRotating     = false;
        targetAngle    = Player.transform.eulerAngles.y;
        targetRotation = Quaternion.AngleAxis(targetAngle, Vector3.up);
    }
コード例 #5
0
    // Use this for initialization
    void Start()
    {
        //Mairim
        Button submitBtn = submit.GetComponent <Button>();

        submitBtn.onClick.AddListener(AddCommandsToCommandList);

        //Button continueBtn = cont.GetComponent<Button>();
        //continueBtn.onClick.AddListener (ClearAllC);

        //Record original position of the player
        originalPos = player.transform.localPosition;
        originalRot = player.transform.localRotation;

        //Create instance of the two player handler classes
        commandProcessor = GetComponent <UIButtonClick> ();
        commandExecution = GetComponent <UIPlayCommand1> ();
        bl = GetComponent <BlocksRotator>();

        attempt       = 0;
        submitClicked = false;
        //DeactivateControls ();
    }