A shortcut for what?
And also, obviously your other engines use a different programming language, this code is utter gibberish.
But why it fails? You start an assignment and then open a block with a codeword leaving the assignment hanging in the air id say. Neither makes the if block any sense, "bar", like youre just throwing a string to the language without telling it what to do with it.
Youre probably looking for
local foo= true and "bar" or "hello"
That would be the common lua syntax.
BrotSagtMist wrote: ↑Sun Sep 04, 2022 12:15 pm
A shortcut for what?
And also, obviously your other engines use a different programming language, this code is utter gibberish.
But why it fails? You start an assignment and then open a block with a codeword leaving the assignment hanging in the air id say. Neither makes the if block any sense, "bar", like youre just throwing a string to the language without telling it what to do with it.
Youre probably looking for
local foo= true and "bar" or "hello"
That would be the common lua syntax.
My apologies, Roblox lets me do it. I realize they use a custom version of Lua called Luau, they must have added the feature.