[action] Yalahar Quest Last Mission

awarkener
em Actions e Talkactions

awarkener

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 18/11/06Posts: 13

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

Nome: Yalahar Quest Last Mission

Versão: 8.4x

Tipo do script: Moviments,Creaturescripts

Servidor Testado: The Forgotten Server 0.3.4 (Crying Damson) Patch Level 2

Autor: Land

Creditos: Ta4e(uma parte do script foi tirada de um outro dele)

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

 

Yalahar Quest BY: Land

 

TUDO QUE ESTIVER EM VERMELHO SAUM IMPORTANTE PARA O SCRIPT E É AONDE TERAUM QUE MUDAR DE ACORDO COM SEU MAP.

ROSA SAUM AS ACTIONID.

 

Configurando Moviments:

 

CRIE UM ARQUIVO .LUA EM "data\movements\scripts\"

Nome = yalahar_azerus_quest

 

EM "data\movements\scripts\yalahar_azerus_quest.lua":

function onStepIn(cid, item, position, fromPosition)

 

--Config-->

local starting = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 253}

local ending = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 253}

local checking = {x = starting.x, y = starting.y, z = starting.z, stackpos = starting.stackpos}

local queststatus = getPlayerStorageValue(cid, XXXXX) --Value ID DA QUEST QUANDO VOCE JA PEGO O ITEM

local player_pos_entrada = {x = XXXXX, y = XXXXX, z = XXXXX}

--EndConfig-->

 

--Do not touch this--

if getPlayerLookDir(cid) == 0 then

newdir = 2

elseif getPlayerLookDir(cid) == 1 then

newdir = 3

elseif getPlayerLookDir(cid) == 2 then

newdir = 0

else

newdir = 1

end

--Don't edit this unless you know what you are doing.

 

if item.actionid == 1974 and queststatus == -1 then

doCreatureSay(cid, "It seems by defeating Azarus you have stopprd this army from entering your world! Better leave this ghastly place forever.", TALKTYPE_ORANGE_1)

setPlayerStorageValue(cid, XXXXX, 1) --Value ID PARA QUE O PLAYER POSSA ENTRA NA PORTA ONDE ESTAUM AS RECOMPENSA

return TRUE

end

 

if item.actionid == 1973 and queststatus == -1 then

totalmonsters = 0

monster = {}

 

repeat

creature = getThingfromPos(checking)

 

if creature.itemid > 0 then

if getPlayerAccess(creature.uid) ~= 0 and getPlayerAccess(creature.uid) ~= 3 then

totalmonsters = totalmonsters + 1

monster[totalmonsters] = creature.uid

end

end

 

checking.x = checking.x + 1

 

if checking.x > ending.x then

checking.x = starting.x

checking.y = checking.y + 1

end

 

until checking.y > ending.y

 

if totalmonsters ~= 0 then

current = 0

repeat

current = current + 1

doRemoveCreature(monster[current])

until current >= totalmonsters

end

 

doTeleportThing(cid, player_pos_entrada)

doSendMagicEffect(player_pos_entrada, 10)

 

else

doMoveCreature(cid, newdir)

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, 'Someone has already done this quest.')

end

end

 

NO PORTAL PARA ENTRA NA SALA DA QUEST ADICIONE ACTIONID,1973 CONFORME A IMAGEM

imagem5v1.jpg

 

STARTING,ENDING:SAUM AS COORNADAS PARA QUE O SCRIPT CHECK SE TEM ALGUM BIXO NA SALA,SE ESTIVER ALGUM ELE REMOVERA

PLAYER_POS_ENTRADA:É A COORDENADA DA ONDE O PLAYER SERA TELEPORTADO APOS ENTRA NA SALA

imagem6v1.jpg

 

NO FINAL DA QUEST ADICIONE ACTIONID,1974 NO TILE CONFORME A FIGURA PARA QUE QUANDO O PLAYER PISE NELE EXIBIRA A MSG FALANDO QUE ELE JA PODE ENTRA NA SALA DE RECOMPENSA

imagem7v1.jpg

 

AGORA LA NO SCRIPT NA ACTION,1974 NA PARTE ONDE ESTA OS 'X' ADICIONE UM VALUE E NAS PORTA DA QUEST COLOKE O MESMO VALUE CONFORME A IMAGEM ABAIXO PARA QUE O PLAYER POSSA ENTRA APOS TERMINA A QUEST

imagem4d.jpg

 

movements.xml:

<!-- Yalahar Set Quest -->

<movevent type="StepIn" actionid="1973" event="script" value="yalahar_azerus_quest.lua" />

<movevent type="StepIn" actionid="1974" event="script" value="yalahar_azerus_quest.lua" />

<!-- End Yalahar Set Quest -->

 

Configurando Actions:

 

CRIE UM ARQUIVO .LUA EM "data\actions\scripts\"

Nome = yalahar_azerus_quest

 

EM "data\actions\scripts\yalahar_azerus_quest.lua":

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

 

--Config-->

local statue_pos = {x = XXXXX, y = XXXXX, z = XXXXX}

local portal_quest01_pos = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 2}

local portal_quest02_pos = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 2}

local new_portal_pos = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 1}

local new_pos = {x = XXXXX, y = XXXXX, z = XXXXX}

--End Config-->

 

function Potwory1()

doCreateMonster('Rift Brood', {x = statue_pos.x+1, y = statue_pos.y+1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Brood', {x = statue_pos.x-1, y = statue_pos.y+1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Brood', {x = statue_pos.x, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Worm', {x = statue_pos.x-1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Worm', {x = statue_pos.x+1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Worm', {x = statue_pos.x+1, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Worm', {x = statue_pos.x-1, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

addEvent(Potwory2, 30 * 1000)

end

 

function Potwory2()

doCreateMonster('Rift Brood', {x = statue_pos.x-1, y = statue_pos.y+1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Brood', {x = statue_pos.x, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Worm', {x = statue_pos.x-1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Worm', {x = statue_pos.x+1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

addEvent(Potwory3, 35 * 1000)

end

 

function Potwory3()

doCreateMonster('Rift Scythe', {x = statue_pos.x-1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Scythe', {x = statue_pos.x+1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Scythe', {x = statue_pos.x+1, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

doCreateMonster('Rift Scythe', {x = statue_pos.x-1, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

addEvent(Potwory4, 40 * 1000)

end

 

function Potwory4()

doCreateMonster('Azerus', {x = statue_pos.x, y = statue_pos.y+1, z = statue_pos.z, stackpos = 253})

doCreateMonster('War Golem', {x = statue_pos.x+1, y = statue_pos.y+1, z = statue_pos.z, stackpos = 253})

doCreateMonster('War Golem', {x = statue_pos.x-1, y = statue_pos.y+1, z = statue_pos.z, stackpos = 253})

doCreateMonster('War Golem', {x = statue_pos.x, y = statue_pos.y-1, z = statue_pos.z, stackpos = 253})

doCreateMonster('War Golem', {x = statue_pos.x-1, y = statue_pos.y, z = statue_pos.z, stackpos = 253})

addEvent(NewPortal, 90 * 1000)

end

 

function NewPortal()

doCreateTeleport(1387, new_pos, new_portal_pos)

addEvent(RemoveAll, 60 * 1000)

end

 

function RemoveAll()

doRemoveItem(getThingfromPos(portal_quest01_pos).uid,1)

doRemoveItem(getThingfromPos(portal_quest02_pos).uid,1)

doRemoveItem(getThingfromPos(new_portal_pos).uid,1)

end

 

if item.uid == 1968 and getThingfromPos(portal_quest01_pos).itemid ~= 9772 then

doCreateItem(9772,1,portal_quest01_pos)

doCreateItem(9772,1,portal_quest02_pos)

addEvent(Potwory1, 0)

else

doPlayerSendTextMessage(cid,22,"Sorry, not possible.")

end

return TRUE

end

 

 

STATUE_POS:COORDENADAS DA ONDE A ESTATUA VAI ESTA

ADICIONE NA ESTATUA EM UNIQUEID,1968

NEW_PORTAL_POS:VAI SER NA ONDE O PORTAL APARECERA QUANDO ACABAR A QUEST

PORTAL_QUEST01_POS:É A POSIÇÃO NA ONDE O PORTAL DE DENTRO DA SALA ESTA

OBS:ISSO SERVE PARA QUE QUANDO A QUEST FOR ACIONADA CRIE UM ORB NO PORTAL PARA QUE NGM MAIS POSSA SAI

imagem6k.jpg

 

PORTAL_QUEST02_POS:É A POSIÇÃO NA ONDE O PORTAL DE FORA DA SALA ESTA

OBS:ISSO SERVE PARA QUE QUANDO A QUEST FOR ACIONADA CRIE UM ORB NO PORTAL PARA QUE NGM MAIS POSSA ENTRA NA SALA

imagem5o.jpg

 

NEW_POS:SAUM AS COORDENADAS DA ONDE O PLAYER SERA TELEPORTADO APOS TERMINA A QUEST

imagem7fxe.jpg

 

actions.xml:

<!-- Yalahar Set Quest -->

<action uniqueid="1968" script="yalahar_azerus_quest.lua"/>

<!-- End Yalahar Set Quest -->

satan666

Antichrist Superstar
avatar
Conde
Conde

INFOS

Grupo: CondeRegistrado: 07/05/08Posts: 612Char no Tibia: leviana luciferiana

sinceramente esse script ae e muito parecido com o outro da fire boots.

 

apenas pequenas modificaçoes e nada de mais.

 

ainda prefiro a boa ideia que vc teve no da fire do que nesse que mais parece copia do outro.

creationb.jpg

"Um Deus que usasse seu poder para criar seres humanos que de antemão sabia que seriam atormentados eternamente, e que os predestinasse a isso,



não poderia ser sábio, nem justo e tampouco amoroso.

Além de nos submeter a isso vim a nos julgar e condenar por nossos atos aos tormentos do inferno.

pra minha pessoa isso não é um Deus Pai amoroso e bondoso como o chaman, seu padrão seria muito mais inferior do que o de muitos homens."

awarkener

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 18/11/06Posts: 13
sinceramente esse script ae e muito parecido com o outro da fire boots.

 

apenas pequenas modificaçoes e nada de mais.

 

ainda prefiro a boa ideia que vc teve no da fire do que nesse que mais parece copia do outro.

 

na parte de moviments sim pq sempre uso esse metodo pra limpar uma certa area.

bem simple...

XvX

avatar
Artesão
Artesão

INFOS

Grupo: ArtesãoRegistrado: 13/12/08Posts: 122Char no Tibia: Soul Vegas

No meu server num funfou naum .

Aq uso Forgotten 8.42

 

Da esse erro:

 

[24/06/2009 09:23:08] Error: [MoveEvent::configureMoveEvent] No valid event name script

[24/06/2009 09:23:08] Warning: [baseEvents::loadFromXml] Can not configure event

[24/06/2009 09:23:08] Error: [MoveEvent::configureMoveEvent] No valid event name script

[24/06/2009 09:23:08] Warning: [baseEvents::loadFromXml] Can not configure event

XvX

avatar
Artesão
Artesão

INFOS

Grupo: ArtesãoRegistrado: 13/12/08Posts: 122Char no Tibia: Soul Vegas

Cara botei p funcionar no meu server aq, mais tem pequenos detalhes q tive q corrigir no scrip:

 

Aqui a função do doCreateMonster num funciona aew botei essa:doSummonCreature

 

E onde vc disse q é p botar ACTIONID no sqm têm q ser UNIQUEID id:

 

NO FINAL DA QUEST ADICIONE ACTIONID,1974 NO TILE CONFORME A FIGURA PARA QUE QUANDO O PLAYER PISE NELE EXIBIRA A MSG FALANDO QUE ELE JA PODE ENTRA NA SALA DE RECOMPENSA

 

Vlw pelo scrip, ficou show de bola!

Matt-

Ex-Moderador Xtibia
avatar
Visconde
Visconde

INFOS

Grupo: ViscondeRegistrado: 02/02/09Posts: 302

XvX

 

Eu gostaria de informar a você que você está cometendo uma infração "Double Post", Double Post é contra as regras.

Está feito o aviso pra que não aconteça isso de novo.

 

Feito o Aviso



Matt

Ex-Moderador

DaNDaNrOxX

oi mosso
avatar
Marquês
Marquês

INFOS

Grupo: MarquêsRegistrado: 18/01/08Posts: 1455Char no Tibia: Saint Claire

Só para complementar o que o Matt- disse, XvX, você foi alertado verbalmente por double post aqui, espero que não volte a quebrar as regras ou teremos que alertar em 10%.

Qualquer dúvida pode mandar mp.

Abraços

 

 

Entrada na equipe: 23/10/2008 Cargo: Estagiário

Promoção: 25/11/2008 Cargo: Moderador

Promoção: 21/10/2009 Cargo: Coordenador

Remoção: 09/05/2010 Motivo: Estudos

Retorno: 15/11/2010 Cargo: Moderador

Remoção: 20/12/2012.

 

 

Stefano26

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 01/04/08Posts: 64Char no Tibia: Qyb

Script bem complexo, adorei, porém estou sem tempo para testar, breve estarei testando!

Olá XTibiano:

Sua assinatura estava com um problema na TAG SPOILER e foi movida para a parte "Sobre mim".
Agradecemos a sua compreensão.

Atenciosamente,
JV Chequer

robson47

O Pai da OpenTibia
avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 26/04/08Posts: 47Char no Tibia: Eddy Qix

aqui nao funcionou =/

Open Source é para todos, queremos que o fórum crie uma seção para avaliação dos downloads de servidores, antes de chegar ao membro do fórum, no tópico deve conter de obrigatóriedade o código fonte do servidor, mesmo que ele não tenho sido editado por quem está criando o tópico, quem não sabe onde conseguir o código fonte deverá se informar.

yanleonardo

avatar
Campones
Campones

INFOS

Grupo: CamponesRegistrado: 29/09/07Posts: 2

Estou com uma duvida.

 

eu tenho um mapa global full e quero por a yalahar quest mais estou com duvida em saber o que é "local starting" e "local ending". Onde fica isso.. Pra eu por as cordenadas..

 

--Config-->

local starting = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 253}

local ending = {x = XXXXX, y = XXXXX, z = XXXXX, stackpos = 253}