Postado Janeiro 13, 2015 10 anos Pessoal anteriormente peguei este script para o TOP LEVEL do server, agora preciso editar o script, ao inves do efeito sair no TOP preciso atribuir o efeito a um player que tenha determinado STORAGE local tempo = 10 --tempo em segundos function onLogin(cid) query = db.getResult("SELECT `name`, `level` FROM `players` WHERE `group_id` < 2 ORDER BY `level` DESC LIMIT 1") if (query:getID() ~= -1) then name = query:getDataString("name") if getPlayerName(cid) == name then TopEffect(cid) end end return TRUE end function TopEffect(cid) if isPlayer(cid) then doSendAnimatedText(getCreaturePosition(cid), "[TOP]", TEXTCOLOR_LIGHTBLUE) doSendMagicEffect(getCreaturePosition(cid), 30) addEvent(TopEffect, tempo*1000, cid) end return TRUE end
Postado Janeiro 13, 2015 10 anos axo que por esse script nao da pra fazer nao, tem que refazer tudo msm
Postado Janeiro 13, 2015 10 anos local delay = 10 --Delay entre os effects. local storage = xxx --Storage. local effect = xxx --Efeito. local function sendContinuousEffect(cid, key) if isPlayer(cid) and getPlayerStorageValue(cid, key) > -1 then doSendMagicEffect(getThingPos(cid), effect) addEvent(function() sendContinuousEffect(cid, key) end, delay * 1000) end end function onLogin(cid) sendContinuousEffect(cid, storage) return true end não respondo pms solicitando suporte em programação/scripting
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.