Skip to main content
Discovery icon for Retro Dev Discord server

Retro Dev

7,601 Online
44,248 Members
# retro-chat6 people

how logic gates evaluate data

Logic gates handle boolean operations simply, but expand into short-circuit evaluation returning actual values when given non-boolean datatypes.

  • For boolean inputs, AND requires both inputs to be true, while OR returns true if either input is true
  • Blocks support any datatype, where nil and false are falsey while all other values are truthy
  • AND returns the first argument if false, otherwise the second; OR returns the first if true, otherwise the second
  • Short-circuit behavior powers common scripting patterns like ternary logic and waiting for character spawns
Summarized from recent messages, might be inaccurate

More conversations

Talk, Play, &
Hang Out

Find your space to hang out, discuss the latest updates with the party chat, and see who's down to join your next match.
Get App