Core Concepts

General Tools

Essential SYNQ tools for timing, events, visuals, configuration, and navigation

Essential SYNQ tools for timing, events, visuals, configuration, and navigation.

Important Variables

time

Current time in seconds, updated when SYNQ framework ticks. Equal to GetTime().

synq.time

buffer

Combined latency, tick rate, and jitter buffer for precise timing.

synq.buffer -- latency + tickRate + jitter

latency

Latency to game server, averaged over last 30 seconds.

synq.latency

tickRate

Time between each SYNQ framework tick.

synq.tickRate

spellCastBuffer

Spell Queue Window duration set by SYNQ. Maximum time remaining on GCD or cast time for queuing next spell.

synq.spellCastBuffer

gcd

Expected GCD duration for 1.5s GCD spells, modified by haste.

synq.gcd -- 1.5 / (1 + player.haste)

hasControl

Whether the player has control of their character.

synq.hasControl

zone

Current zone text.

synq.zone

mapID

Current mapID.

synq.mapID

powerTypes

Table mapping power type names to numeric IDs.

synq.powerTypes -- { mana = 0, rage = 1, focus = 2, energy = 3, ... }

Framework Functions

onTick

Adds callback to main framework ticker. Called in order added, just before routine actor.

synq.onTick(callback[, enabled])

onUpdate

Same as onTick, but runs every frame (faster).

synq.onUpdate(callback[, enabled])

onEvent

Assign callback to combat log or other event.

synq.onEvent(callback, eventType)

Utility Functions

bin

Converts value to binary. Any value is 1, nil or false is 0.

synq.bin(conditions) : 1 | 0

controlMovement

Temporarily disables movement and optionally facing input.

synq.controlMovement(duration[, facing])

controlFacing

Temporarily disables facing input.

synq.controlFacing(duration)

StopMoving

Immediately stops player movement.

synq.StopMoving()

Populate

Creates references to associative array entries in other tables/namespaces.

synq.Populate(aArray, t1[, t2, t3, t4, t5, ...])

pullTimer

Reference to DBM/BigWigs pull timer. Defaults to 0.

synq.pullTimer : 0

Alerts & Visuals

alert

Displays a toast alert. Always returns true for use in conditionals.

synq.alert([message / {options}], [texture]) : true

Options: message, texture, duration, fadeIn, fadeOut, bgColor, imgX, imgY, imgScale

textureEscape

Converts spellID or texture ID into escape sequence string.

synq.textureEscape(spellID/FileDataID[, size, offsets])

Draw

Draws shapes and text ingame.

local Draw = synq.Draw

Draw(function(draw)
    draw:SetWidth(number)
    draw:SetColor(r, g, b, a)
    draw:Line(x1, y1, z1, x2, y2, z2, maxDistance)
    draw:Circle(x, y, z, radius, steps)
    draw:Cylinder(x, y, z, radius, height)
    draw:Arc(x, y, z, size, arc, rotation)
    draw:Rectangle(x, y, z, width, length, rotation)
    draw:Outline(x, y, z, radius)
    draw:FilledCircle(x, y, z, radius, steps)
    draw:Triangle(x, y, z, v1, v2, v3, cull, wireframe)
    draw:Text(string, font, x, y, z)
    draw:Texture(config, x, y, z, alphaA)
end)

Configuration

NewConfig

Creates persistent configuration storage. Shallow writes trigger saves.

synq.NewConfig(name)

synq.path

Returns path object for navigation between player and coordinates.

synq.path(player, x, y, z)

path object

Array of nodes with built-in methods.

path.simplify(tolerance, highestQuality) -- Douglas Peucker simplification
path.draw() -- Draw path for this tick
path.follow() -- Move character along path

Next: Explore Advanced Routine Features to see these tools in action, or check out the SYNQ UI documentation.