public void UpdateInstance() { INTERACTION_TRANSFORM transform = new INTERACTION_TRANSFORM(); transform.position = Vector3.one.ToCVector(); transform.rotation = Quaternion.identity.ToCQuaternion(); transform.wallTime = 0; INTERACTION_UPDATE_SHAPE_INFO info = new INTERACTION_UPDATE_SHAPE_INFO(); info.angularAcceleration = Vector3.zero.ToCVector(); info.angularVelocity = Vector3.zero.ToCVector(); info.linearAcceleration = Vector3.zero.ToCVector(); info.linearVelocity = Vector3.zero.ToCVector(); InteractionC.UpdateShapeInstance(ref _scene, ref transform, ref info, ref _shapeInstanceHandle); }
protected virtual void updateInteractionRepresentations() { var active = _activityManager.ActiveBehaviours; for (int i = 0; i < active.Count; i++) { IInteractionBehaviour interactionBehaviour = active[i]; try { INTERACTION_SHAPE_INSTANCE_HANDLE shapeInstanceHandle = interactionBehaviour.ShapeInstanceHandle; INTERACTION_UPDATE_SHAPE_INFO updateInfo; INTERACTION_TRANSFORM updateTransform; interactionBehaviour.GetInteractionShapeUpdateInfo(out updateInfo, out updateTransform); InteractionC.UpdateShapeInstance(ref _scene, ref updateTransform, ref updateInfo, ref shapeInstanceHandle); } catch (Exception e) { _activityManager.NotifyMisbehaving(interactionBehaviour); Debug.LogException(e); } } }