Llamar como
Conditions.totem.remaining(record, start)
Registra la dependencia Conditions.totem.remaining y luego llámala con ese nombre. Una llamada con espacio de nombres no pasa self: usa una llamada con dos puntos o pasa tú mismo el objeto.
Qué hace
Seconds left on a totem slot record at time start (or now): zero when the totem is inactive, and never negative.
Argumentos
| Nombre | Tipo | Qué hace |
|---|---|---|
record | table | Totem record with active, startTime and duration fields. |
start | number | nil | Time to measure from; nil uses GetTime(). |
Retornos
| 1 | number | Remaining seconds. |
|---|
Ediciones
Las funciones auxiliares integradas se registran en todas las ediciones. Lo que cambia es la API del juego que leen; donde falta alguna, la función auxiliar recurre a una alternativa o devuelve nil con un motivo.
- No disponible en esa edición (el motivo aparece en la información emergente)
- Solo mientras estén activas las alternativas de Blizzard para API obsoletas
| API del juego | |||||
|---|---|---|---|---|---|
GetTime |
Cómo la llama el addon
- Tótem presente (evaluate)
return record.active and remaining(record,start)>0 - Tiempo restante del tótem (evaluate)
local seconds=remaining(record,start) Conditions.totem.findSpecificelseif record.active and remaining(record,start)>0 then
Código fuente
Conditions/totem.lua, línea 62. Solo lectura en el juego; Duplicar crea una copia editable.
Conditions.totem.remaining(record, start)
if not record.active then return 0 end
return math.max(0,record.startTime+record.duration-(start or GetTime()))




