LearnSkill
Train spells at a trainer. Waits if unavailable or unaffordable; add the required MinLevel and class filters.
- Formato del valor
- table
- Ámbito
- step
Las descripciones técnicas se conservan en su inglés original. Los nombres de los campos y los ejemplos de Lua no se modifican.
Ejemplos
Ejemplo de las fuentes. Sustituye los ID y valores según tu ruta; este sitio no ejecuta Lua.
LearnSkill = { spellID = 6673 }, MinLevel = 1LearnSkill = { allAvailable = true, npcID = 911 }APR.RouteQuestStepList["Forever-Training-Example"] = {
label = "Training example",
gameVersion = "forever",
mapID = 1411,
conditions = { Faction = "Horde", Class = "MAGE" },
steps = {
{
LearnSkill = { spellID = 7411 },
MinLevel = 5,
SkipForPrimaryProfessions = 2,
Coord = { x = -4960.0, y = -791.3 },
Zone = 1411,
},
{ PickUp = { 96873 }, Skill = { skillID = 333, rank = 1 }, Zone = 1411 },
{ RouteCompleted = true },
},
}Parámetros documentados
| Parámetros documentados | Funcionamiento y detalles | Formato del valor |
|---|---|---|
spellID | Shown in the source example; this does not establish a required field. | number |
MinLevel | Shown in the source example; this does not establish a required field. | number | string | table |
Funcionamiento y detalles
Forms shown in the documentation, not an exhaustive runtime schema. Constant runtime types are not inferred.
Action / Progression Options
An action waits for completion; a failed step condition skips the step. Use one main action per step.
LearnSkill: named spells
spellID = 6673 or spellIDs = { 6673, 100 } supplies localized names; optional npcID restricts the trainer.
LearnSkill: all services
LearnSkill = { allAvailable = true, npcID = 911 }; trainer ID required. Use text for advice when no spell IDs are supplied.
Main actions
Use separate SellItems and Repair steps with the same coordinates; only one main action per step.
Example Route
APR.RouteQuestStepList["Forever-Training-Example"] = {
label = "Training example",
gameVersion = "forever",
mapID = 1411,
conditions = { Faction = "Horde", Class = "MAGE" },
steps = {
{
LearnSkill = { spellID = 7411 },
MinLevel = 5,
SkipForPrimaryProfessions = 2,
Coord = { x = -4960.0, y = -791.3 },
Zone = 1411,
},
{ PickUp = { 96873 }, Skill = { skillID = 333, rank = 1 }, Zone = 1411 },
{ RouteCompleted = true },
},
}