TurboWarp / extensions

User-contributed unsandboxed extension gallery for TurboWarp
https://extensions.turbowarp.org/
MIT License
114 stars 233 forks source link

true-fantom/math: add x < y < z blocks #1430

Closed MaelkMark closed 4 months ago

MaelkMark commented 5 months ago

I've added a new boolean block that checks whether a number is in a given range. <A is in range B - C>

block opcode: is_in_range_block

LilyMakesThings commented 5 months ago

I think this exists in more comparisons as () < () < ()

MaelkMark commented 5 months ago

I think this exists in more comparisons as () < () < ()

Oh, I didn't know. However I think it would be practical to have such a block in the math extension too - you don't have to add the more comparisons ext. (I've added that block because I needed a block like that in my project)

LilyMakesThings commented 5 months ago

I second that as well, adding both is often tedious.

GarboMuffin commented 4 months ago

you have to use Cast.compare or this will break horribly when it gets a string containing a number instead of an actual number

MaelkMark commented 4 months ago

Thanks for the correction and adding the blocks to the extension!