Ir para conteúdo

Posts Recomendados

blz galera bom dia, eu tenho esse talkaction no meu servidor, o meu sistema vip e por storage ai gostaria de bloquear esse comando só pra vips poder falar

 

---By Masterpako19---
--Config--
local cash = 500 -- Dinero que se nesecita para hacer el broadcast (en gps)
local levelneeded = 8 -- Level necesario para hacer el broadcast
local lenght = 100 -- Maximo de caracteres del mensaje
local messagesort = MESSAGE_STATUS_WARNING -- can be "MESSAGE_STATUS_WARNING" or "TALKTYPE_ORANGE_1" check your global.lua for more...
local exhaustTime = 1 * 60 * 1000 -- tiempo de exausted entre cada mensaje (para cambiar mas minutos cambia el 4 por x cantidad de minutos)
local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, exhaustTime)
--End of config--
function onSay(cid, words, param)
if getCreatureCondition(cid, CONDITION_EXHAUST) == TRUE then
doPlayerSendCancel(cid, "Lo siento, nesecitas esperas 1 minutos para mansar otro mensaje")
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return TRUE
end
local name = getPlayerName(cid)
local level = getPlayerLevel(cid)
if isCreature(cid) == TRUE then
if param ~= nil then
if string.len(param) < lenght then
if level >= levelneeded then
if doPlayerRemoveMoney(cid, cash) == TRUE then
broadcastMessage( ''..name..' ['..level..'] dice: ' .. param .. '', messagesort)
--exhaustion.set(cid, storageValue,exhaustTime)
doAddCondition(cid, exhaust)
return TRUE
else
doPlayerSendCancel(cid, 'Tu nesecitas '..cash..' gps para hacer un broadcast!')
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return TRUE
end
else
doPlayerSendCancel(cid, 'Tu nesecitas ser level '..levelneeded..' para hacer un broadcast!')
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return TRUE
end
else
doPlayerSendCancel(cid, 'No mas de ' .. lenght .. ' caracteres. ')
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return TRUE
end
else
doPlayerSendCancel(cid, 'Nesecitas escribir algo!')
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return TRUE
end
else
doPlayerSendCancel(cid, 'You haven\'t a target!')
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
return TRUE
end
return TRUE
end
Link para o comentário
https://xtibia.com/forum/topic/239959-ajuda-com-script-vip-falando-em-vermelho/
Compartilhar em outros sites

×
×
  • Criar Novo...