private bool ContainmentDetectorTest_Helper(string point_name) { EditorSceneManager.OpenScene(sceneName); GameObject demisphere = GameObject.Find(demispherename); GameObject point = GameObject.Find(point_name); Vector3 center = point.transform.position; Vector4 position = new Vector4(center.x, center.y, center.z, 1.0f); ContainmentDetector detector = demisphere.GetComponent <ContainmentDetector>(); //Awake/update is not run by the test detector.collider = demisphere.GetComponent <MeshCollider>(); return(detector.GameObjectContains(position)); }
public void Set(GameObject staticModel, Transform referenceTransform) { this.staticModelContainmentDetector = staticModel.GetComponent <ContainmentDetector>(); this.referenceTransform = referenceTransform; }