Created
August 30, 2018 23:00
-
-
Save cxmeel/1836a352c64cfc51d703dad227a7d620 to your computer and use it in GitHub Desktop.
Returns a given value based on whether the condition evaluates to true or false.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--[[ | |
clockworksquirrel.iif | |
Returns a given value based on whether the condition evaluates to true or false. | |
Usage: | |
<variant> IIF(<boolean> expression, <variant> value_if_true, <variant> value_if_false) | |
--]] | |
return function(Condition, IfTrue, IfFalse) | |
if (not not Condition) then return IfTrue end | |
return IfFalse | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment