Page 1 of 1

implement compileIntoCurrentProcedure for if-else-chain expressions

Posted: Wed Dec 25, 2019 6:31 am
by Honktown
I want to use variables in conditionals for noise expressions. More complex functions can be implemented without doing work-arounds on map-gen. I was looking into atan2: have all the math correct for an accurate approximation, but no conditionals are available.

"condition-expression" isn't a valid type of expression, and using if-else-chain returns true for values > 0, false for values < 0 (and probably 0), but only takes literal-number's. There's no means of providing ordinary conditions (<, >, etc) documented anywhere, and I tried a bunch of things and looked all over.

I have example code for it, if examples would like to be taken for no-error/error arguments.

Re: implement compileIntoCurrentProcedure for if-else-chain expressions

Posted: Thu Dec 26, 2019 2:36 am
by Honktown
Nevermind, I figured out something for conditionals.

Re: implement compileIntoCurrentProcedure for if-else-chain expressions

Posted: Wed Jul 29, 2020 6:25 pm
by Bilka
I added this in 0.18.37.