/// <summary> /// Clone all of the necessary data in the CurveEngine. /// </summary> /// <returns>The partially cloned curve data.</returns> public CurveEngine PartialClone() { CurveEngine clonedCE = new CurveEngine(AntiAliasing); clonedCE.ControlPoints = ControlPoints.Select(i => i.Clone()).ToList(); //Don't clone the GeneratedPoints or OrganizedPoints, as they will be calculated. clonedCE.Arrow1 = Arrow1.Clone(); clonedCE.Arrow2 = Arrow2.Clone(); clonedCE.DashPattern = DashPattern; return(clonedCE); }
public override void update() { if (Icon1 != null) { Icon1.update(); if (Icon2 != null) { Icon2.update(); } if (Icon3 != null) { Icon3.update(); } } Arrow1.update(); Arrow2.update(); Arrow3.update(); }
public override void draw(SpriteBatch sprite_batch, Vector2 draw_offset = default(Vector2)) { if (Icon1 != null) { Vector2 offset = this.loc + draw_vector(); Icon1.draw(sprite_batch, draw_offset - offset); if (Icon2 != null) { Icon2.draw(sprite_batch, draw_offset - offset); Arrow3.draw(sprite_batch, draw_offset - offset); } if (Icon3 != null) { Icon3.draw(sprite_batch, draw_offset - offset); Arrow2.draw(sprite_batch, draw_offset - offset); if (Icon2 != null) { Arrow1.draw(sprite_batch, draw_offset - offset); } } } }