From 9d20024aa35cd7f923ebfc1ed9a2ffbf2731da70 Mon Sep 17 00:00:00 2001 From: Jakob Odersky Date: Thu, 5 Nov 2009 21:02:40 +0000 Subject: Initial import. --- src/graphyx/tests/General2.scala | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 src/graphyx/tests/General2.scala (limited to 'src/graphyx/tests/General2.scala') diff --git a/src/graphyx/tests/General2.scala b/src/graphyx/tests/General2.scala new file mode 100644 index 0000000..2006080 --- /dev/null +++ b/src/graphyx/tests/General2.scala @@ -0,0 +1,28 @@ +/* + * Graphyx + * copyright (c) 2009 Jakob Odersky + * made available under the MIT License +*/ + +package graphyx.tests + +import sims.geometry._ +import sims.dynamics._ + +object General2 extends Test{ + val title = "General2" + val world = new World + + def init = { + world += new Body(new Rectangle(100,0.5,1) {pos = Vector2D(0, -0.5)}) {fixed = true} + //new Body(new Circle(0.05,1) {pos = Vector2D(0, 0.05)}), + //new Body(new Rectangle(0.5,0.1,1) {pos = Vector2D(0, 0.2)}), + //new Body(new Circle(0.05,1) {pos = Vector2D(1, 0.05)})) + + world += new Body(new Circle(0.2,1) {pos = Vector2D(5, 0.2)}) + world += new Body(new Rectangle(1.5,0.1,1) {pos = Vector2D(4.5, 0.5)}, new Rectangle(0.05,0.1,1) {pos = Vector2D(3.05,0.7)}) + world += new Body(new Circle(0.1,1) {pos = Vector2D(3.2, 0.7)}) + world += new Body(new Circle(0.5,10) {pos = Vector2D(8, 0.5)}) + + } +} -- cgit v1.2.3