Guest User

Untitled

a guest
Jan 18th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4.  
  5. public class PickUp : MonoBehaviour {
  6.  
  7. public Transform target;
  8.  
  9. void Update () {
  10.  
  11. }
  12.  
  13. void onMouseDown() {
  14. this.transform.position = target.position;
  15. this.transform.parent = GameObject.Find ("FirstPersonCharacter").transform;
  16. }
  17.  
  18. void onMouseUp() {
  19. this.transform.parent = null;
  20. }
  21. }
Add Comment
Please, Sign In to add comment