zbizu
Legendary OT User
original author: @Ninja
original thread: Guild Leaders Channel (9.X and 8.6)
(see link to know what this script does)
no source edits needed
chatchannels.xml:
guildleaders.lua
original thread: Guild Leaders Channel (9.X and 8.6)
(see link to know what this script does)
no source edits needed
chatchannels.xml:
Code:
<channel id="10" name="Guild Leaders" script="guildleaders.lua" />
guildleaders.lua
Code:
function canJoin(player)
return player:getGuildLevel() == 3 or player:getGroup():getAccess()
end
function onSpeak(player, type, message)
local staff = player:getGroup():getAccess()
local guild = player:getGuild()
local info = "staff"
type = TALKTYPE_CHANNEL_Y
if staff then
if guild then
info = info .. "][" .. guild:getName()
end
type = TALKTYPE_CHANNEL_O
else
info = guild:getName()
end
sendChannelMessage(10, type, player:getName() .. " [" .. info .. "]: " .. message)
return false
end