OmniGame logoOmniGame

/schedule Command

Queues a function or function tag to be executed after a specified delay from the current game tick. `append` allows multiple schedules for the same function to stack; `replace` (default) overwrites the existing pending schedule. `clear` cancels a pending schedule.

Syntax
schedule function <function> <time> [append|replace] schedule clear <function>
Permission: 2Edition: Java

Examples

schedule function mypack:boss_spawn 30s replaceschedule function mypack:wave_2 200t appendschedule clear mypack:boss_spawnschedule function #mypack:cleanup 1d replace

Notes

Exclusive to Java Edition. Time units: `t` (game ticks, default), `s` (seconds = 20t), `d` (in-game days = 24000t). The minimum delay is 0 ticks (runs next tick). The function tag prefix `#` is supported. Scheduled functions execute relative to the world time when the delay elapses, not the calendar time.

More commands