void Update() { foreach (var jb in JPhysics.OverlapMesh(col.Shape, transform.position, transform.rotation)) { Debug.Log(jb.name); } }
private void OnEnable() { TransformToBody(); JPhysics.AddBody(body); JPhysics.AddConstraint(controller); }
private void OnEnable() { Body.Shape = Shape; Body.Tag = this; TransformToBody(); JPhysics.AddBody(Body); }
private void Update() { var ray = Camera.main.ScreenPointToRay(Input.mousePosition); var hit = JPhysics.Raycast(ray); if (hit != null) { if (Input.GetMouseButtonDown(2)) { Dig(hit.Point); } } }
private void OnDisable() { JPhysics.RemoveBody(body); JPhysics.RemoveConstraint(controller); }
private void OnDisable() { JPhysics.RemoveBody(Body); }