public override dynamic ValueToData(ValueElement element, string value) { float fData = actorValueEnum.ValueToData(element, value); byte[] bytes = BitConverter.GetBytes(fData); return(BitConverter.ToUInt32(bytes)); }
public override dynamic ValueToData(ValueElement element, string value) { var n = value.IndexOf(':'); if (n == -1) { return(0); } var fnString = value.Substring(0, n - 1); var mbString = value.Substring(n + 1); return(eventMemberEnum.ValueToData(element, mbString) << 16 + eventFunctionEnum.ValueToData(element, fnString)); }
public override dynamic ValueToData(ValueElement element, string value) { var match = valueExpr.Match(value); if (match == null) { return(0); } var enumData = ctdaTypeEnum.ValueToData(element, match.Groups[1].Value); var flagsData = match.Groups.Count > 2 ? ctdaTypeFlags.ValueToData(element, match.Groups[2].Value) : 0; return(enumData + flagsData); }