Exemplo n.º 1
0
    protected Vector3 LookDirection;            // 캐릭터 시선방향

    //Use this for initialization
    void Awake()
    {
        Joystick   = FindObjectOfType <FixedJoystick>();   // 왼쪽 조이스틱 스크립트 접근
        TouchField = FindObjectOfType <FixedTouchField>(); // 터치화면 스크립트 접근
        ButtonA    = FindObjectOfType <FixedButtonA>();    // 공격버튼 스크립트 접근
        ButtonB    = FindObjectOfType <FixedButtonB>();    // 점프버튼 스크립트 접근
        Player     = GetComponent <TestPlayer>();          // 플레이어 스크립트 접근
    }
Exemplo n.º 2
0
    protected Vector3 LookDirection;            // 캐릭터 시선방향

    //Use this for initialization
    void Awake()
    {
        Joystick   = FindObjectOfType <FixedJoystick>();   // 왼쪽 조이스틱 스크립트 접근
        TouchField = FindObjectOfType <FixedTouchField>(); // 터치화면 스크립트 접근
        ButtonA    = FindObjectOfType <FixedButtonA>();    // 공격버튼 스크립트 접근
        ButtonB    = FindObjectOfType <FixedButtonB>();    // 점프버튼 스크립트 접근
        ButtonR    = FindObjectOfType <FixedButtonR>();    // 달리기/ONOFF 스크립트 접근
        ButtonX    = FindObjectOfType <FixedButtonX>();    // 줍기버튼접근
        ButtonDrop = FindObjectOfType <FixedButtonDrop>(); // 던지기 버튼 접근
        ButtonAim  = FindObjectOfType <FixedButtonAim>();  // 던지기 버튼 접근
        AimPoint   = FindObjectOfType <AimPoint>();        //조준점

        ButtonAim.gameObject.SetActive(false);
        AimPoint.gameObject.SetActive(false);


        ButtonWalk = FindObjectOfType <ButtonWalk>();
        Player     = GetComponent <Player>(); // 플레이어 스크립트 접근
        buttonWalk = GameObject.Find("Joystick/FixedJoystick/ButtonWalk");
    }