1using System.Collections;
2using System.Collections.Generic;
4using NaughtyAttributes;
13 private Transform originalParent;
28 Ray ray =
new Ray(@
from.position,
to.position - @
from.position);
29 Debug.DrawLine(ray.origin, ray.GetPoint(Vector3.Distance(@
from.position,
to.position)),
Color.green, 3);
30 GameObject hit =
pb_HandleUtility.
ObjectRaycast(ray,
pb_Scene.
Children(), Vector3.Distance(@
from.position,
to.position),
true,
new List<GameObject>() { from.gameObject, to.gameObject, from.transform.parent.gameObject, to.transform.parent.gameObject });
39 originalParent = tcd.transform.parent;
40 tcd.gameObject.transform.SetParent(transform,
true);
UnityEngine.UI.Button Button
static DobotGrabber instance
static GameObject ObjectRaycast(Ray ray, IEnumerable< GameObject > objects, bool ignoreSelection=false)
static List< GameObject > Children()
static void SetStatic(GameObject go)
static void SetInteractable(GameObject go, bool isKinematic=true)