Now privjet when login
This commit is contained in:
@@ -8,7 +8,7 @@ local debug = false
|
|||||||
local channels = {
|
local channels = {
|
||||||
{ name = "Horde", password = "garrosh" },
|
{ name = "Horde", password = "garrosh" },
|
||||||
{ name = "world_ru", password = nil },
|
{ name = "world_ru", password = nil },
|
||||||
{ name = "Agent", password = "agents42" },
|
{ name = "Agent", password = "agents42" },
|
||||||
}
|
}
|
||||||
---@type string
|
---@type string
|
||||||
---@type string[]
|
---@type string[]
|
||||||
@@ -107,11 +107,28 @@ local function FindOrCreateChatFrame(chatFrameName, groups, channels)
|
|||||||
return chatFrame
|
return chatFrame
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local function Privjet(channelname)
|
||||||
|
local channels = { GetChannelList() }
|
||||||
|
for i = 1, #channels, 2 do
|
||||||
|
local id = channels[i]
|
||||||
|
local name = channels[i + 1]
|
||||||
|
if name == channelname then
|
||||||
|
SendChatMessage("Zdravstvuyte ljudi!", "CHANNEL", nil, id)
|
||||||
|
return
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
local function Configure()
|
local function Configure()
|
||||||
JoinChannels()
|
JoinChannels()
|
||||||
FindOrCreateChatFrame("Auto", subscribedMessageGroups, {})
|
-- FindOrCreateChatFrame("Auto", subscribedMessageGroups, subscribedChannels)
|
||||||
|
-- FindOrCreateChatFrame("world_ru", {}, { "world_ru" })
|
||||||
FindOrCreateChatFrame("Horde", {}, { "Horde" })
|
FindOrCreateChatFrame("Horde", {}, { "Horde" })
|
||||||
FindOrCreateChatFrame("Agent", {}, { "Agent" })
|
FindOrCreateChatFrame("Agent", {}, { "Agent" })
|
||||||
|
Privjet("Horde")
|
||||||
|
C_Timer.After(1, function()
|
||||||
|
Privjet("Agent")
|
||||||
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
local frame = CreateFrame("Frame")
|
local frame = CreateFrame("Frame")
|
||||||
|
BIN
Channeler.zip
(Stored with Git LFS)
BIN
Channeler.zip
(Stored with Git LFS)
Binary file not shown.
Reference in New Issue
Block a user