☢stalker39☢
Пользователь
- Регистрация
- 28 Июл 2017
- Сообщения
- 279
- Реакции
- 0
- Баллы
- 30
- Адрес
- S.T.A.L.K.E.R. RP
- Веб-сайт
- netzona.org
- Клан-тег
- LEGION
- Род занятий
- Форумный червь
И так я вроде бы решил проблему с чат боксом НС.
Но появилась не то что бы ошибка, а скажем так закономерность. Когда пишешь в оос то пишет "Global OOC is disabled on this server."
И сообщение не отправляется. Прописал в конце данного кода вместо "false" "true". Чат оос работает но всплывает это сообщение "Global OOC is disabled on this server." в правом верхнем углу.
Как нормально настроить чат, что бы не вслывало это сообщение "Global OOC is disabled on this server."?
Заранее спасибо!
Часть кода:
-- Out of character.
nut.chat.register("ooc", {
onCanSay = function(speaker, text)
if (!nut.config.get("allowGlobalOOC")) then
speaker:notifyLocalized("Global OOC is disabled on this server.")
return false
else
local delay = nut.config.get("oocDelay", 10)
-- Only need to check the time if they have spoken in OOC chat before.
if (delay > 0 and speaker.nutLastOOC) then
local lastOOC = CurTime() - speaker.nutLastOOC
-- Use this method of checking time in case the oocDelay config changes.
if (lastOOC <= delay) then
speaker:notifyLocalized("oocDelay", delay - math.ceil(lastOOC))
return false
end
end
Но появилась не то что бы ошибка, а скажем так закономерность. Когда пишешь в оос то пишет "Global OOC is disabled on this server."
И сообщение не отправляется. Прописал в конце данного кода вместо "false" "true". Чат оос работает но всплывает это сообщение "Global OOC is disabled on this server." в правом верхнем углу.
Как нормально настроить чат, что бы не вслывало это сообщение "Global OOC is disabled on this server."?
Заранее спасибо!
Часть кода:
-- Out of character.
nut.chat.register("ooc", {
onCanSay = function(speaker, text)
if (!nut.config.get("allowGlobalOOC")) then
speaker:notifyLocalized("Global OOC is disabled on this server.")
return false
else
local delay = nut.config.get("oocDelay", 10)
-- Only need to check the time if they have spoken in OOC chat before.
if (delay > 0 and speaker.nutLastOOC) then
local lastOOC = CurTime() - speaker.nutLastOOC
-- Use this method of checking time in case the oocDelay config changes.
if (lastOOC <= delay) then
speaker:notifyLocalized("oocDelay", delay - math.ceil(lastOOC))
return false
end
end