Esempio n. 1
0
    private void CreateNewHook()
    {
        timerRope        = 0;
        isPressingButton = true;
        rb.gravityScale  = PM.gravityHooked;
        currentTarget    = PM.GetCurrentGrabbableObject();
        previousVelocity = rb.velocity.magnitude;
        alreadySpinned   = false;
        if (currentTarget != null)
        {
            if (PM.playerHooks == Hooks.HOOK_SPRING)
            {
                CreateSpring(currentTarget);
            }
            else
            {
                CreateRope(currentTarget);
            }



            EM.CreateCameraShake(0.05f);
        }

        /*else
         * {
         *  DoAirPower();
         * }*/
        /*PM.SetNewPlayerState(States.STATE_MAGNET);
         * magnetTarget = target;*/
    }