Por vmAth, 17 de abr. de 2013 em Mods, funções e outros
info
Grupo: Artesão
Registrado: 16/04/13
Posts: 126
Reputação: +40
É um simples MOD que conta quantos monstros você ja matou.
Ele exibe em seu look e você tambÉm pode consultar pela talkaction !monsters
Logo mais vou aprimorá-lo, e colocar ranks (:
Para instalar basta você ir na pasta servidor/data/mods ou só servidor/mods, criar o arquivo monsterskill.xml e colocar lá:
<?xml version = "1.0" encoding = "UTF-8"?> <mod name="Monsters Kill" version="1.0" author="Renato Ribeiro" enabled="yes"> <config name="config-monsterskill"><![CDATA[ storage = 1647 killedMonsters = getPlayerStorageValue(cid, storage) ]]></config> <event type="look" name="monsterLook" event="script"><![CDATA[ domodlib("config-monsterskill") function onLook(cid, thing, position, lookDistance) if(isPlayer(thing.uid)) then doPlayerSetSpecialDescription(thing.uid, "\n Killed Monsters: " .. killedMonsters) end return TRUE end ]]></event> <event type="kill" name="monsterKill" event="script"><![CDATA[ domodlib("config-monsterskill") function onKill(cid, target) if(isMonster(target)) then setPlayerStorageValue(cid, storage, math.max(1, getPlayerStorageValue(cid, storage) + 1)) end return TRUE end ]]></event> <event type="login" name="monsterLogin" event="script"><![CDATA[ function onLogin(cid) registerCreatureEvent(cid, "monsterLook") registerCreatureEvent(cid, "monsterKill") return TRUE end ]]></event> <talkaction words="!monsters" event="script"><![CDATA[ domodlib("config-monsterskill") function onSay(cid, words, param, channel) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have killed " .. killedMonsters .. " monsters at the moment") return TRUE end ]]></talkaction> </mod>
Créditos: Renato
Grupo: Conde
Registrado: 29/10/12
Posts: 789
Reputação: +146
Muito bom! Gostei do script (da ideia). Obrigado por compartilhar conosco!
Abraços.
info
Grupo: Artesão
Registrado: 16/04/13
Posts: 126
Reputação: +40
É um simples MOD que conta quantos monstros você ja matou.
Ele exibe em seu look e você tambÉm pode consultar pela talkaction !monsters
Logo mais vou aprimorá-lo, e colocar ranks (:
Para instalar basta você ir na pasta servidor/data/mods ou só servidor/mods, criar o arquivo monsterskill.xml e colocar lá:
<?xml version = "1.0" encoding = "UTF-8"?> <mod name="Monsters Kill" version="1.0" author="Renato Ribeiro" enabled="yes"> <config name="config-monsterskill"><![CDATA[ storage = 1647 killedMonsters = getPlayerStorageValue(cid, storage) ]]></config> <event type="look" name="monsterLook" event="script"><![CDATA[ domodlib("config-monsterskill") function onLook(cid, thing, position, lookDistance) if(isPlayer(thing.uid)) then doPlayerSetSpecialDescription(thing.uid, "\n Killed Monsters: " .. killedMonsters) end return TRUE end ]]></event> <event type="kill" name="monsterKill" event="script"><![CDATA[ domodlib("config-monsterskill") function onKill(cid, target) if(isMonster(target)) then setPlayerStorageValue(cid, storage, math.max(1, getPlayerStorageValue(cid, storage) + 1)) end return TRUE end ]]></event> <event type="login" name="monsterLogin" event="script"><![CDATA[ function onLogin(cid) registerCreatureEvent(cid, "monsterLook") registerCreatureEvent(cid, "monsterKill") return TRUE end ]]></event> <talkaction words="!monsters" event="script"><![CDATA[ domodlib("config-monsterskill") function onSay(cid, words, param, channel) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have killed " .. killedMonsters .. " monsters at the moment") return TRUE end ]]></talkaction> </mod>Créditos: Renato