after12am / eisenscript

A programming language designed for generating awesome structures.
https://after12am.github.io/eisenscript-docs/
MIT License
46 stars 4 forks source link

Triangle rotation is different in StructureSynth and Eisenscript #110

Open kronpano opened 3 years ago

kronpano commented 3 years ago

Not sure if this is an issue or just a different implementation All it means is you can't use StructureSynth scripts in Eisenscript and get the same results - just saying.

Those 4 triangles rotated

produce a different result from Strucutresynth if you run this script 4 * {x 1 rx 90}tri rule tri{ triangle[0,0,0; 1,0,0;1,1,0] triangle[0,0,0; 1,1,0;1,0,0] }

you can't at the moment run the eisenscript example from the link because the docs and editor seem to have different versions of eisenscript - in the editor box AND triangle together doesn't work.

after12am commented 3 years ago

After investigating, it seems a little difficult. If using transparent, that code is working.

{s 0.01 9 0.01 a .99 color green}box
{s 9 0.01 0.01 color red}box
{s 0.01 0.01 9 color blue}box

4 * {x 1 rx 90}tri
rule tri{
    triangle[0,0,0; 1,0,0;1,1,0]
}
after12am commented 3 years ago

Or use doOptimize parameter and set it to 0.

https://after12am.github.io/eisenscript-editor/?doOptimize=0%2F#B/TclLCoAwDEXRsVnFG4tIC06KSxEHfoIIxUJUKJTu3VIVJZD74IQdqlYa5s7krBMswrzF0XkK+ys/Fp5f/Mg8ONqTs1KDEsFDQzyMioesJKdlpBGoSH/YFsudqtK10Dm6Su0pXg==