コード例 #1
0
    // Use this for initialization
    void Start()
    {
        if (walkingType == WalkingMethod.RotatePlanet)
        {
            oldPos = player.transform.position;
        }
        else if (walkingType == WalkingMethod.RotatePlayer)
        {
            oldPos = player.transform.localPosition;
        }

        pm            = this.gameObject.GetComponent <PossessionMechanic> ();
        thisRigidBody = this.GetComponent <Rigidbody> ();
    }
コード例 #2
0
 void Start()
 {
     //get myself first
     NPC = this.transform.parent.gameObject;
     pm  = GameObject.Find("CamContainer").GetComponent <PossessionMechanic> ();
 }