예제 #1
0
        /// <summary>
        /// Copies data from native instance to this wire.
        /// </summary>
        /// <param name="native">Native instance.</param>
        public void RestoreLocalDataFrom(agxWire.Wire native)
        {
            if (native == null)
            {
                return;
            }

            Radius = System.Convert.ToSingle(native.getRadius());
            ResolutionPerUnitLength = System.Convert.ToSingle(native.getResolutionPerUnitLength());
            ScaleConstant           = System.Convert.ToSingle(native.getParameterController().getScaleConstant());
        }
예제 #2
0
        /// <summary>
        /// Copies data from native instance to this wire.
        /// </summary>
        /// <param name="native">Native instance.</param>
        public void RestoreLocalDataFrom(agxWire.Wire native)
        {
            if (native == null)
            {
                return;
            }

            Radius = System.Convert.ToSingle(native.getRadius());
            ResolutionPerUnitLength = System.Convert.ToSingle(native.getResolutionPerUnitLength());
            ScaleConstant           = System.Convert.ToSingle(native.getParameterController().getScaleConstant());

            // Is the wire enabled/active?
            gameObject.SetActive(native.isEnabled());
        }