Ir para conteúdo

Featured Replies

Postado
  • Autor

@Brunds nao acho que isso tenha alguma relação pois eu mudei de tudo os nomes e outro, ali encima eu comentei

1 hora atrás, Pepeco disse:

@Brunds eu ja mudei o nome dos outros, e mesmo assim ele nao vende, a um tempo atras tentei vender itens com outro npc que só vendia os itens novos, mas mesmo assim nao deu, OBS: Não existiam nomes iguais.

  Mostrar conteúdo oculto

</item>
        <item id="12666" article="a" name="health potion">
        <attribute key="weight" value="270"/>
    </item>
        <item id="12667" article="a" name="strong health potion">
        <attribute key="description" value="This potion can only be consumed by knights and paladins of level 50 or higher."/>
        <attribute key="weight" value="290"/>
    </item>
        <item id="12668" article="a" name="great health potion">
        <attribute key="description" value="This potion can only be consumed by knights of level 80 or higher."/>
        <attribute key="weight" value="310"/>
    </item>
        <item id="12669" article="an" name="ultimate health potion">
        <attribute key="description" value="This potion can only be consumed by knights of level 130 or higher."/>
        <attribute key="weight" value="310"/>
    </item>
        <item id="12670" article="a" name="mana potion">
        <attribute key="weight" value="270"/>
    </item>
        <item id="12671" article="a" name="strong mana potion">
        <attribute key="description" value="This potion can only be consumed by sorcerers, druids and paladins of level 50 or higher."/>
        <attribute key="weight" value="290"/>
    </item>
        <item id="12672" article="a" name="great mana potion">
        <attribute key="description" value="This potion can only be consumed by sorcerers and druids of level 80 or higher."/>
        <attribute key="weight" value="310"/>
    </item>
        <item id="12673" article="a" name="great spirit potion">
        <attribute key="description" value="This potion can only be consumed by paladins of level 80 or higher."/>
        <attribute key="weight" value="310"/>
    </item>

 

  Mostrar conteúdo oculto

    <item id="8472" article="a" name="great spirit potion INF">
        <attribute key="description" value="This potion can only be consumed by paladins of level 80 or higher."/>
        <attribute key="weight" value="310"/>
    </item>
    <item id="8473" article="an" name="ultimate health potion INF">
        <attribute key="description" value="This potion can only be consumed by knights of level 130 or higher."/>
        <attribute key="weight" value="310"/>
    </item>

 como voce pode ver os potions do tibia, estao com os nomes mudados ja

 

  • Respostas 29
  • Visualizações 814
  • Created
  • Última resposta

Top Posters In This Topic

Postado
15 minutos atrás, Pepeco disse:

@Brunds nao acho que isso tenha alguma relação pois eu mudei de tudo os nomes e outro, ali encima eu comentei

 

qual a versão do seu servidor?

Compre seus Scripts Agora totalmente seguro e de forma rápida, aceitamos também encomendas.

discord.gg/phJZeHa2k4

 

Projeto ATS (Naruto)

Informações Abaixo

Facebook

Youtube
Discord

 

Tutoriais / Conteúdos

Clique Aqui

Postado
Agora, Pepeco disse:

8.6 @Brunds

vamos fazer um pequeno test faça uma copia do seu e troque por essa

 

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

local shopModule = ShopModule:new()
npcHandler:addModule(shopModule)

shopModule:addBuyableItem({'spellbook'}, 2175, 150, 'spellbook')

local items = {[1] = 2190, [2] = 2182, [5] = 2190, [6] = 2182}
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, 'desability ronnd') or msgcontains(msg, 'desability wannnd')) then
		if(isSorcerer(cid) or isDruid(cid)) then
			if(getPlayerStorageValue(cid, 30002) <= 0) then
				selfSay('So you ask me for a {' .. getItemNameById(items[getPlayerVocation(cid)]) .. '} to begin your advanture?', cid)
				talkState[talkUser] = 1
			else
				selfSay('What? I have already gave you one {' .. getItemNameById(items[getPlayerVocation(cid)]) .. '}!', cid)
			end
		else
			selfSay('Sorry, you aren\'t a druid either a sorcerer.', cid)
		end
	elseif(msgcontains(msg, 'yes')) then
		if(talkState[talkUser] == 1) then
			doPlayerAddItem(cid, items[getPlayerVocation(cid)], 1)
			selfSay('Here you are young adept, take care yourself.', cid)
			setPlayerStorageValue(cid, 30002, 1)
		end
		talkState[talkUser] = 0
	elseif(msgcontains(msg, 'no') and isInArray({1}, talkState[talkUser])) then
		selfSay('Ok then.', cid)
		talkState[talkUser] = 0
	end

	return true
end

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

se o seu ot tiver on fale /reload npcs e tente comprar o spellbook

 

Compre seus Scripts Agora totalmente seguro e de forma rápida, aceitamos também encomendas.

discord.gg/phJZeHa2k4

 

Projeto ATS (Naruto)

Informações Abaixo

Facebook

Youtube
Discord

 

Tutoriais / Conteúdos

Clique Aqui

Postado
  • Autor

@Brunds acho que voce nao entendeu, o npc vende qualquer item, só nao vende os novos, os itens estao tudo certinhos, o problema esta com o npc em vender os novos itens, ja tentei usar tbm o 

parameter key="shop_buyable"

no xml dele, mas nao vai, será que é a distro ou o client?  disseram para mim que pode ser o client, mas eu acho que seja a distro :/ 

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.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.6k

Informação Importante

Confirmação de Termo