Ir para conteúdo

Posts Recomendados

Iae galera do xtibia

queria saber como troca a outfit que os master dos clan dão!

tipo eu qro mudar a outfit que o npc da

USO pda

Malefic master.lua

 

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, 'clan') or msgcontains(msg, 'Clan')) then --alterado v1.7
if getPlayerClanName(cid) == 'Malefic' then --alterado v1.7
selfSay("You already are of the clan malefic!", cid)
talkState[talkUser] = 0
return true
elseif getPlayerClanNum(cid) ~= -1 then --alterado v1.7
selfSay("You already are of another clan!", cid)
talkState[talkUser] = 0
return true
end
selfSay("So you want to join in my clan... Are you sure that?", cid)
talkState[talkUser] = 2
elseif (msgcontains(msg, 'yes') or msgcontains(msg, 'Yes')) and talkState[talkUser] == 2 then
if getPlayerLevel(cid) < 80 then
selfSay("You are too weak yet... You need to be atleast level 80 to enter in the clan!", cid)
talkState[talkUser] = 0
return true
end
selfSay("OK then... Now you are a great member of de clan malefic!", cid)
setPlayerClan(cid, 'Malefic') --alterado v1.7
talkState[talkUser] = 0


elseif (msgcontains(msg, 'leave') or msgcontains(msg, 'Leave')) then --alterado v1.7 \/
if getPlayerClanName(cid) ~= 'Malefic' then
selfSay("You aren't of the clan, get out of here!", cid)
talkState[talkUser] = 0
return true
else
selfSay("So you want to leave the clan... Are you sure that?", cid)
talkState[talkUser] = 3
end
elseif (msgcontains(msg, 'yes') or msgcontains(msg, 'Yes')) and talkState[talkUser] == 3 then
if removePlayerClan(cid) then
selfSay("Ok then, good luck!", cid)
talkState[talkUser] = 0
return true
else
selfSay("You have some task to finish of one trainer! Go finish it!", cid)
talkState[talkUser] = 0
return true
end


elseif (msgcontains(msg, 'shiny') or msgcontains(msg, 'Shiny')) then --alterado v1.7
if getPlayerClanName(cid) ~= 'Malefic' then --alterado v1.7
selfSay("You aren't of the clan Malefic! Get out of here!", cid)
return true
else
selfSay("So you want to transform your Nidoking in a Shiny Nidoking? It will cost 500k!", cid)
talkState[talkUser] = 4
end
elseif (msgcontains(msg, 'yes') or msgcontains(msg, 'Yes')) and talkState[talkUser] == 4 then
if getPlayerSlotItem(cid, 8).uid <= 0 then
selfSay("Sorry, you don't have a pokemon in the main slot!", cid)
talkState[talkUser] = 0
return true
end
--alterado v1.2
if #getCreatureSummons(cid) >= 1 then
selfSay("Go back your pokemon!", cid)
talkState[talkUser] = 0
return true
end

local pb = getPlayerSlotItem(cid, 8).uid

if getItemAttribute(pb, "poke") ~= "Nidoking" then
selfSay("Put a Nidoking's pokeball atleast +20 in main slot!", cid)
talkState[talkUser] = 0
return true
end

if not getItemAttribute(pb, "boost") or getItemAttribute(pb, "boost") < 20 then
selfSay("Sorry, your Nidoking is not boosted +20!", cid)
talkState[talkUser] = 0
return true
end
--100000 = 1k, 1000000 = 10k, 10000000 = 100k
if doPlayerRemoveMoney(cid, 50000000) == true then
selfSay("So there is it! Enjoy!", cid)
doItemSetAttribute(pb, "hp", 1)
doItemSetAttribute(pb, "poke", "Shiny Nidoking")
doItemSetAttribute(pb, "description", "Contains a Shiny Nidoking.")
doItemEraseAttribute(pb, "boost")
doTransformItem(getPlayerSlotItem(cid, 7).uid, fotos["Shiny Nidoking"])
if useKpdoDlls then
doCreatureExecuteTalkAction(cid, "/pokeread")
end
talkState[talkUser] = 0
return true
else
selfSay("You don't have enough money!", cid)
talkState[talkUser] = 0
return true
end
end

return true
end

npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback)
npcHandler:addModule(FocusModule:new())

 

 

Malefic master.xml

 

 

<?xml version="1.0" encoding="UTF-8"?>

<npc name="Malefic Master" script=".malefic master.lua" walkinterval="0" floorchange="0" access="5" level="1" maglevel="1">
<health now="150" max="150"/>
<look type="1430" head="114" body="119" legs="114" feet="114" corpse="2212"/>
<parameters>
<parameter key="message_greet" value="Welcome |PLAYERNAME|, you want to join to my {clan}? Or you want to move up of {rank}? Or you want to transform you poke in a {shiny}?"/>
</parameters>
</npc>

 

 

 

Outfit atual: Male: 1167 Female: 1176

 

Nova Outfit: Male: 1428 Female: 1430

Editado por xandeloko
Link para o comentário
Compartilhar em outros sites

Inves de vc botar a looktype da outfit , bota a quest dela. Exemplo:

<outfit id="17" quest="181615">
<list gender="0" lookType="1153" name="Malefic"/>
<list gender="1" lookType="1157" name="Malefic"/>
</outfit>
pda é por storage(quest) ^^
Link para o comentário
Compartilhar em outros sites

Não... O npc nao da a looktype. Ele da uma storage(valor) , aquilo <outfit id="17" quest="181615">

<list gender="0" lookType="1153" name="Malefic"/>
<list gender="1" lookType="1157" name="Malefic"/>
</outfit>
é o valor, vc pega o antigo, da ctrl+f no npc procura e altera o valor antigo pelo valor que se quer da nova outfit
pronto.
Link para o comentário
Compartilhar em outros sites

Vai no teu outfits.xml (data/xml), e procura por " PROMOTE MASTER ", agora tu pega os ids " quest="181630"> " de cada um e vai em Clan System.lua na pasta lib e procura por " local clansName = { ", agora só trocar os ids.

Deixe o seu assim:

[1] = {'Volcanic', 181613, 181634},
[2] = {'Seavell', 181619, 181631},
[3] = {'Orebound', 181620, 181636},
[4] = {'Wingeon', 181616, 181635},
[5] = {'Malefic', 181615, 181633},
[6] = {'Gardestrike', 181614, 181637},
[7] = {'Psycraft', 181618, 181638},
[8] = {'Naturia', 181612, 181632},
[9] = {'Raibolt', 181617, 181630},
}
Link para o comentário
Compartilhar em outros sites

ta ae o outifts.xml

 

 

<?xml version="1.0"?>

<outfits>
<!-- NORMAL -->
<outfit id="1">
<list gender="0" lookType="511" name="Trainer"/>
<list gender="1" lookType="510" name="Trainer"/>
</outfit>
<outfit id="2" premium="yes">
<list gender="0" lookType="615" name="Elite Trainer"/>
<list gender="1" lookType="614" name="Elite Trainer"/>
</outfit>
<outfit id="3" premium="yes" quest="181602">
<list gender="0" lookType="512" name="Rapper"/>
<list gender="1" lookType="545" name="Rapper"/>
</outfit>
<outfit id="4" premium="yes" quest="181601">
<list gender="0" lookType="588" name="Jamaican"/>
<list gender="1" lookType="587" name="Jamaican"/>
</outfit>
<outfit id="5" premium="yes" quest="181603">
<list gender="0" lookType="586" name="Oriental"/>
<list gender="1" lookType="585" name="Oriental"/>
</outfit>
<outfit id="6" quest="181604">
<list gender="0" lookType="605" name="Rocket"/>
<list gender="1" lookType="604" name="Rocket"/>
</outfit>
<outfit id="7" premium="yes" quest="181605">
<list gender="0" lookType="495" name="Adventurer"/>
<list gender="1" lookType="494" name="Adventurer"/>
</outfit>
<outfit id="8" premium="yes" quest="181606">
<list gender="0" lookType="513" name="Bussiness"/>
<list gender="1" lookType="1419" name="Bussiness"/>
</outfit>
<outfit id="9" premium="yes" quest="181607">
<list gender="0" lookType="517" name="Atletic"/>
<list gender="1" lookType="516" name="Atletic"/>
</outfit>
<outfit id="10" premium="yes" quest="181608">
<list gender="0" lookType="519" name="Punk"/>
<list gender="1" lookType="518" name="Punk"/>
</outfit>
<outfit id="11">
<list gender="0" lookType="521" name="Fisher"/>
<list gender="1" lookType="520" name="Fisher"/>
</outfit>
<outfit id="12" premium="yes" quest="181610">
<list gender="0" lookType="524" name="Mercenary"/>
<list gender="1" lookType="522" name="Mercenary"/>
</outfit>
<outfit id="13" premium="yes" quest="181611">
<list gender="0" lookType="525" name="Hiker"/>
<list gender="1" lookType="523" name="Hiker"/>
</outfit>
<!-- PROMOTE -->
<outfit id="14" quest="181612">
<list gender="0" lookType="1149" name="Naturia"/>
<list gender="1" lookType="1159" name="Naturia"/>
</outfit>
<outfit id="15" quest="181613">
<list gender="0" lookType="1152" name="Volcanic"/>
<list gender="1" lookType="1154" name="Volcanic"/>
</outfit>
<outfit id="16" quest="181614">
<list gender="0" lookType="1146" name="Gardestrike"/>
<list gender="1" lookType="1155" name="Gardestrike"/>
</outfit>
<outfit id="17" quest="181615">
<list gender="0" lookType="1153" name="Malefic"/>
<list gender="1" lookType="1157" name="Malefic"/>
</outfit>
<outfit id="18" quest="181616">
<list gender="0" lookType="1148" name="Wingeon"/>
<list gender="1" lookType="1158" name="Wingeon"/>
</outfit>
<outfit id="19" quest="181617">
<list gender="0" lookType="1147" name="Raibolt"/>
<list gender="1" lookType="1160" name="Raibolt"/>
</outfit>
<outfit id="20" quest="181618">
<list gender="0" lookType="1145" name="Psycraft"/>
<list gender="1" lookType="1161" name="Psycraft"/>
</outfit>
<outfit id="21" quest="181619">
<list gender="0" lookType="1151" name="Seavell"/>
<list gender="1" lookType="1162" name="Seavell"/>
</outfit>
<outfit id="22" quest="181620">
<list gender="0" lookType="1150" name="Orebound"/>
<list gender="1" lookType="1156" name="Orebound"/>
</outfit>
<!-- PROMOTE RANK 5 -->
<outfit id="23" quest="181621">
<list gender="0" lookType="1179" name="Raibolt Legend"/>
<list gender="1" lookType="1164" name="Raibolt Legend"/>
</outfit>
<outfit id="24" quest="181622">
<list gender="0" lookType="1178" name="Seavell Queen"/>
<list gender="1" lookType="1165" name="Seavell King"/>
</outfit>
<outfit id="25" quest="181623">
<list gender="0" lookType="1177" name="Naturia Keeper"/>
<list gender="1" lookType="1166" name="Naturia Keeper"/>
</outfit>
<outfit id="26" quest="181624">
<list gender="0" lookType="1176" name="Malefic Lady"/>
<list gender="1" lookType="1167" name="Malefic Lord"/>
</outfit>
<outfit id="27" quest="181625">
<list gender="0" lookType="1180" name="Volcanic Master"/>
<list gender="1" lookType="1168" name="Volcanic Master"/>
</outfit>
<outfit id="28" quest="181626">
<list gender="0" lookType="1175" name="Wingeon Dragon"/>
<list gender="1" lookType="1169" name="Wingeon Dragon"/>
</outfit>
<outfit id="29" quest="181627">
<list gender="0" lookType="1174" name="Orebound Hero"/>
<list gender="1" lookType="1170" name="Orebound Hero"/>
</outfit>
<outfit id="30" quest="181628">
<list gender="0" lookType="1173" name="Gardestrike Lady"/>
<list gender="1" lookType="1171" name="Gardestrike Champion"/>
</outfit>
<outfit id="31" quest="181629">
<list gender="0" lookType="1181" name="Psycraft Medium"/>
<list gender="1" lookType="1172" name="Psycraft Medium"/>
</outfit>
<!-- PROMOTE MASTER -->
<outfit id="32" quest="181630">
<list gender="0" lookType="1437" name="Raibolt Master"/>
<list gender="1" lookType="1421" name="Raibolt Master"/>
</outfit>
<outfit id="33" quest="181631">
<list gender="0" lookType="1438" name="Seavell Master"/>
<list gender="1" lookType="1422" name="Seavell Master"/>
</outfit>
<outfit id="34" quest="181632">
<list gender="0" lookType="1434" name="Naturia Master"/>
<list gender="1" lookType="1423" name="Naturia Master"/>
</outfit>
<outfit id="35" quest="181633">
<list gender="0" lookType="1430" name="Malefic Master"/>
<list gender="1" lookType="1428" name="Malefic Master"/>
</outfit>
<outfit id="36" quest="181634">
<list gender="0" lookType="1432" name="Volcanic Superior"/>
<list gender="1" lookType="1425" name="Volcanic Superior"/>
</outfit>
<outfit id="37" quest="181635">
<list gender="0" lookType="1433" name="Wingeon Master"/>
<list gender="1" lookType="1424" name="Wingeon Master"/>
</outfit>
<outfit id="38" quest="181636">
<list gender="0" lookType="1436" name="Orebound Master"/>
<list gender="1" lookType="1427" name="Orebound Master"/>
</outfit>
<outfit id="39" quest="181637">
<list gender="0" lookType="1431" name="Gardestrike Master"/>
<list gender="1" lookType="1429" name="Gardestrike Master"/>
</outfit>
<outfit id="40" quest="181638">
<list gender="0" lookType="1435" name="Psycraft Master"/>
<list gender="1" lookType="1426" name="Psycraft Master"/>
</outfit>
<!-- GAMEMASTER -->
<outfit id="41" access = "5">
<list gender="0-3" lookType="664" name="GameMaster"/>
</outfit>
<!-- NATAL -->
<outfit id="42" quest="181639">
<list gender="0" lookType="661" name="Christmas"/>
<list gender="1" lookType="662" name="Christmas"/>
</outfit>
<outfit id="43" quest="181640">
<list gender="0" lookType="1084" name="Christmas 2"/>
<list gender="1" lookType="1083" name="Christmas 2"/>
</outfit>
<!-- HALLOWEEN -->
<outfit id="44" quest="181641">
<list gender="0-3" lookType="1140" name="Mummy"/>
</outfit>
<outfit id="45" quest="181642">
<list gender="0" lookType="1190" name="Bruxa"/>
<list gender="1" lookType="1191" name="Dracula"/>
</outfit>
<outfit id="46" quest="181643">
<list gender="0" lookType="1188" name="Caveira"/>
<list gender="1" lookType="1189" name="Diaba"/>
</outfit>
<!-- CATCHER -->
<outfit id="47" quest="181644">
<list gender="0" lookType="1414" name="Catcher"/>
<list gender="1" lookType="1413" name="Catcher"/>
</outfit>
<!-- ESPECIAIS -->
<outfit id="48" quest="181645">
<list gender="0" lookType="1016" name="Hunter"/>
<list gender="1" lookType="1015" name="Hunter"/>
</outfit>
<outfit id="49" quest="181646">
<list gender="0" lookType="1035" name="Diver"/>
<list gender="1" lookType="1034" name="Diver"/>
</outfit>
<outfit id="50" quest="181647">
<list gender="0" lookType="1408" name="Esquiadora"/>
<list gender="1" lookType="1407" name="Esquiador"/>
</outfit>
<outfit id="51" quest="181648">
<list gender="1" lookType="1441" name="Slash"/>
</outfit>
<outfit id="52" quest="181649">
<list gender="0" lookType="1442" name="Playboy"/>
</outfit>
<outfit id="53" quest="181650">
<list gender="1" lookType="1443" name="Vinganca"/>
</outfit>
<outfit id="54" quest="181651">
<list gender="1" lookType="1444" name="House"/>
</outfit>
<outfit id="55" quest="181652">
<list gender="0" lookType="1184" name="Police Officer"/>
<list gender="1" lookType="1183" name="Police Officer"/>
</outfit>
<outfit id="56" quest="181653">
<list gender="0" lookType="1466" name="Veteran Trainer"/>
<list gender="1" lookType="1465" name="Veteran Trainer"/>
</outfit>
<outfit id="57" quest="181654">
<list gender="0" lookType="1469" name="Assassin"/>
<list gender="1" lookType="1470" name="Assassin"/>
</outfit>
<outfit id="58">
<list gender="0" lookType="1441" name="Rockero"/>
</outfit>
<outfit id="59">
<list gender="0" lookType="1442" name="Playboy"/>
</outfit>
<outfit id="60">
<list gender="0" lookType="1443" name="Asesino"/>
</outfit>
<outfit id="61">
<list gender="0" lookType="1444" name="Dr House"/>
</outfit>
</outfits>

 

 

 

Outfit atual: Male: 1167 Female: 1176

Nova Outfit: Male: 1428 Female: 1430

Editado por xandeloko
Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...