• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Linux Error when i try to ban a player

Vrotz

Member
Joined
Apr 7, 2011
Messages
1,071
Reaction score
7
Location
Brazil
Hi brahs,

When i said /ban in my god to punished a player, i receive that message:
PHP:
[13:31:10.818] [Error - CreatureScript Interface]
[13:31:10.818] data/creaturescripts/scripts/ban/action.lua:onChannelRequest
[13:31:10.818] Description:
[13:31:10.818] data/lib/050-function.lua:27: bad argument #1 to 'ipairs' (table expected, got nil)
[13:31:10.819] stack traceback:
[13:31:10.819]  [C]: in function 'ipairs'
[13:31:10.819]  data/lib/050-function.lua:27: in function 'isInArray'
[13:31:10.819]  data/creaturescripts/scripts/ban/action.lua:14: in function <data/creaturescripts/scripts/ban/action.lua:7>
 
Post the script.

PHP:
local TYPE_ACCESS = {
    [1] = { "Player" },
    [2] = { "Player" },
    [3] = { "Account", "Player" },
    [4] = { "Account", "Player" },
    [5] = { "Account", "Player", "IP" }
}

function onSay(cid, words, param, channel)
    unregisterCreatureEventType(cid, "channelrequest")
    unregisterCreatureEventType(cid, "textedit")

    doPlayerSendChannels(cid, TYPE_ACCESS[getPlayerAccess(cid)])
    registerCreatureEvent(cid, "Ban_Type")
    return true
end
 
Back
Top