internal override void parse(string str, ref int pos, ReleaseVersion release, int len, ConcurrentDictionary <int, BaseClassIfc> dictionary) { base.parse(str, ref pos, release, len, dictionary); HorizontalWidths = ParserSTEP.StripBool(str, ref pos, len); Widths.AddRange(ParserSTEP.StripListDouble(str, ref pos, len)); Slopes.AddRange(ParserSTEP.StripListDouble(str, ref pos, len)); Tags.AddRange(ParserSTEP.SplitListStrings(ParserSTEP.StripField(str, ref pos, len)).ConvertAll(x => ParserIfc.Decode(x))); }
private void OnRemoveExecute() { CurrentRoof.RoofSquare -= SelectedSlope.SlopeSquare; CurrentRoof.TotalQuantity -= SelectedSlope.ModuleQuantity; CurrentRoof.TotalSum -= SelectedSlope.Summ; Slopes.Remove(SelectedSlope); SelectedSlope = null; }
void Start() { // Get the rigidbody component rb = GetComponent <Rigidbody2D>(); slopes = GetComponent <Slopes>(); wallSlide = GetComponent <WallSlide>(); wallClimb = GetComponent <WallClimb>(); }
public void Read(AssetReader reader) { Path = reader.ReadStringAligned(); Times.Read(reader); Values.Read(reader); Slopes.Read(reader); PreInfinity = reader.ReadInt32(); PostInfinity = reader.ReadInt32(); }
public void Read(AssetStream stream) { Path = stream.ReadStringAligned(); Times.Read(stream); Values.Read(stream); Slopes.Read(stream); PreInfinity = stream.ReadInt32(); PostInfinity = stream.ReadInt32(); }
public void Read(AssetReader reader) { Path = reader.ReadString(); Times.Read(reader); Values.Read(reader); Slopes.Read(reader); PreInfinity = (CurveLoopTypes)reader.ReadInt32(); PostInfinity = (CurveLoopTypes)reader.ReadInt32(); }
public YAMLNode ExportYAML(IExportContainer container) { YAMLMappingNode node = new YAMLMappingNode(); node.Add("m_Path", Path); node.Add("m_Times", Times.ExportYAML(container)); node.Add("m_Values", Values.ExportYAML(container)); node.Add("m_Slopes", Slopes.ExportYAML(container)); node.Add("m_PreInfinity", PreInfinity); node.Add("m_PostInfinity", PostInfinity); return(node); }
public YAMLNode ExportYAML(IExportContainer container) { YAMLMappingNode node = new YAMLMappingNode(); node.Add(PathName, Path); node.Add(TimesName, Times.ExportYAML(container)); node.Add(ValuesName, Values.ExportYAML(container)); node.Add(SlopesName, Slopes.ExportYAML(container)); node.Add(PreInfinityName, (int)PreInfinity); node.Add(PostInfinityName, (int)PostInfinity); return(node); }
private void OnAddExecute() { SlopeCalculate(); var wrapper = new SlopeWrapper(new Slope()); wrapper.SlopeType = Slope.SlopeType; wrapper.SlopeSquare = Slope.SlopeSquare; wrapper.ModuleCost = Slope.ModuleCost; wrapper.ModuleQuantity = Slope.ModuleQuantity; wrapper.Summ = Slope.Summ; wrapper.PropertyChanged += Wrapper_PropertyChanged; Slopes.Add(wrapper); CurrentRoof.RoofSquare += Slope.SlopeSquare; CurrentRoof.TotalQuantity += Slope.ModuleQuantity; CurrentRoof.TotalSum += Slope.Summ; }
public virtual void CalculateGridTotal() { if (Slopes.Count > 0) { ///sumtotal SumTotal = Slopes.Select(x => x.Total).Sum(); if (OverrideManually == false) { ///sumtotalmixes SumTotalMixes = Slopes.Select(x => x.TotalMixes).Sum(); ///sumtotalmatext SumTotalMatExt = Slopes.Select(x => x.MaterialExtensionSlope).Sum(); //sumtotallaborext SumTotalLaborExt = Slopes.Select(x => x.LaborExtensionSlope).Sum(); } } }
public QuaternionCurve Unpack() { int[] timesValues = Times.Unpack(); float[] times = new float[timesValues.Length]; for (int i = 0; i < times.Length; i++) { times[i] = timesValues[i] * 0.01f; } Quaternionf[] rotations = Values.Unpack(); float[] slopes = Slopes.Unpack(); KeyframeTpl <Quaternionf>[] keyframes = new KeyframeTpl <Quaternionf> [rotations.Length]; for (int i = 0, j = 4; i < rotations.Length; i++, j += 4) { float time = times[i]; Quaternionf rotation = rotations[i]; Quaternionf inSlope = new Quaternionf(slopes[j - 4], slopes[j - 3], slopes[j - 2], slopes[j - 1]); Quaternionf outSlope = new Quaternionf(slopes[j + 0], slopes[j + 1], slopes[j + 2], slopes[j + 3]); keyframes[i] = new KeyframeTpl <Quaternionf>(time, rotation, inSlope, outSlope, KeyframeTpl <Quaternionf> .DefaultQuaternionWeight); } AnimationCurveTpl <Quaternionf> curve = new AnimationCurveTpl <Quaternionf>(keyframes, PreInfinity, PostInfinity); return(new QuaternionCurve(Path, curve)); }