XB

Pegando "frutinhas" Nos Bushs

Por xbowaxx, 02 de nov. de 2005 em Actions e Talkactions

script
7
2.2k
02 de novembro de 2005 às 22:35

Pegar cherrys nos bushs com machete e no use, com random...

em actions.xml coloque

<action itemid="2785" script="bush.lua" />

se o id for 7.5 deve mudar o id...

e em bush.lua coloque

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

rand = math.random(1,100)

repo = getPlayerName(cid)

if item.itemid == 2785 and rand < 20 then

doTransformItem(item.uid,2786)

doPlayerAddItem(cid,2677,3)

doPlayerSendTextMessage(cid,22,"Whoho, I'm so lucky, I got three blueberries.")

doPlayerSendTextMessage(cid,22,"hum... I think I could get more blueberries using a machete.")

print("JLS ::Player got three blueberries:",repo)

else if rand > 20 and rand < 50 then

doTransformItem(item.uid,2786)

doPlayerAddItem(cid,2677,2)

doPlayerSendTextMessage(cid,22,"mmm... Not bad at all, I got two blueberries.")

doPlayerSendTextMessage(cid,22,"hum... I think I could get more blueberries using a machete.")

print("JLS ::Player got two blueberries:",repo)

else if rand > 50 and rand < 80 then

doTransformItem(item.uid,2786)

doPlayerAddItem(cid,2677,1)

doPlayerSendTextMessage(cid,22,"I managed to get a blueberry.")

doPlayerSendTextMessage(cid,22,"hum... I think I could get more blueberries using a machete.")

print("JLS ::Player got a blueberry:",repo)

else if rand > 80 and rand < 100 then

doTransformItem(item.uid,2786)

doPlayerSendTextMessage(cid,22,"Damn, I'm so unlucky.")

print("JLS ::Player haven't got any blueberry:",repo)

end

return 1

end

end

end

end

com a machete vc pode pegar 4 a 5 blueberrys e adicionar skill de sworde em machete.lua coloque

if item2.itemid == 2785 and rand < 35 then

doTransformItem(item2.uid,2786)

doPlayerAddItem(cid,2677,5)

doPlayerAddSkillTry(cid,2,1)

doPlayerSendTextMessage(cid,22,"Oh! That's much better, I got 5 blueberries.")

elseif item2.itemid == 2785 and rand > 35 then

doTransformItem(item2.uid,2786)

doPlayerAddItem(cid,2677,4)

doPlayerAddSkillTry(cid,2,1)

doPlayerSendTextMessage(cid,22,"Oh! That's much better, I got 4 blueberries.")

else

return 0

end

só adicione isso o q ja tinha deixa neh, mas bota antes dos outros ends pra nao terminar a action neh xP

fonte: ######

Editado Novembro 3 por xbowaxx

3 meses depois...
VenturaV
27 de fevereiro de 2006 às 22:26

nossa meu vc é mt bom continua assim ^.^

GMxtibiaG
28 de fevereiro de 2006 às 18:35

muito rox

2 meses depois...
Fusion32F
05 de abril de 2006 às 14:47

kara eu nao tenhu a action machete aki xD poe ae o script todo?

9 meses depois...
codornaC
17 de janeiro de 2007 às 17:30

sim poe sim

 

dai tipow a blueberry bush apos tirar as blueberrys muda prakela peladinha neh??

 

vo por aki nu meu evo6.3 e ve se funfa pq a ideia eh boa ^^

 

 

edit: n sei pq mas n to cosneguindo faze funfa cum o machete!!

 

a script do bush ta funfandu perfeitament mas a do machete da osso faze fufna help ae =/

Editado Janeiro 18 por codorna

1 ano depois...
felipebs77F
26 de outubro de 2008 às 11:22

parabens kra, mto bom, funfo beleza ake, so dei umas modificadas a gosto xD

26 de outubro de 2008 às 11:26

Ei, autor do tópico...esse comando print, funciona mesmo? Pra mim é novidade u.u