Пример #1
0
 void Start()
 {
     _gameSetup    = FindObjectOfType <GameSetup>();
     score_counter = character.GetComponent <PlayerScoreCounter>();
     _anim         = character.GetComponent <Animator>();
     _uiController = FindObjectOfType <UIController>();
 }
Пример #2
0
    void Start()
    {
        animator      = GetComponent <Animator>();
        s_arrow       = a_container.GetComponent <ArrowScript>();
        score_counter = GetComponent <PlayerScoreCounter>();
        ui_controller = uIContainer.GetComponent <UIController>();

        stored_clip = new string[7];
    }
Пример #3
0
    void Start()
    {
        //_gameController = FindObjectOfType<GameController>();
        _playerScoreCounter = character.GetComponent <PlayerScoreCounter>();
        _gameSetup          = FindObjectOfType <GameSetup>();
        totalHealthUI.text  = _playerScoreCounter.maxHealth.ToString();
        healthBar.maxValue  = _playerScoreCounter.maxHealth;
        healthBar.value     = _playerScoreCounter.maxHealth;

        _difficultyChoice.onValueChanged.AddListener(delegate { ValueChangeCheck(); });
    }
Пример #4
0
    void Start()
    {
        _playerScoreCounter = _player.GetComponent <PlayerScoreCounter>();
        groundHit           = GetComponent <AudioSource>();

        _leftPointLight.color  = _colorProtector.color;
        _rightPointLight.color = _colorProtector.color;
        _spotLight.color       = _colorProtector.color;
        _ropeMaterial.color    = _colorProtector.color;
        _ropeMaterial.SetColor("_EmissionColor", _colorProtector.color);
        _comboSystem.startColor = _colorProtector.color;
    }
Пример #5
0
    private void OnTriggerEnter(Collider other)
    {
        if (other.CompareTag("Player"))
        {
            PlayerScoreCounter trigger = other.GetComponent <PlayerScoreCounter>();

            trigger.AddScore();

            Debug.Log("JEWEL");
            Destroy(gameObject);
        }
    }
Пример #6
0
    void Start()
    {
        if (m_StoreController == null)
        {
            InitializePurchasing();
        }

        if (_scoreCounter == null)
        {
            _scoreCounter = GetComponent <PlayerScoreCounter>();
        }
    }
Пример #7
0
    void Start()
    {
        _playerAnimator = character.GetComponent <Animator>();
        _uiController   = FindObjectOfType <UIController>();
        animator        = character.GetComponent <Animator>();
        counter         = character.GetComponent <PlayerScoreCounter>();
        r_animator      = rope.GetComponent <Animator>();
        a_renderer      = arrow.GetComponent <SpriteRenderer>();


        _animParamPlayer = _playerAnimator.GetFloat("anim_speed_player");
        _animParamRope   = r_animator.GetFloat("anim_speed_rope");

        direction = new float[6] {
            0f, 45f, 90f, 180f, 270f, 315f
        };
        UpdateAnimClipTimes();
        StartCoroutine("SwitchArrow");
    }