
Boolean · Reads onchain state
Compares two values with a chosen operator and returns a boolean. The operator can be equal, not equal, greater than, greater or equal, less than, less or equal, and, or or, applied to two numbers or two booleans. Decimals are matched between the operands so a price and a threshold compare correctly. The result is a value, not a branch. Reach for it when a later step needs the boolean itself: feed it into a while loop's condition, store it as a flag, combine several comparisons with and or or, or bubble it as the program's result. Use the predicate instead when the goal is to branch or revert.
Dust Guard


1·Take
Declares a named parameter called amount, whose value the caller supplies when running the plug.
2·Take
A second parameter, threshold, is likewise declared for the caller to fill in at execution time.
3·Compare two values
Comparing the amount against the threshold, this step returns true when the amount is greater than or equal to the threshold.
4·Predicate
Requiring that comparison result to equal true, execution proceeds only when the amount meets or exceeds the threshold, otherwise it halts.