add p5 test file
This commit is contained in:
parent
1733de7dff
commit
73b2343963
16
build/p5_test.mjs
Normal file
16
build/p5_test.mjs
Normal file
|
@ -0,0 +1,16 @@
|
|||
import {run, p5} from "./ludus.mjs"
|
||||
|
||||
const code = `
|
||||
pencolor! (colors :white)
|
||||
repeat 10 {
|
||||
repeat 4 {
|
||||
fd! (500)
|
||||
rt! (0.25)
|
||||
}
|
||||
rt! (0.1)
|
||||
}`
|
||||
|
||||
const result = run(code)
|
||||
|
||||
console.log(result.io.stdout.data)
|
||||
console.log(p5(result.io.turtle.data))
|
Loading…
Reference in New Issue
Block a user