fix minor channels lua error
This commit is contained in:
parent
d3665efbb2
commit
1c12bc3fb2
|
@ -96,12 +96,12 @@ local function onCreatureSpeak(name, level, speaktype, message, channelId, creat
|
||||||
if not defaultMessage then
|
if not defaultMessage then
|
||||||
channel = channels[channelId]
|
channel = channels[channelId]
|
||||||
end
|
end
|
||||||
|
|
||||||
if channel then
|
if channel then
|
||||||
Console.addText(message, speaktype, channel)
|
Console.addText(message, speaktype, channel)
|
||||||
else
|
else
|
||||||
-- server sent a message on a channel that we are not aware of, must leave it
|
-- server sent a message on a channel that is not open
|
||||||
g_game.leaveChannel(channelId)
|
warning('message in channel id ', channelId, ' which is unknown, this is a server bug, relogin if you want to see messages in this channel')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -12,4 +12,4 @@ Module
|
||||||
NPCTrade.init()
|
NPCTrade.init()
|
||||||
|
|
||||||
@onUnload: |
|
@onUnload: |
|
||||||
NPCTrade.terminate()
|
NPCTrade.terminate()
|
||||||
|
|
Loading…
Reference in New Issue