public static UnityLightType GetPatchApplied(this LightType _this, MRELightType value) { var lightType = (UnityLightType)Enum.Parse(typeof(UnityLightType), value.ToString()); if (!_this.Equals(lightType)) { _this = lightType; } return(_this); }
/* * public static UnityCollisionDetectionMode GetPatchApplied(this UnityCollisionDetectionMode _this, MRECollisionDetectionMode value) * { * var detectionMode = (UnityCollisionDetectionMode)Enum.Parse(typeof(UnityCollisionDetectionMode), value.ToString()); * if (!_this.Equals(detectionMode)) * { * _this = detectionMode; * } * * return _this; * } */ public static GodotLightType GetPatchApplied(this VisualServer.LightType _this, MRELightType value) { var lightType = (GodotLightType)Enum.Parse(typeof(GodotLightType), value.ToString()); if (!_this.Equals(lightType)) { _this = lightType; } return(_this); }