public JointSetup Randomize(JointSetup setup) { if (setup == null) { return(null); } JointSetup result = new JointSetup(); result.position.x = position.Randomize(setup.position.x); result.position.y = position.Randomize(setup.position.y); result.size = size.Randomize(setup.size); result.weight = weight.Randomize(setup.weight); result.friction = friction.Randomize(setup.friction); result.bounciness = bounciness.Randomize(setup.bounciness); return(result); }
public MuscleSetup Randomize(MuscleSetup setup) { MuscleSetup result = new MuscleSetup(); result.activeTime = activeTime.Randomize(setup.activeTime); result.interval = interval.Randomize(setup.interval); result.contractedDistance = contractedDistance.Randomize(setup.contractedDistance); result.relaxedDistance = relaxedDistance.Randomize(setup.relaxedDistance); result.frequency = frequency.Randomize(setup.frequency); result.startPhase = startPhase.Randomize(setup.startPhase); result.jointA = setup.jointA; result.jointB = setup.jointB; return(result); }