예제 #1
0
    public override void DoBeforeLeaving()
    {
        StopCoroutine("StartCrush");

        //rigidbody2D.isKinematic = false;
        anim.SetBool("isCrushing", false);
        ManagerPause.UnSubscribeOnPauseGame(OnPauseGame);
        ManagerPause.UnSubscribeOnResumeGame(OnResumeGame);

        rigidBody2D.gravityScale = store_GravityScale;
        useForceUp = false;
        isDown     = false;
        moveState.AddLayerToWhatisGround("Obstacle");

        puno.enabled         = false;
        punoRenderer.enabled = false;
        punoRenderer.color   = new Color(punoRenderer.color.r, punoRenderer.color.g, punoRenderer.color.b, 0);
        moveState.checkGround();
        moveState.CheckVelocityOffGround();
    }