Conectarse
Buscar
Mejores posteadores
XxStroksxX (463) | ||||
~*~[:Đαяќ:]~[:тιβια:]~*~ (366) | ||||
spoor (83) | ||||
Dj Pacos (73) | ||||
God Skit (68) | ||||
GoD MexicanSoul (40) | ||||
fuzzy (35) | ||||
Eddie (31) | ||||
GOD Chimito (30) | ||||
conalep1996 (23) |
Últimos temas
Temas más activos
Miembros que empiezan más temas
XxStroksxX | ||||
~*~[:Đαяќ:]~[:тιβια:]~*~ | ||||
God Skit | ||||
spoor | ||||
GoD MexicanSoul | ||||
fuzzy | ||||
Eddie | ||||
conalep1996 | ||||
Cletus | ||||
Dj Pacos |
[Mod] Ban Command :D by ~*~[Dark]~[Tibia]~*~
2 participantes
Página 1 de 1.
[Mod] Ban Command :D by ~*~[Dark]~[Tibia]~*~
Tienes un TFS 0.4_DEV y no puedes banear a players pues aquí un poco de solución.
Solo funciona con players que estén OnLine.
Solo basta que crees una nueva Mod en /mods/BAN.XML y lo pongas a trabajar.
REP+ 100% MIOO
Solo funciona con players que estén OnLine.
Solo basta que crees una nueva Mod en /mods/BAN.XML y lo pongas a trabajar.
- Código:
local default = {
length = 24 * 60 * 60,
comment = "Dont do illegal stuff.",
reason = 4
}
function getPlayerTesti(cid)
local Tiedot = db.getResult("SELECT `id` FROM `accounts` WHERE `id` = " .. getPlayerAccountId(cid) .. " LIMIT 1")
if Tiedot:getID() ~= LUA_ERROR then
local account = Tiedot:getDataInt("id")
return account
end
return LUA_ERROR
end
function onSay(cid, words, param)
local t = string.explode(param, ",")
if(not t[1]) then
doPlayerSendCancel(cid, "You must enter name.")
return true
end
local player = getPlayerByName(t[1])
if(not isPlayer(player)) then
doPlayerSendCancel(cid, "Player with name `" .. t[1] .. "` not found.")
return true
end
local action = t[2]
if(not t[2] or (t[2] and type(t[2]) ~= 'string')) then
doPlayerSendCancel(cid, "Wrong param.")
return true
end
local length = (t[3] and tonumber(t[3]) > 0) and t[3] or default.length
local comment = (t[4] and type(t[4]) == "string") and t[4] or default.comment
if(isInArray({"account", "acc", "a"}, action)) then
doAddAccountBanishment(getAccountIdByName(t[1]), getPlayerGUID(t[1]), os.time() + length, default.reason, comment, ACTION_BANISHMENT, comment, getPlayerGUID(cid))
result = true
--[[
elseif(isInArray({"player", "p"}, action)) then
--type missing
doAddPlayerBanishment(getPlayerGUID(t[1]), type, os.time() + length, default.reason, ACTION_BANISHMENT, comment, getPlayerGUID(cid))
result = true
elseif(isInArray({}, action)) then
--ip and mask missing
doAddIpBanishment(ip, mask, os.time() + length, default.reason, comment, getPlayerGUID(cid))
result = true
elseif(isInArray({}, action)) then
doAddNotation(getAccountIdByName(t[1]), getPlayerGUID(t[1]), default.reason, comment, getPlayerGUID(cid))
result = true
elseif(isInArray({}, action)) then
--channelId missing
doAddStatement(getPlayerGUID(t[1]), channelId, default.reason, comment, getPlayerGUID(cid))
result = true
]]
end
if(result) then
db.executeQuery("INSERT INTO `bans` (`id` ,`type` ,`value` ,`param`, `active`, `expires`, `added`, `comment`, `reason`, `action`) VALUES ('id', '3', '".. getPlayerTesti(player) .."', '45', '1', '".. os.time() + length .."', '".. os.time() .."', '".. comment .."', '12', '2' );")
doSendAnimatedText(getCreaturePosition(player), "BANISHED", TEXTCOLOR_RED)
doRemoveCreature(player)
end
return true
end
]]>
REP+ 100% MIOO
Temas similares
» [Talkation] Backpack Random Command !bp by ~*~[Dark]~[Tibia]~*~
» [Talkation] Comando Para Bailar :D By ~*~[Dark]~[Tibia]~*~
» [Script] No Anunciar Ots :D By ~*~[Dark]~[Tibia]~*~
» [CreatureScript] Anti-Bot System 100% By ~*~[Dark]~[Tibia]~*~
» [Spell] Paralyze Muy Buena (: By ~*~[Dark]~[Tibia]~*~
» [Talkation] Comando Para Bailar :D By ~*~[Dark]~[Tibia]~*~
» [Script] No Anunciar Ots :D By ~*~[Dark]~[Tibia]~*~
» [CreatureScript] Anti-Bot System 100% By ~*~[Dark]~[Tibia]~*~
» [Spell] Paralyze Muy Buena (: By ~*~[Dark]~[Tibia]~*~
Página 1 de 1.
Permisos de este foro:
No puedes responder a temas en este foro.
|
|
Lun Jun 08, 2015 12:08 pm por keishmer91
» [ACTION] God/GM da item a un player
Mar Dic 02, 2014 12:53 pm por hecmanos
» [8.60] Nuevo War Thais By TheRobertxon
Vie Jun 20, 2014 10:56 am por luismc
» [7.92]Naruto Final Story!
Dom Mayo 26, 2013 2:40 am por ricardotuck
» [9.1] Fun Server
Mar Mayo 14, 2013 5:32 pm por skifer
» [9.1] The Forgotten Server v0.2.11pl2 (Mystic Spirit)
Mar Mayo 14, 2013 5:29 pm por skifer
» New Map 8.60 (Darksystem) By: Turock & Gilio LIsto Arreglado El
Mar Mayo 07, 2013 5:27 pm por tonyso
» Ocean Clasic Global Map 8.6
Miér Mayo 01, 2013 11:19 pm por maganiua
» ayuda a abrir puertos
Lun Abr 29, 2013 5:58 pm por XxStroksxX
» [8.60] Speedy War
Dom Abr 28, 2013 5:51 pm por Sunnade'Audio