Postado Setembro 16, 2018 6 anos Olá! boa noite eu preciso que essa script de promotion fosse Modificada : O LvL Do players é resetado porem eu queria que fosse como um reset normal seu hp e mana continuasse e o seu LvL fosse pra 1 So pode-se fazer essa promotion se tiver x LvL! local tab = { -- [vocid] = {prom = newvocid}, [1] = {prom = 9}, [2] = {prom = 10}, [3] = {prom = 11}, [4] = {prom = 12} } local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end function creatureSayCallback(cid, type, msg) if (not npcHandler:isFocused(cid)) then return false end local talkUser = NPCHANDLER_CONVbehavior == CONVERSATION_DEFAULT and 0 or cid if (msgcontains(msg, 'deus')) then if tab[getPlayerVocation(cid)] then talkState[talkUser] = 1 selfSay('tem certezaz que quer ser mesmo um Deus?', cid) else talkState[talkUser] = 0 selfSay('voce ainda nao esta pronto.', cid) end elseif (msgcontains(msg, 'yes') and talkState[talkUser] == 1) then if (getPlayerVocation(cid) ~= tab[getPlayerVocation(cid)].prom) then talkState[talkUser] = 0 doPlayerSetVocation(cid, tab[getPlayerVocation(cid)].prom) doSendMagicEffect(getThingPos(cid), CONST_ME_GIFT_WRAPS) selfSay('Parabens, Agora Voce e um Deus Respeitado!', cid) else talkState[talkUser] = 0 selfSay('Voce ja é Deus, continue sua jornada.', cid) end elseif (msgcontains(msg, 'no') and talkState[talkUser] == 1) then talkState[talkUser] = 0 selfSay('Entao adeus, jovem tolo.', cid) end Agradeço! darei REP ++
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.