Aaai procuro um sistema de reset tipo o de rozin , ex: fala !reset no lvl 10k vira super assassin ii ganha umas magias muitos lols ii mais fortes , de novo !reset lvl 60k vira mega assasino ganha mais magias ii armas novas etc... ALGUEM AI PODE ME AJUDAR PLX?
Sistema De Reset

s o sistema de reset normal eu tenhu um que preste!
isso dai eu n sei :S
Contato: DevilMoon@Xtibia.com
intaoh me passa ele ai então fasendo favor =) vo ve se consigo..
AAAI VC Q É MAPPEr pode conseguir um mapa bom pra mim to um tempão procurando um mapa..vlw fuiiz
sahusha o mapa fala pelo pvt o script ta ai dps tu edita ok?
ok vai em DATA>NPC
cria uma pasta xml ou copia de outro npc renomeia para Reseter e bota isso dentro
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Reseter" script="reset.lua" walkinterval="2000" floorchange="0">
<health now="150" max="150"/>
<look type="115" head="115" body="0" legs="114" feet="0" addons="3" corpse="2212"/>
<parameters>
<parameter key="module_shop" value="1"/>
<parameter key="message_greet" value="Eae |PLAYERNAME| Tudu Blz? Fala reset para resetar seu lvl ou diga resets. Cuidado ao resetar seu level voltara ao 30 e sua velocidade tambem!"/>
</parameters>
</npc>
Agora vai em Data>Npcs>Scripts
cria uma pasta reset.lua e bota isso dentro
-- config
minlevel = 25000 -- level para resetar
price = 500000 -- dinheiro para pagar ao resetar
newlevel = 30 -- level após reset
newexp = 368300 -- nova experiencia após reset
-- end config
function addReset(cid)
resets = getResets(cid)
setPlayerStorageValue(cid,36874,resets+1)
return true
end
function getResets(cid)
resets = getPlayerStorageValue(cid,36874)
if resets < 0 then
resets = 0
end
return resets
end
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, 'reset') then
selfSay('Do you want to reset your character level? Your character will be logged off if you confirm. You must pay '..price..' gold coins to reset.', cid)
talkState[talkUser] = 1
elseif(msgcontains(msg, 'yes') and talkState[talkUser] == 1) then
if getPlayerMoney(cid) < price then
selfSay('You must pay '..price..' gold coins to reset.', cid)
elseif getPlayerLevel(cid) < minlevel then
selfSay('You must be at least level '.. minlevel ..' to reset.', cid)
else
doPlayerRemoveMoney(cid,price)
addReset(cid)
playerid = getPlayerGUID(cid)
doRemoveCreature(cid)
db.executeQuery("UPDATE `players` SET `level`="..newlevel..",`experience`="..newexp.." WHERE `players`.`id`= ".. playerid .."")
end
talkState[talkUser] = 0
elseif(msgcontains(msg, 'no') and isInArray({1}, talkState[talkUser]) == TRUE) then
talkState[talkUser] = 0
selfSay('Ok.', cid)
elseif msgcontains(msg, 'resets') then
selfSay('You have '..getResets(cid)..' reset(s).', cid)
end
return true
end
npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback)
npcHandler:addModule(FocusModule:new())
Se Gostar da um Rep + ae dps tu edita o lvl que ele reseta , qanto ele paga , o level que ele volta dps tals !
Contato: DevilMoon@Xtibia.com
Aaai o sistema eu ja achei agora quero tipo um igual do rozin quero abrender como colocar , ex : da reset muda a classe ganha spells novos ii fica mais forte , me ajuda a procurar vlw.. Abraçç aah ii ja te dei ++ pontos me da aii tbm vlw fuiiiz . te ++
sahusha o mapa fala pelo pvt o script ta ai dps tu edita ok?
ok vai em DATA>NPC
cria uma pasta xml ou copia de outro npc renomeia para Reseter e bota isso dentro
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Reseter" script="reset.lua" walkinterval="2000" floorchange="0">
<health now="150" max="150"/>
<look type="115" head="115" body="0" legs="114" feet="0" addons="3" corpse="2212"/>
<parameters>
<parameter key="module_shop" value="1"/>
<parameter key="message_greet" value="Eae |PLAYERNAME| Tudu Blz? Fala reset para resetar seu lvl ou diga resets. Cuidado ao resetar seu level voltara ao 30 e sua velocidade tambem!"/>
</parameters>
</npc>
Agora vai em Data>Npcs>Scripts
cria uma pasta reset.lua e bota isso dentro
-- config
minlevel = 25000 -- level para resetar
price = 500000 -- dinheiro para pagar ao resetar
newlevel = 30 -- level após reset
newexp = 368300 -- nova experiencia após reset
-- end config
function addReset(cid)
resets = getResets(cid)
setPlayerStorageValue(cid,36874,resets+1)
return true
end
function getResets(cid)
resets = getPlayerStorageValue(cid,36874)
if resets < 0 then
resets = 0
end
return resets
end
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, 'reset') then
selfSay('Do you want to reset your character level? Your character will be logged off if you confirm. You must pay '..price..' gold coins to reset.', cid)
talkState[talkUser] = 1
elseif(msgcontains(msg, 'yes') and talkState[talkUser] == 1) then
if getPlayerMoney(cid) < price then
selfSay('You must pay '..price..' gold coins to reset.', cid)
elseif getPlayerLevel(cid) < minlevel then
selfSay('You must be at least level '.. minlevel ..' to reset.', cid)
else
doPlayerRemoveMoney(cid,price)
addReset(cid)
playerid = getPlayerGUID(cid)
doRemoveCreature(cid)
db.executeQuery("UPDATE `players` SET `level`="..newlevel..",`experience`="..newexp.." WHERE `players`.`id`= ".. playerid .."")
end
talkState[talkUser] = 0
elseif(msgcontains(msg, 'no') and isInArray({1}, talkState[talkUser]) == TRUE) then
talkState[talkUser] = 0
selfSay('Ok.', cid)
elseif msgcontains(msg, 'resets') then
selfSay('You have '..getResets(cid)..' reset(s).', cid)
end
return true
end
npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback)
npcHandler:addModule(FocusModule:new())
Se Gostar da um Rep + ae
dps tu edita o lvl que ele reseta , qanto ele paga , o level que ele volta dps tals !
Como funciona esse reset?
Falamos com o npc e resetamos, mas o que acontece, sem ser voltar ao lvl 30, quais são as vantagens de resetar?
Cumprimentos, ~DragoR~
Meus Trabalhos:
Monstros Do Update (e Muito +)
~~Metas:~~
[X]1post
[X]5 posts (SERVO)
[X]10 posts (CAMPONÊS)
[X]25 posts (CAÇADOR)
[X]50 posts (CAVALEIRO)
[X]100 posts (BARONETE)
[ ]200 posts (BARÃO)
[ ]300 posts (VISCONDE)
[ ]400 posts (DUQUE)
[ ]600 posts (ARQUEDUQUE)
[ ]800 posts (ARISTOCRATA)
[ ]1000 posts (REGENTE)
[ ]1400 posts (SÁBIO)
[ ]1800 posts (SACERDOTE)
[ ]2500 posts (PRÍNCIPE)
voce fica com o mesmo hp e mana
sendo que anets do reset vc tinha 1000 hp / 1000 mana
ai vc reseto fico tudo igual,a vantagem é que ainda ao upar vai poder ficar com mais mana e hp ainda
voce fica com o mesmo hp e mana
sendo que anets do reset vc tinha 1000 hp / 1000 mana
ai vc reseto fico tudo igual,a vantagem é que ainda ao upar vai poder ficar com mais mana e hp ainda
Hum, entendi, parece muito útil, especialmente para knights e mages (paladino não usa tanto a mana ou a vida para atacar)^^
Cumprimentos, ~DragoR~
Meus Trabalhos:
Monstros Do Update (e Muito +)
~~Metas:~~
[X]1post
[X]5 posts (SERVO)
[X]10 posts (CAMPONÊS)
[X]25 posts (CAÇADOR)
[X]50 posts (CAVALEIRO)
[X]100 posts (BARONETE)
[ ]200 posts (BARÃO)
[ ]300 posts (VISCONDE)
[ ]400 posts (DUQUE)
[ ]600 posts (ARQUEDUQUE)
[ ]800 posts (ARISTOCRATA)
[ ]1000 posts (REGENTE)
[ ]1400 posts (SÁBIO)
[ ]1800 posts (SACERDOTE)
[ ]2500 posts (PRÍNCIPE)
aff isso eu seei eu quero que quando resetar .. exemplo: sou druid , falei !reset,aii vira super druid
tpw então faz assim
if getPlayerVocation(cid) == 5 then doPlayerSetVocation(cid, 9) end
5 = id da voc da druid
9 = id da voc da super druid
tpw então faz assim
if getPlayerVocation(cid) == 5 then doPlayerSetVocation(cid, 9) end
5 = id da voc da druid
9 = id da voc da super druid
Onde coloca isso no script? No começo?
Cumprimentos, ~DragoR~
Meus Trabalhos:
Monstros Do Update (e Muito +)
~~Metas:~~
[X]1post
[X]5 posts (SERVO)
[X]10 posts (CAMPONÊS)
[X]25 posts (CAÇADOR)
[X]50 posts (CAVALEIRO)
[X]100 posts (BARONETE)
[ ]200 posts (BARÃO)
[ ]300 posts (VISCONDE)
[ ]400 posts (DUQUE)
[ ]600 posts (ARQUEDUQUE)
[ ]800 posts (ARISTOCRATA)
[ ]1000 posts (REGENTE)
[ ]1400 posts (SÁBIO)
[ ]1800 posts (SACERDOTE)
[ ]2500 posts (PRÍNCIPE)
tpw então faz assim
if getPlayerVocation(cid) == 5 then doPlayerSetVocation(cid, 9) end
5 = id da voc da druid
9 = id da voc da super druid
Onde coloca isso no script? No começo?
Você ira colocar no meio Disso :
doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)))doRemoveCreature(cid)
Então ficara assim :
doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) if getPlayerVocation(cid) == 5 then doPlayerSetVocation(cid, 9) doRemoveCreature(cid)
Eu nao conseguir add npc no meu mapa pf me ajudem (
msn : david.s.83@hotmail.com
?
Hm... Parece ser bom eu editei tals' eu tentei fazer direitinho mais o npc nao cria
Att ~
Yoroshi.