Redirect violations msgs to default channel
This commit is contained in:
parent
8a2d2cd5ac
commit
abcc95634e
|
@ -589,8 +589,14 @@ end
|
||||||
|
|
||||||
function sendMessage(message, tab)
|
function sendMessage(message, tab)
|
||||||
local tab = tab or getCurrentTab()
|
local tab = tab or getCurrentTab()
|
||||||
|
if not tab then return end
|
||||||
|
|
||||||
if tab == getRuleViolationsTab() then return end
|
-- when talking on server log, the message goes to default channel
|
||||||
|
local name = tab:getText()
|
||||||
|
if tab == serverTab or tab == getRuleViolationsTab() then
|
||||||
|
tab = defaultTab
|
||||||
|
name = defaultTab:getText()
|
||||||
|
end
|
||||||
|
|
||||||
-- handling chat commands
|
-- handling chat commands
|
||||||
local originalMessage = message
|
local originalMessage = message
|
||||||
|
@ -630,13 +636,6 @@ function sendMessage(message, tab)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
-- when talking on server log, the message goes to default channel
|
|
||||||
local name = tab:getText()
|
|
||||||
if tab == serverTab then
|
|
||||||
tab = defaultTab
|
|
||||||
name = defaultTab:getText()
|
|
||||||
end
|
|
||||||
|
|
||||||
local speaktypedesc
|
local speaktypedesc
|
||||||
if (tab.channelId or tab == defaultTab) and not chatCommandPrivateReady then
|
if (tab.channelId or tab == defaultTab) and not chatCommandPrivateReady then
|
||||||
if tab == defaultTab then
|
if tab == defaultTab then
|
||||||
|
|
|
@ -241,7 +241,7 @@ function checkExpSpeed()
|
||||||
player.lastExps = {}
|
player.lastExps = {}
|
||||||
end
|
end
|
||||||
table.insert(player.lastExps, {currentExp, currentTime})
|
table.insert(player.lastExps, {currentExp, currentTime})
|
||||||
if #player.lastExps > 10 then
|
if #player.lastExps > 30 then
|
||||||
table.remove(player.lastExps, 1)
|
table.remove(player.lastExps, 1)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue