/* setTipShape puts a clone of pshape at each vertex of the * pbasepoly(), and then it deletes pshape. So don't use a pshape as argument that you need to save. */ //cSprite overloads /* Overload the standard cSpriteComposite radius() method. */ public override void mutate(int mutationflags, float mutationstrength) { if (BasePoly == null) { add(new cShape()); } BasePoly.mutate(mutationflags, mutationstrength); cSprite ptipshapenew; if (TipShape != null) { ptipshapenew = TipShape.copy(); //Use this as a model } else { ptipshapenew = new cShape(); } ptipshapenew.mutate(mutationflags, mutationstrength); //Make the tip shape have smaller radius than the basepoly. ptipshapenew.Radius = Framework.randomOb.mutate(ptipshapenew.Radius, MIN_TIP_RADIUS_RATIO * BasePoly.Radius, MAX_TIP_RADIUS_RATIO * BasePoly.Radius, mutationstrength); //Randomize the tip rotations. _tipangvelocity = Framework.randomOb.randomSign() * Framework.randomOb.mutate(_tipangvelocity, cPolyPolygon.MINTIPANGLEVELOCITY, cPolyPolygon.MAXTIPANGLEVELOCITY, mutationstrength); //Make all the tips the same. TipShape = ptipshapenew; //This deletes ptipshapenew //More fixup _newgeometryflag = true; //Because you changed the relative positions of the tips. }
public void InsertPoly(BasePoly poly) { this.InsertExternalPoly((TEntity)poly); }
public override void InsertPoly(BasePoly poly) { // convert BasePoly to external type and insert that throw new NotImplementedException(); }
public abstract void InsertPoly(BasePoly poly);