public CurveInfo(AnimationCurve curve) { int num = (curve != null ? curve.length : 0); if (num == 0) { this.calc = false; this.constant = true; this.duration = 0f; this.offset = 0f; } else if (num != 1) { Keyframe item = curve[0]; Keyframe keyframe = curve[num - 1]; this.calc = true; this.constant = false; this.duration = keyframe.time - item.time; this.offset = curve[0].time; BobForceCurve.CurveInfo curveInfo = this; curveInfo.duration = curveInfo.duration * 8f; } else { this.calc = curve[0].@value != 0f; this.constant = true; this.duration = 0f; this.offset = 0f; } }
private void Gasp() { bool flag; bool flag1; bool flag2; this.infoX = new BobForceCurve.CurveInfo(this.forceX); this.infoY = new BobForceCurve.CurveInfo(this.forceY); this.infoZ = new BobForceCurve.CurveInfo(this.forceZ); this.calc = (this.infoX.calc || this.infoY.calc ? true : this.infoZ.calc); int num = this.sourceMask.length; if (num != 1) { flag = (num != 0 ? true : false); } else if (this.sourceMask[0].@value == 1f) { flag = false; } else if (this.sourceMask[0].@value != 0f) { flag = true; } else { this.calc = false; flag = false; } num = this.sourceScale.length; if (num == 1) { flag1 = (this.sourceScale[0].@value != 1f ? true : false); flag2 = (this.sourceScale[0].@value != 0f ? false : true); } else if (num != 0) { flag1 = true; flag2 = false; } else { flag1 = false; flag2 = false; } this.mask = flag; this.scale = flag1; this.scaleFixed = flag2; this.once = true; }