示例#1
0
    public void SetStage_ObjectInHand()
    {
        originalScale = lastPickup.transform.localScale;
        lastPickup.getBody().isKinematic = true;
        lastPickup.transform.SetParent(hand, false);
        lastPickup.transform.SetPositionAndRotation(hand.position + hand.up * 0.1f + hand.forward * 0.1f, hand.rotation * inHandRotation);
        Vector3 scale = lastPickup.transform.localScale;

        lastPickup.transform.localScale = new Vector3(scale.x / hand.localScale.x, scale.y / hand.localScale.y, scale.z / hand.localScale.z);
    }