예제 #1
0
 public void Drop()
 {
     if (_state != DropStates.Falling)
     {
         _state = DropStates.Falling;
         StartCoroutine("DropSequence");
     }
 }
예제 #2
0
    private void Update()
    {
        if (!_stal.Active() || !_stal.UnstableStalactite)
        {
            return;
        }

        if ((_playerBody.position.x + 8f > transform.position.x) && _state == DropStates.None && _playerControl.ThePlayer.IsAlive())
        {
            _state = DropStates.Shaking;
            StartCoroutine("Shake");
        }

        if (!_playerControl)
        {
            return;
        }                                // Editor clumsy has no player control
        if (!_playerControl.ThePlayer.IsAlive() && _state == DropStates.Shaking)
        {
            _state = DropStates.None;
        }
    }
예제 #3
0
 public void NewStalactite()
 {
     _state = DropStates.None;
     StopAllCoroutines();
     TriggerSprite.enabled = Toolbox.Instance.Debug && _stal.UnstableStalactite;
 }