Jass:QueuedTriggerRemoveByIndex – Mappedia

Jass:QueuedTriggerRemoveByIndex

Aus Mappedia
Wechseln zu: Navigation, Suche
Funktion: QueuedTriggerRemoveByIndex
Parameter: integer
Rückgabewert: boolean
Autor: Blizzard
Quelle: Blizzard.j
Synchron: Unbekannt



Code

function QueuedTriggerRemoveByIndex takes integer trigIndex returns boolean
    local integer index

    // If the to-be-removed index is out of range, fail.
    if (trigIndex >= bj_queuedExecTotal) then
        return false
    endif

    // Shift all queue entries down to fill in the gap.
    set bj_queuedExecTotal = bj_queuedExecTotal - 1
    set index = trigIndex
    loop
        exitwhen index >= bj_queuedExecTotal
        set bj_queuedExecTriggers[index] = bj_queuedExecTriggers[index + 1]
        set bj_queuedExecUseConds[index] = bj_queuedExecUseConds[index + 1]
        set index = index + 1
    endloop
    return true
endfunction

Parameter

Typ Name Beschreibung
integer trigIndex
Meine Werkzeuge
Namensräume
Varianten
Aktionen
Navigation
Warcraft-Mapping
Werkzeuge