Tapestry E Trophy

Conde Sapo
em Actions e Talkactions
  • 1
  • 2

Conde Sapo

avatar
Visconde
Visconde

INFOS

Grupo: ViscondeRegistrado: 14/08/07Posts: 322Char no Tibia: Conde Sapo (Secura)

procurei a resposta em site americano

achei isto aqui (não testei)

 

Put the tapestry in front of the wall that you want to put the tapestry on

------------------------------ tradução -------------------------------------------------

(Arraste o tapestry na parede que você deseja decorar)

 

tapestries.lua

function onUse(cid, item, frompos, item2, pos)

wall1 = {x=pos.x-1, y=pos.y, z=pos.z, stackpos=1}
wall1s1 = {x=pos.x-1, y=pos.y, z=pos.z, stackpos=2}
getwall1 = getThingfromPos(wall1)
getwall1s1 = getThingfromPos(wall1s1)
wall2 = {x=pos.x, y=pos.y-1, z=pos.z, stackpos=1}
wall2s1 = {x=pos.x, y=pos.y-1, z=pos.z, stackpos=2}
getwall2 = getThingfromPos(wall2)
getwall2s1 = getThingfromPos(wall2s1)

player = getPlayerPosition(cid)


if item.itemid == 1857 or item.itemid == 1860 or item.itemid == 1863 or item.itemid == 1866 or item.itemid == 1869 or item.itemid == 1872 or item.itemid == 1880 or item.itemid == 5616 then  --flat tapestry
if getwall1.itemid == 1036 or getwall1.itemid == 1040 or getwall1.itemid == 1041 or getwall1.itemid == 1042 or getwall1.itemid == 1043 or getwall1.itemid == 1044 or getwall1.itemid == 1046 or getwall1.itemid == 1049 or getwall1.itemid == 1053 or getwall1.itemid == 1054 or getwall1.itemid == 1055 or getwall1.itemid == 1056 or getwall1.itemid == 1057 or getwall1.itemid == 1059 or getwall1.itemid == 1100 or getwall1.itemid == 1104 or getwall1.itemid == 1105 or getwall1.itemid == 1106 or getwall1.itemid == 1107 or getwall1.itemid == 1108 or getwall1.itemid == 1110 or getwall1.itemid == 1111 or getwall1.itemid == 1115 or getwall1.itemid == 1116 or getwall1.itemid == 1117 or getwall1.itemid == 1119 or getwall1.itemid == 3361 or getwall1.itemid == 3365 or getwall1.itemid == 3366 or getwall1.itemid == 3367 or getwall1.itemid == 3369 or getwall1.itemid == 5261 or getwall1.itemid == 5265 or getwall1.itemid == 5266 or getwall1.itemid == 5267 or getwall1.itemid == 5268 or getwall1.itemid == 5269 or getwall1.itemid == 5271 then  --west facing
	if getwall1s1.itemid > 0 then
if getwall2.itemid == 1037 or getwall2.itemid == 1039 or getwall2.itemid == 1040 or getwall2.itemid == 1042 or getwall2.itemid == 1044 or getwall2.itemid == 1045 or getwall2.itemid == 1046 or getwall2.itemid == 1050 or getwall2.itemid == 1052 or getwall2.itemid == 1053 or getwall2.itemid == 1055 or getwall2.itemid == 1057 or getwall2.itemid == 1058 or getwall2.itemid == 1059 or getwall2.itemid == 1061 or getwall2.itemid == 1064 or getwall2.itemid == 1066 or getwall2.itemid == 1068 or getwall2.itemid == 1069 or getwall2.itemid == 1070 or getwall2.itemid == 1039 or getwall2.itemid == 1101 or getwall2.itemid == 1103 or getwall2.itemid == 1104 or getwall2.itemid == 1106 or getwall2.itemid == 1108 or getwall2.itemid == 1109 or getwall2.itemid == 1110 or getwall2.itemid == 1112 or getwall2.itemid == 1114 or getwall2.itemid == 1115 or getwall2.itemid == 1117 or getwall2.itemid == 1118 or getwall2.itemid == 1119 or getwall2.itemid == 3362 or getwall2.itemid == 3364 or getwall2.itemid == 3365 or getwall2.itemid == 3367 or getwall2.itemid == 3368 or getwall2.itemid == 3369 or getwall2.itemid == 5262 or getwall2.itemid == 5264 or getwall2.itemid == 5265 or getwall2.itemid == 5267 or getwall2.itemid == 5269 or getwall2.itemid == 5270 or getwall2.itemid == 5271 then   --south facing
			if getwall2s1.itemid > 0 then
			else
				doRemoveItem(item.uid,1)
				doCreateItem(item.itemid-2,1,wall2)
			end
		end
	else
		doRemoveItem(item.uid,1)
		doCreateItem(item.itemid-1,1,wall1)
	end
elseif getwall2.itemid == 1037 or getwall2.itemid == 1039 or getwall2.itemid == 1040 or getwall2.itemid == 1042 or getwall2.itemid == 1044 or getwall2.itemid == 1045 or getwall2.itemid == 1046 or getwall2.itemid == 1050 or getwall2.itemid == 1052 or getwall2.itemid == 1053 or getwall2.itemid == 1055 or getwall2.itemid == 1057 or getwall2.itemid == 1058 or getwall2.itemid == 1059 or getwall2.itemid == 1061 or getwall2.itemid == 1064 or getwall2.itemid == 1066 or getwall2.itemid == 1068 or getwall2.itemid == 1069 or getwall2.itemid == 1070 or getwall2.itemid == 1039 or getwall2.itemid == 1101 or getwall2.itemid == 1103 or getwall2.itemid == 1104 or getwall2.itemid == 1106 or getwall2.itemid == 1108 or getwall2.itemid == 1109 or getwall2.itemid == 1110 or getwall2.itemid == 1112 or getwall2.itemid == 1114 or getwall2.itemid == 1115 or getwall2.itemid == 1117 or getwall2.itemid == 1118 or getwall2.itemid == 1119 or getwall2.itemid == 3362 or getwall2.itemid == 3364 or getwall2.itemid == 3365 or getwall2.itemid == 3367 or getwall2.itemid == 3368 or getwall2.itemid == 3369 or getwall2.itemid == 5262 or getwall2.itemid == 5264 or getwall2.itemid == 5265 or getwall2.itemid == 5267 or getwall2.itemid == 5269 or getwall2.itemid == 5270 or getwall2.itemid == 5271 then  --south facing
	if getwall2s1.itemid > 0 then
	else
		doRemoveItem(item.uid,1)
		doCreateItem(item.itemid-2,1,wall2)
	end
end

elseif item.itemid == 1856 or item.itemid == 1859 or item.itemid == 1862 or item.itemid == 1865 or item.itemid == 1868 or item.itemid == 1871 or item.itemid == 1879 or item.itemid == 5615 then	--west facing
if (player.x == pos.x+1) then
	doPlayerAddItem(cid, item.itemid+1, 1)
	doRemoveItem(item.uid,1)	
end		
elseif item.itemid == 1855 or item.itemid == 1858 or item.itemid == 1861 or item.itemid == 1864 or item.itemid == 1867 or item.itemid == 1870 or item.itemid == 1878 or item.itemid == 5614 then  --south facing
if (player.y == pos.y+1) then	
	doRemoveItem(item.uid,1)
	doPlayerAddItem(cid, item.itemid+2, 1)	
end	
end
end

This was done for 7.81, also if you have a place where u have two walls next to each other to form a corner, it will go on the east facing wall first.

------------------------------ tradução -------------------------------------------------

(funciona pra 7.81 , entretanto se você tiver um lugar com duas paredes fazendo uma quina , o deco vai colar na parede virada pra leste)

 

Aguardo cobaias e comentarios.

-----------------------
-------------------------------


Encontro de Quake na minha Ex-LAN

odeio rapidshare

"Criticas enriquecem o trabalho dos inteligentes.
Os negligentes simplesmente as ignoram." - Conde Sapo

"A melhor recompensa do Mestre ,
é ver o Aluno superar as espectativas." - Conde Sapo



(finalmente me convenceram a fazer a Fan Bar)

Meus trabalhos :
\/------- Clicar

01 - Porta com chave numérica
02 - Efeito de MAR em movimento
03 - Fruta na Árvore (acrescentei arvore)
04 - NPC Messager
05 - Monstros Morrem Mas Nao Somem Do Mapa
06 - Simulando UnderWater
07 - SpellBook (Book 2175)
08 - CommandsSpellBook (Book 6120)
09 - Fixo: Tudo Sobre A Linguagem Lua
10 - Dice (Rolando os dados)
11 - Voodoo Skull (previsão da sorte do dia)
12 - Caça Niqueis
13 - Mapa-spawn.xml (Como funciona)
14 - Pendurando objetos na parede
15 - Santa Doll (Papai Noel)
16 - EuTeAmoVoce [Instant Spell]
17 - doSendAnimatedText (Todas as cores)
18 - NPC Banqueiro
19 - 8 Bichos (Massive Summon)
20 - Transformando Barril Simples em Barril de Mana Fluid
21 - Quebrando Itens Com Arma (Tirando BUG)
22 - Padre Marcelo (Totalmente REFEITO)
23 - Npc De Backpack ( Back Picka )
24 - Npc De Dolls ( Baby Doll )
25 - Fonte Da Juventude (Mana e Life)
26 - NPC que troca itens
27 - Removendo paredes com PAUSA, (efeito visual lindo)
28 - Halloween - Fazendo o PumpkinHead
29 - Halloween - Criando o monstro Halloween Hare
30 - Mapa pra fazer Testes (Sapo.otbm)
31 - Fishing Rod (Qualquer versão)
32 - Jungle Maw (planta que morde)
33 - Npc Stan (fantasias de Carnaval)
Clicar -------/\

genoma

genoma
avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 19/08/07Posts: 59Char no Tibia: Diabeda

Tá bem organizado, vou testar no meu serv...mas tipo, oq tem que colar no actions.xml ?

E quanto aos trophys, seria só trocar o ID dos tapestries?

Agradecido :D

SirAlquati

avatar
Barão
Barão

INFOS

Grupo: BarãoRegistrado: 16/01/07Posts: 206Char no Tibia: Thiago Shinoda

Verdade

Num tem mais nada pra por não?

 

Nenhum linha no Actions


De volta ao Xtibia.

GOD Bon

GOD Bon
avatar
Herói
Herói

INFOS

Grupo: HeróiRegistrado: 05/01/07Posts: 153

Tabom esse tutorial mas você devia ter explicado como coloca na Action para os novatos saber.

 

~~Abraços~~

 

Atenciosamente, GOD Bon.

>>>>>>>>ĞФĐ βθŋ™<<<<<<<<
Você que é meu fan use minha bar
godbon.png
zeldagodbon.png

SephyrotSin

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 22/09/07Posts: 69Char no Tibia: Nero

Ótimo tutorial, como sempre Conde Sapo xD


Jvchequer

"Veni, vidi, vici."
avatar
Lenda
Lenda

INFOS

Grupo: LendaRegistrado: 10/10/05Posts: 2161Char no Tibia: Master Chequer

Excelente action.

 

Parabéns cara.

 

 

P.S: Tópico movido para seção correta.

 

 

Sem mais.

1271330714-U1306.gif

 

~ Fiz parte da Equipe Xtibia em um tempo que Tibia era minha família. Saudades de todos vocês.

Conde Sapo

avatar
Visconde
Visconde

INFOS

Grupo: ViscondeRegistrado: 14/08/07Posts: 322Char no Tibia: Conde Sapo (Secura)

Forum extrangeiro não explica nos minimos detalhes.

 

Supõe-se que quem tá lendo é uma pessoa que tem um minimo de conhecimento.

 

Os IDs pra colocar no actions.xml estão :

 

nesta linha aqui

if item.itemid == 1857 or item.itemid == 1860 or item.itemid == 1863 or item.itemid == 1866 or item.itemid == 1869 or item.itemid == 1872 or item.itemid == 1880 or item.itemid == 5616 then

nesta linha aqui

elseif item.itemid == 1856 or item.itemid == 1859 or item.itemid == 1862 or item.itemid == 1865 or item.itemid == 1868 or item.itemid == 1871 or item.itemid == 1879 or item.itemid == 5615 then

nesta linha aqui

elseif item.itemid == 1855 or item.itemid == 1858 or item.itemid == 1861 or item.itemid == 1864 or item.itemid == 1867 or item.itemid == 1870 or item.itemid == 1878 or item.itemid == 5614 then

 

fica assim no actions.xml

<action itemid="1857" script="tapestries.lua"  />
<action itemid="1860" script="tapestries.lua"  />
<action itemid="1863" script="tapestries.lua"  />
<action itemid="1866" script="tapestries.lua"  />
<action itemid="1869" script="tapestries.lua"  />
<action itemid="1872" script="tapestries.lua"  />
<action itemid="1880" script="tapestries.lua"  />
<action itemid="5616" script="tapestries.lua"  />

<action itemid="1855" script="tapestries.lua"  />
<action itemid="1858" script="tapestries.lua"  />
<action itemid="1861" script="tapestries.lua"  />
<action itemid="1864" script="tapestries.lua"  />
<action itemid="1867" script="tapestries.lua"  />
<action itemid="1870" script="tapestries.lua"  />
<action itemid="1878" script="tapestries.lua"  />
<action itemid="5614" script="tapestries.lua"  />

<action itemid="1856" script="tapestries.lua"  />
<action itemid="1859" script="tapestries.lua"  />
<action itemid="1862" script="tapestries.lua"  />
<action itemid="1865" script="tapestries.lua"  />
<action itemid="1868" script="tapestries.lua"  />
<action itemid="1871" script="tapestries.lua"  />
<action itemid="1879" script="tapestries.lua"  />
<action itemid="5615" script="tapestries.lua"  />

Acho que não esqueci nenhum.

 

smile_positivo.gif

-----------------------
-------------------------------


Encontro de Quake na minha Ex-LAN

odeio rapidshare

"Criticas enriquecem o trabalho dos inteligentes.
Os negligentes simplesmente as ignoram." - Conde Sapo

"A melhor recompensa do Mestre ,
é ver o Aluno superar as espectativas." - Conde Sapo



(finalmente me convenceram a fazer a Fan Bar)

Meus trabalhos :
\/------- Clicar

01 - Porta com chave numérica
02 - Efeito de MAR em movimento
03 - Fruta na Árvore (acrescentei arvore)
04 - NPC Messager
05 - Monstros Morrem Mas Nao Somem Do Mapa
06 - Simulando UnderWater
07 - SpellBook (Book 2175)
08 - CommandsSpellBook (Book 6120)
09 - Fixo: Tudo Sobre A Linguagem Lua
10 - Dice (Rolando os dados)
11 - Voodoo Skull (previsão da sorte do dia)
12 - Caça Niqueis
13 - Mapa-spawn.xml (Como funciona)
14 - Pendurando objetos na parede
15 - Santa Doll (Papai Noel)
16 - EuTeAmoVoce [Instant Spell]
17 - doSendAnimatedText (Todas as cores)
18 - NPC Banqueiro
19 - 8 Bichos (Massive Summon)
20 - Transformando Barril Simples em Barril de Mana Fluid
21 - Quebrando Itens Com Arma (Tirando BUG)
22 - Padre Marcelo (Totalmente REFEITO)
23 - Npc De Backpack ( Back Picka )
24 - Npc De Dolls ( Baby Doll )
25 - Fonte Da Juventude (Mana e Life)
26 - NPC que troca itens
27 - Removendo paredes com PAUSA, (efeito visual lindo)
28 - Halloween - Fazendo o PumpkinHead
29 - Halloween - Criando o monstro Halloween Hare
30 - Mapa pra fazer Testes (Sapo.otbm)
31 - Fishing Rod (Qualquer versão)
32 - Jungle Maw (planta que morde)
33 - Npc Stan (fantasias de Carnaval)
Clicar -------/\

Nostradamus

Serviços Prestados ao XTibia.com
avatar
Visconde
Visconde

INFOS

Grupo: ViscondeRegistrado: 10/06/06Posts: 338Char no Tibia: Setyte Berseker

@Conde Sapo

Ao invés de usar esse tanto de OR, coloque os ids em arrays e use a função isInArray

[twitter]ThomazYuji[/twitter]

brab0

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 01/10/05Posts: 17

Nostra, reformula ai e posta pra a comunidade

Administrador
dkrealmssign3.png

Sequeled

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 16/06/07Posts: 23

mt bom lek parabens :lol:

continue assim :)

genoma

genoma
avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 19/08/07Posts: 59Char no Tibia: Diabeda

Testei os tapestries e também criei os trophys, tive q substituir algumas coisas( west face e south face) de cada um. Pois os IDs não são consecutivos como no caso dos tapestries. Tive que faze um script para cada trophy :D.

Ambos funcionaram 100%, porém quando fecho meu server, ao abrir de novo ambos somem das paredes.

Acho que isso não tem como arrumar :(

 

 

Mas parabéns pelo script, ficou excelente.;)

Conde Sapo

avatar
Visconde
Visconde

INFOS

Grupo: ViscondeRegistrado: 14/08/07Posts: 322Char no Tibia: Conde Sapo (Secura)

@genoma

põe ae o script modificado

 

você usou /save antes de fechar seu OT ???

 

:thumbsupsmiley:

-----------------------
-------------------------------


Encontro de Quake na minha Ex-LAN

odeio rapidshare

"Criticas enriquecem o trabalho dos inteligentes.
Os negligentes simplesmente as ignoram." - Conde Sapo

"A melhor recompensa do Mestre ,
é ver o Aluno superar as espectativas." - Conde Sapo



(finalmente me convenceram a fazer a Fan Bar)

Meus trabalhos :
\/------- Clicar

01 - Porta com chave numérica
02 - Efeito de MAR em movimento
03 - Fruta na Árvore (acrescentei arvore)
04 - NPC Messager
05 - Monstros Morrem Mas Nao Somem Do Mapa
06 - Simulando UnderWater
07 - SpellBook (Book 2175)
08 - CommandsSpellBook (Book 6120)
09 - Fixo: Tudo Sobre A Linguagem Lua
10 - Dice (Rolando os dados)
11 - Voodoo Skull (previsão da sorte do dia)
12 - Caça Niqueis
13 - Mapa-spawn.xml (Como funciona)
14 - Pendurando objetos na parede
15 - Santa Doll (Papai Noel)
16 - EuTeAmoVoce [Instant Spell]
17 - doSendAnimatedText (Todas as cores)
18 - NPC Banqueiro
19 - 8 Bichos (Massive Summon)
20 - Transformando Barril Simples em Barril de Mana Fluid
21 - Quebrando Itens Com Arma (Tirando BUG)
22 - Padre Marcelo (Totalmente REFEITO)
23 - Npc De Backpack ( Back Picka )
24 - Npc De Dolls ( Baby Doll )
25 - Fonte Da Juventude (Mana e Life)
26 - NPC que troca itens
27 - Removendo paredes com PAUSA, (efeito visual lindo)
28 - Halloween - Fazendo o PumpkinHead
29 - Halloween - Criando o monstro Halloween Hare
30 - Mapa pra fazer Testes (Sapo.otbm)
31 - Fishing Rod (Qualquer versão)
32 - Jungle Maw (planta que morde)
33 - Npc Stan (fantasias de Carnaval)
Clicar -------/\

genoma

genoma
avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 19/08/07Posts: 59Char no Tibia: Diabeda

sim, eu usei o comando /save e não deu, mas ja resolvi esse probleminha ;)

Item Editor, editei todos trophys e tapestries como hangable e moveable :D

 

Agora não somem mais das casas :p

cherife

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 15/10/05Posts: 79

Genoma, abre seu mapa no mapeditor e certifique-se que as paredes das suas casas estão em cima de um tile que seja "house" tile azul, entende? ;)

 

mas ja resolvi esse probleminha

Item Editor, editei todos trophys e tapestries como hangable e moveable

 

Agora não somem mais das casas

Ooops, tu já resolveu :p

Mas mesmo assim, caso alguem esteja com problema de as cortinas sumirem, tente minha dica ;)

sign.jpg

[Inspire before you expire.]

myamnarbar.jpg
  • 1
  • 2