BU

Invasões De Montros

By buster287, 11 de dez. de 2005 in Actions e Talkactions

script
8
4.4k
buster287B
11 de dezembro de 2005 às 03:58

Esse tutorial tem crédito totalmente do Thomasleick por ter me ajudado a corrigir!

Aeee eu fiz aqui isso aih e não deu certoo então eu fiz um script aki esse aki ta funcionando só que eu fiz ele com o ID de uma runa okz ??

esse aki colokem no data\actions\scripts\invasion.lua

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

if getPlayerAccess(cid) ~=0 then

topleft={x=??, y=??, z=??} ---> Cima/Esquerda

bottonright={x=??, y=??, z=??} ---> Baixo/Direita

maxmonsters= Se quizer sem limite coloque maxmonsters= nil

checking={x=topleft.x, y=topleft.y, z=topleft.z}

summonedtotal=0

repeat

checkforsummon=0

spawnrate=math.random(0,10)

if spawnrate == 0 and summonedtotal ~= maxmonsters then

species=math.random(1,10)

if species == 1 then

checkforsummon = doSummonCreature("Monstro1",checking)

elseif species == 2 then

checkforsummon = doSummonCreature("Monstro2",checking)

elseif species == 3 then

checkforsummon = doSummonCreature("Monstro3",checking)

elseif species == 4 then

checkforsummon = doSummonCreature("Monstro4",checking)

elseif species == 5 then

checkforsummon = doSummonCreature("Monstro5",checking)

elseif species == 6 then

checkforsummon = doSummonCreature("Monstro6,checking)

elseif species == 7 then

checkforsummon = doSummonCreature("Monstro7",checking)

else

checkforsummon = doSummonCreature("Monstro + sumonado",checking)

end

if checkforsummon~= 0 then

summonedtotal=summonedtotal+1

end

end

checking.x=checking.x+1

if checking.x>bottonright.x then

checking.x=topleft.x

checking.y=checking.y+1

end

until checking.y > bottonright.y

--doPlayerSay(cid,"/B INVASÃO!!!",23)

print("número de monstros sumonados:",summonedtotal)

end

return 1

end

agora colokem isso no data\actions\actions.xml

<action itemid="2275" script="invasion.lua" />

É isso aih!! facinhuu!!!

Edited Junho 4 by buster287

3 weeks later...
28 de dezembro de 2005 às 12:17

n tem coment pq n funciona pelomenos aki n deu e e mto + facil fze a invason

4 months later...
mariojunM
22 de abril de 2006 às 01:13

Naum sei c pega vo tenta :bigsmile:. Tomara q funcione :confused:.

1 month later...
08 de maio de 2006 às 14:10

Umm Vo Tenta Aki Pra Ve Se Pega...

:icon1:

4 weeks later...
ThomasleickT
30 de maio de 2006 às 22:47

Aeee eu fiz aqui isso aih e não deu certoo então eu fiz um script aki esse aki ta funcionando só que eu fiz ele com o ID de uma runa okz ??

esse aki colokem no data\actions\scripts\invasion.lua

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

if getPlayerAccess(cid) ~=0 then

topleft={x=??, y=??, z=??} ---> Cima/Esquerda

bottonright={x=??, y=??, z=??} ---> Baixo/Direita

maxmonsters= Se quizer sem limite coloque maxmonsters= nil

checking={x=topleft.x, y=topleft.y, z=topleft.z}

summonedtotal=0

repeat

checkforsummon=0

spawnrate=math.random(0,10)

if spawnrate == 0 and summonedtotal ~= maxmonsters then

species=math.random(1,10)

if species == 1 then

checkforsummon = doSummonCreature("Monstro1",checking)

elseif species == 2 then

checkforsummon = doSummonCreature("Monstro2",checking)

elseif species == 3 then

checkforsummon = doSummonCreature("Monstro3",checking)

elseif species == 4 then

checkforsummon = doSummonCreature("Monstro4",checking)

elseif species == 5 then

checkforsummon = doSummonCreature("Monstro5",checking)

elseif species == 6 then

checkforsummon = doSummonCreature("Monstro6,checking)

elseif species == 7 then

checkforsummon = doSummonCreature("Monstro7",checking)

else

checkforsummon = doSummonCreature("Monstro + sumonado",checking)

end

if checkforsummon~= 0 then

summonedtotal=summonedtotal+1

end

end

checking.x=checking.x+1

if checking.x>bottonright.x then

checking.x=topleft.x

checking.y=checking.y+1

end

until checking.y > bottonright.y

--doPlayerSay(cid,"/B INVASÃO!!!",23)

print("número de monstros sumonados:",summonedtotal)

end

return 1

end

agora colokem isso no data\actions\actions.xml

<action itemid="2275" script="invasion.lua" />

É isso aih!! facinhuu!!!

Edited Maio 30 by Thomasleick

BraboB
30 de maio de 2006 às 23:06

Nao funfou aqui nao o.O

BurnxB
02 de junho de 2006 às 19:53

Quando tive meu yourots, eu configurei para aqueles cajados antigos sumonarem cada um um tipo de Boss.....fico muito funcional...deu bastante bug pra faze funfa quase perfect, pois as vezes em vez de sai um boss saiam 2 até + ^^, é pra 7.5 se não me engano, se alguem quize os códigos eu passo...:).

Ty

thucoT
08 de junho de 2006 às 20:17

Ow cara c tivé como vc m responde, add ae the_tavares@hotmail.com

q codigo eu ponho com o gm pra invasion funnunciá?