コード例 #1
0
ファイル: Player.cs プロジェクト: Airwaffle/ludumdare48
    public void ToggleRope(bool newRope)
    {
        if (newRope == roped)
        {
            return;
        }

        if (newRope)
        {
            Debug.Log("StartRope");
        }
        else
        {
            Debug.Log("EndRope");
        }

        roped = newRope;
        rope.gameObject.SetActive(roped);
        if (roped)
        {
            rope.Create(world);
        }
        else
        {
            rope.End();
        }
    }