Skip to content

Shift string

135

The Shift string node acts as a sliding text buffer. When new characters are added, they are pushed into the buffer while older characters are shifted out. It is the core logic used for sequence-based puzzles like keypads or "Konami-style" hidden codes.

When to use this node: * Keypad Buffering: Storing the last 4 digits pressed by a player to see if they match a secret code. * Pattern Matching: Automatically triggering onPatternMatch the moment the buffer matches your predefined pattern. * Command History: Keeping a small visible record of the last few commands or inputs processed by a system.

Pro Tip: Use the clear after full property to automatically reset the buffer once it reaches its character limit, forcing players to re-enter a code from the beginning if they make a mistake.

Connectors in

  • pattern [type: string]
  • start [type: string]
  • add [type: string]
  • reset [type: action]
  • move [type: action]

Connectors out

  • res [type: string]
  • patternMatch [type: bool]
  • onChange [type: action]
  • onReset [type: action]
  • onFull [type: action]
  • onPatternMatch [type: action]

Node properties

  • clear after full [type: bool]
  • move after add [type: bool]
  • pattern [type: string]
  • positions [type: integer]
  • start [type: string]