From a280dfd564f50067029c46b2d07e6c5860ce0224 Mon Sep 17 00:00:00 2001 From: LordBaryhobal Date: Tue, 23 Apr 2024 15:15:49 +0200 Subject: [PATCH] added TestLogo --- src/logo/TestLogo.scala | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 src/logo/TestLogo.scala diff --git a/src/logo/TestLogo.scala b/src/logo/TestLogo.scala new file mode 100644 index 0000000..c8bb97a --- /dev/null +++ b/src/logo/TestLogo.scala @@ -0,0 +1,19 @@ +package logo + +import hevs.graphics.TurtleGraphics + +object TestLogo { + def main(args: Array[String]): Unit = { + val turtle: TurtleGraphics = new TurtleGraphics(600, 600) + turtle.penUp() + turtle.jump(300, 300) + turtle.setAngle(0) + turtle.forward(150 * math.sqrt(3) / 2) + turtle.turn(150) + turtle.penDown() + for (_: Int <- 0 until 3) { + turtle.forward(300) + turtle.turn(120) + } + } +}