thiagotop 0 Posted March 2, 2013 Share Posted March 2, 2013 no meu ot os cara upa muita a ml eu queria por um limite na ml . alguem pode me ajuda ? Link to comment Share on other sites More sharing options...
0 ADMMario 2 Posted March 2, 2013 Share Posted March 2, 2013 Amigo limite não recomendo porque da uma sensação de "Terminar de ser mage". abaixa um pouco a ml é minha opinião. Link to comment Share on other sites More sharing options...
0 Roksas 846 Posted March 2, 2013 Share Posted March 2, 2013 Tenta assim: Em data/creaturescripts/scripts, crie um arquivo chamado maxml.lua e adicione dentro: local config = { mlevel = 200, -- ML MAX msg = "Parabéns, você chegou ao ML Máximo!", -- Mensagem enviada quando atingir o level necessário. msgtype = MESSAGE_EVENT_ADVANCE -- Tipo da mensagem enviada. } function onAdvance(cid, oldLevel, newLevel) registerCreatureEvent(cid, "mlmax") if getPlayerMagLevel(cid) >= config.mlevel then doPlayerAddMagicLevel(cid,-1) doPlayerSendTextMessage(cid, config.msgtype, config.msg) end return TRUE end Agora em creaturescripts.xml adicione essa tag: <event type="advance" name="mlmax" event="script" value="maxml.lua"/> E no arquivo login.lua da pasta scripts, mais ou menos no final adicione: registerCreatureEvent(cid, "mlmax") Link to comment Share on other sites More sharing options...
0 SkyDarkyes 104 Posted March 2, 2013 Share Posted March 2, 2013 Poksas,o mapa que o cara deve ta usando provavelmente é igual o meu Link to comment Share on other sites More sharing options...
0 Slicer 1070 Posted March 2, 2013 Share Posted March 2, 2013 ngm reparo q ele ta em ATENDIMENTO neh? @rok ve se começa a ver aonde esta o topico antes de responder mano... ;x Link to comment Share on other sites More sharing options...
0 Roksas 846 Posted March 2, 2013 Share Posted March 2, 2013 Perdão, área incorreta, reported. Link to comment Share on other sites More sharing options...
0 Lordfire 309 Posted March 2, 2013 Share Posted March 2, 2013 Porra tu ainda não aprendeu a olhar a seção hein Link to comment Share on other sites More sharing options...
0 SkyLigh 453 Posted March 2, 2013 Share Posted March 2, 2013 Utilize o script do roksas assim . local config = { mlevel = 200, -- ML MAX msg = "Parabéns, você chegou ao ML Máximo!", -- Mensagem enviada quando atingir o level necessário. msgtype = MESSAGE_EVENT_ADVANCE -- Tipo da mensagem enviada. } function onAdvance(cid, oldLevel, newLevel) registerCreatureEvent(cid, "mlmax") if getPlayerMagLevel(cid) >= config.mlevel then doPlayerAddMagicLevel(cid,-1) doPlayerSendTextMessage(cid, config.msgtype, config.msg) end return TRUE end e ponha isso no login.lua registerCreatureEvent(cid,"mlmax") havia mais de 1 espaço no script . e na linha Link to comment Share on other sites More sharing options...
0 SkyDarkyes 104 Posted March 7, 2013 Share Posted March 7, 2013 local config = { mlevel = 200, -- ML MAX msg = "Parabéns, você chegou ao ML Máximo!", -- Mensagem enviada quando atingir o level necessário. msgtype = MESSAGE_EVENT_ADVANCE -- Tipo da mensagem enviada. } function onAdvance(cid, oldLevel, newLevel) registerCreatureEvent(cid, "mlmax") if getPlayerMagLevel(cid) >= config.mlevel then doPlayerAddMagicLevel(cid,-1) doPlayerSendTextMessage(cid, config.msgtype, config.msg) end return TRUE end Tem como tirar essa mensagem? Link to comment Share on other sites More sharing options...
0 Roksas 846 Posted March 7, 2013 Share Posted March 7, 2013 local config = { mlevel = 200, -- ML MAX } function onAdvance(cid, oldLevel, newLevel) registerCreatureEvent(cid, "mlmax") if getPlayerMagLevel(cid) >= config.mlevel then doPlayerAddMagicLevel(cid,-1) end return TRUE end Link to comment Share on other sites More sharing options...
0 SkyLigh 453 Posted March 8, 2013 Share Posted March 8, 2013 local config = { mlevel = 200, -- ML MAX } function onAdvance(cid, oldLevel, newLevel) registerCreatureEvent(cid, "mlmax") if getPlayerMagLevel(cid) >= config.mlevel then doPlayerAddMagicLevel(cid,-1) end return TRUE end Link to comment Share on other sites More sharing options...
0 Slicer 1070 Posted March 8, 2013 Share Posted March 8, 2013 /\ isso n vai funcionar, e tem q registrar no login e n no proprio arquivo Link to comment Share on other sites More sharing options...
0 StackMinute 13 Posted March 8, 2013 Share Posted March 8, 2013 (edited) wtf??? porque vocês tão registrando o creature event no proprio script? assim acho que dá... ;x local mn = 120 function onAdvance(cid, oldLevel, newLevel) if getPlayerMagLevel(cid) >= mn then doPlayerSetMagicRate(cid, -getPlayerMagRate(cid)) end return true end As tags são as mesmas do Roksas lá em cima Edited March 8, 2013 by StackMinute Link to comment Share on other sites More sharing options...
0 Skymagnum 234 Posted March 13, 2013 Share Posted March 13, 2013 local max = ? function onAdvance(cid, skill, oldLevel, newLevel) if skill == 7 then if newLevel >= max then return false end end return true end Link to comment Share on other sites More sharing options...
0 phardole 5 Posted March 13, 2013 Share Posted March 13, 2013 Galera não ta funcionando aqui.. testei todos ai encima e ta dando isso aqui... [Error - CreatureScript Interface] data/creaturescripts/scripts/maxml.lua:onAdvance Description: data/creaturescripts/scripts/maxml.lua:5: attempt to call global 'getPlayerMagRate' (a nil value) stack traceback: data/creaturescripts/scripts/maxml.lua:5: in function <data/creaturescripts/scripts/maxml.lua:3> Link to comment Share on other sites More sharing options...
0 Skymagnum 234 Posted March 13, 2013 Share Posted March 13, 2013 usa o meu Link to comment Share on other sites More sharing options...
Question
thiagotop 0
no meu ot os cara upa muita a ml eu queria por um limite na ml .
alguem pode me ajuda ?
Link to comment
Share on other sites
Top Posters For This Question
11
11
10
4
Popular Days
Mar 13
30
Mar 14
6
Mar 2
6
Mar 7
5
Top Posters For This Question
Demonbholder 11 posts
SkyDarkyes 11 posts
phardole 10 posts
Roksas 4 posts
Popular Days
Mar 13 2013
30 posts
Mar 14 2013
6 posts
Mar 2 2013
6 posts
Mar 7 2013
5 posts
52 answers to this question
Recommended Posts