fix possible crash when disconnecting, fix status small message
This commit is contained in:
parent
1983a08cbe
commit
e8767d3971
|
@ -13,7 +13,7 @@ local MessageTypes = {
|
||||||
eventAdvance = { color = '#FFFFFF', consoleTab = 'Server Log', labelId = 'centerAdvance', consoleOption = 'showEventMessagesInConsole', wrap = true },
|
eventAdvance = { color = '#FFFFFF', consoleTab = 'Server Log', labelId = 'centerAdvance', consoleOption = 'showEventMessagesInConsole', wrap = true },
|
||||||
eventDefault = { color = '#FFFFFF', consoleTab = 'Server Log', labelId = 'bottomStatus', consoleOption = 'showEventMessagesInConsole' },
|
eventDefault = { color = '#FFFFFF', consoleTab = 'Server Log', labelId = 'bottomStatus', consoleOption = 'showEventMessagesInConsole' },
|
||||||
statusDefault = { color = '#FFFFFF', consoleTab = 'Server Log', labelId = 'bottomStatus', consoleOption = 'showStatusMessagesInConsole' },
|
statusDefault = { color = '#FFFFFF', consoleTab = 'Server Log', labelId = 'bottomStatus', consoleOption = 'showStatusMessagesInConsole' },
|
||||||
statusSmall = { color = '#FFFFFF', windowLocation = 'bottomStatus' },
|
statusSmall = { color = '#FFFFFF', labelId = 'bottomStatus' },
|
||||||
}
|
}
|
||||||
|
|
||||||
local centerTextMessagePanel
|
local centerTextMessagePanel
|
||||||
|
@ -44,7 +44,7 @@ local function displayMessage(msgtype, msg, time)
|
||||||
end
|
end
|
||||||
|
|
||||||
if not time then
|
if not time then
|
||||||
time = math.max(#msg * 100, 5000)
|
time = math.max(#msg * 100, 4000)
|
||||||
else
|
else
|
||||||
time = time * 1000
|
time = time * 1000
|
||||||
end
|
end
|
||||||
|
|
|
@ -257,6 +257,9 @@ void Game::walk(Otc::Direction direction)
|
||||||
|
|
||||||
void Game::forceWalk(Otc::Direction direction)
|
void Game::forceWalk(Otc::Direction direction)
|
||||||
{
|
{
|
||||||
|
if(!isOnline() || !checkBotProtection())
|
||||||
|
return;
|
||||||
|
|
||||||
switch(direction) {
|
switch(direction) {
|
||||||
case Otc::North:
|
case Otc::North:
|
||||||
m_protocolGame->sendWalkNorth();
|
m_protocolGame->sendWalkNorth();
|
||||||
|
|
Loading…
Reference in New Issue