added TestLogo
This commit is contained in:
parent
9d6b1f767e
commit
a280dfd564
19
src/logo/TestLogo.scala
Normal file
19
src/logo/TestLogo.scala
Normal file
@ -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)
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user