JoinFormation

Join specified formation

Usage: Used in 8 task(s)

Lua Implementation

-- Join Formation
function execute(params)
    local leader = params.leader or this:getSuperior()

    if leader and leader:isValid() then
        this:addTask("DtFollow", {
            leader = leader,
            formation = params.formation_name or "wedge",
            position = params.position or 1,
            spacing = params.spacing or 100
        })
        return true
    end
    return false
end