Implement follow command
This commit is contained in:
@@ -165,6 +165,12 @@ function shared.Commander.Init()
|
||||
LeaveParty()
|
||||
return {}
|
||||
end
|
||||
---@param target string
|
||||
local function FollowTarget(target)
|
||||
if not target then return end
|
||||
FollowUnit(target)
|
||||
return {}
|
||||
end
|
||||
|
||||
---@class Command
|
||||
---@field keywordRe string
|
||||
@@ -179,6 +185,7 @@ function shared.Commander.Init()
|
||||
{ keywordRe = "^helpen", commanderOnly = false, callback = HelpEn },
|
||||
{ keywordRe = "^joingroup", commanderOnly = true, callback = JoinGroup },
|
||||
{ keywordRe = "^leavegroup", commanderOnly = true, callback = LeaveGroup },
|
||||
{ keywordRe = "^follow", commanderOnly = false, callback = FollowTarget },
|
||||
}
|
||||
|
||||
local commanderChannelFrame = CreateFrame("Frame")
|
||||
|
||||
Reference in New Issue
Block a user