예제 #1
0
 public void AddBody(double mass, double size, int color, BodyStartPosition startPosition)
 {
     bodies.Add(new Body(mass, size, renderer.GetStartingPosition(startPosition), simSpace));
     renderer.Add(size, color, bodies.Last());
 }
예제 #2
0
 public void AddBody(double mass, double size, int color, BodyStartPosition startPosition, SimPoint startVelocity,
                     bool isGravitySource)
 {
     bodies.Add(new Body(mass, size, renderer.GetStartingPosition(startPosition), startVelocity, isGravitySource, simSpace));
     renderer.Add(size, color, bodies.Last());
 }