ExecutionUpdated 2026-07-24

GPC combos, wait, and call

Author timed first-level combo steps with legal wait durations and compose sequences with combo-only call.

Overview

A combo is a named timed sequence that runs alongside the repeating main logic. wait divides its first-level statements into time segments.

call composes combo behavior from another combo context. Both wait and call have placement rules enforced by the compiler.

Key facts

  • wait is allowed only in combos.
  • wait must be at the first level of a combo.
  • A wait duration is from 1 through 32767 milliseconds.
  • call is allowed only in combos.
  • User functions and main cannot use wait.

GPC syntax examples

Examples are intentionally small. Replace identifiers only with values documented for your target.

Timed press and releaseexample.gpc
combo Tap {
    set_val(XB1_A, 100);
    wait(60);
    set_val(XB1_A, 0);
    wait(40);
}

Functions, commands, and terms

Names below are catalog entries, not guessed signatures. Open the official sources for current parameter and return-value details.

NameKindPurpose
combokeyword

Declares a named timed sequence.

waitcommand

Ends a combo time segment for a duration from 1 to 32767 ms.

callcommand

Invokes a combo from within combo execution.

Common mistakes

Calling wait from main or a function.

Nesting wait inside if or another block in a combo.

Using zero, a negative value, or more than 32767 ms.

Using call outside a combo.

Official GPC sources

Use these first-party references to confirm exact syntax and runtime behavior for your installed firmware and Studio version.

Related GPC references