Ir para conteúdo

Featured Replies

Postado
8 minutos atrás, kauan13 disse:

@kauan13 nd ainda

 

Tenta Assim 

  Ocultar conteúdo

local cfg = {
    positions = {
        {{x=193, y=431, z=7}, {x=284, y=551, z=7}}, ------ AOND O PLAYER VAI DA TP
        {{x=192, y=431, z=7}, {x=283, y=551, z=7}}, ------ AONDE PLAYER VAI TA
        {{x=191, y=431, z=7}, {x=282, y=551, z=7}}, ------ AONDE PLAYER VAI TA
        {{x=190, y=431, z=7}, {x=281, y=551, z=7}}, ------ AONDE PLAYER VAI TA
        {{x=189, y=431, z=7}, {x=280, y=551, z=7}}, ------ AONDE PLAYER VAI TA
        {{x=188, y=431, z=7}, {x=279, y=551, z=7}}, ------ AONDE PLAYER VAI TA

 

    },
    not_enough_players = 2,      --Efeito que aparecerá quando não tiver jogadores o suficiente.
    tp_effect = 65,               --Efeito que vai aparecer nos jogadores ao serem teleportados.
}
function onUse(cid, item, fromPosition, item2, toPosition)
    for i = 1, #cfg.positions do
        if not isPlayer(getTopCreature(cfg.positions[1]).uid) then
            return doPlayerSendCancel(cid, "Not enough players.") and doSendMagicEffect(getThingPos(cid), cfg.not_enough_players)
        end
    end         
    for i = 1, #cfg.positions do
        local creature = getTopCreature(cfg.positions[1]).uid
        doTeleportThing(creature, cfg.positions[2])
        doPlayerSendTextMessage(creature, 27, "You started the quest.")
        doSendMagicEffect(getThingPos(creature), cfg.tp_effect)
    end
    return true
end

 

 

13 minutos atrás, kiinho disse:

 

 

-Nome do arquivo.lua que criei-

 

O Nome do arquivo que eu criei é "creatport10.lua"

Sem aspas.

 

-Script que eu usei no creatport10.lua-

 

 

Citar

Citar

local tpId = 1387

local tps = {
["Shiny Reshiram] = {pos = {x=1232, y=337, z=8}, toPos = {x=1215, y=514, z=8}, time = 30},
}
 
function removeTp(tp)
local t = getTileItemById(tp.pos, tpId)
if t then
doRemoveItem(t.uid, 1)
doSendMagicEffect(tp.pos, CONST_ME_POFF)
end
end
 
function onDeath(cid)
local tp = tps[getCreatureName(cid)]
if tp then
doCreateTeleport(tpId, tp.toPos, tp.pos)
doCreatureSay(cid, "O teleport irá sumir em "..tp.time.." segundos."TALKTYPE_ORANGE_1)
addEvent(removeTp, tp.time*1000, tp)
end
return TRUE

end

 

 
 

-Legenda-

 

 

Vermelho = É o ID do teleport. (Magic forcefield);

 

Rosa = É o nome do pokémon que quando morre abre o tp;

 

Azul = É o lugar de onde aparece o TP para entrar;

 

Laranja =  É onde é teletransportado quando entra no TP;

 

Vermelho Escuro = É a mensagem que aparece quando o Shiny Reshiram Morre.

 

 

-Script que eu usei no "Creaturescripts.xml"

 

 

 

       

Citar

Citar

 

<event type="death" name="creatport10" event="script" value="creatport10.lua"/> 

 

 

 

 

 

-Legenda-

 

Vermelho = É o tipo do Script (ou algo assim)

 

Cyano  É o nome do arquivo (citado no começo do tópico)

 

Obrigado galera, Por favor me ajudem nisso!

Quero muito fazer umas quests :v

Editado por wougoplex (veja o histórico de edições)

  • Respostas 11
  • Visualizações 520
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • Vai em Action Script crie um novo e bote esse script       Scirpt  :   local cfg = {     positions = {         {{x=2392, y=73, z=7}, {x=2519, y=78, z=7}}, ------ AOND

  • @kauan13 Ue, basta ir acrescentando passo a passo amigo, isso ai em meu ponto de vista se chama preguiça.. Ou voce realmente n consegue? Ja tentou? Se nao conseguiu me avisa que vou lhe ajudar.

  • Ta dando erro nos script ow ta duplicando o action id ?

Postado

@wougoplex Aonde salvo o arquivo.lua?

@wougoplex O que esse erro poderia ser? e os itens duplicate??

 

[12/08/2016 16:18:26] Pokemon Dash Advanced (1.0), last compiled at Jan 11 2012.
[12/08/2016 16:18:26] Credits to all TFS team (Elf, slawkens, Talaturen, Lithium, KaczooH, Kiper, Kornholijo).
[12/08/2016 16:18:26] PokemonDistro made by mastercraft/brun123.
[12/08/2016 16:18:26] >> Loading config (config.lua)
[12/08/2016 16:18:26] > Using plaintext encryption
[12/08/2016 16:18:26] >> Checking software version... failed checking - malformed file.
[12/08/2016 16:18:27] >> Fetching blacklist
[12/08/2016 16:18:27] >> Loading RSA key
[12/08/2016 16:18:27] >> Starting SQL connection
[12/08/2016 16:18:27] >> Running Database Manager
[12/08/2016 16:18:27] > Optimized database.
[12/08/2016 16:18:27] >> Loading items
[12/08/2016 16:18:27] [Warning - Items::loadFromXml] Duplicate registered item with id 1232
[12/08/2016 16:18:27] [Warning - Items::loadFromXml] Duplicate registered item with id 12593
[12/08/2016 16:18:27] >> Loading groups
[12/08/2016 16:18:27] >> Loading vocations
[12/08/2016 16:18:27] >> Loading script systems
[12/08/2016 16:18:28] [Warning - Actions::registerEvent] Duplicate registered item id: 12804
[12/08/2016 16:18:28] [Warning - Actions::registerEvent] Duplicate registered item id: 12808
[12/08/2016 16:18:28] [Warning - Actions::registerEvent] Duplicate registered item id: 2393
[12/08/2016 16:18:28] [Warning - Actions::registerEvent] Duplicate registered item aid: 2000
[12/08/2016 16:18:28] >> Loading chat channels
[12/08/2016 16:18:28] >> Loading outfits
[12/08/2016 16:18:28] >> Loading experience stages
[12/08/2016 16:18:28] >> Loading monsters
[12/08/2016 16:18:30] >> Loading mods...
[12/08/2016 16:18:30] > Loading buypremium_command.xml... done, but disabled.
[12/08/2016 16:18:30] > Loading changender_command.xml... done, but disabled.
[12/08/2016 16:18:30] > Loading custommonsters.xml... done, but disabled.
[12/08/2016 16:18:30] > Loading customspells.xml... done, but disabled.
[12/08/2016 16:18:30] > Loading firstitems.xml... done.
[12/08/2016 16:18:30] > Loading highscorebook.xml... done.
[12/08/2016 16:18:30] > Loading Sumário do OneNote.onetoc2...[Error - ScriptingManager::loadFromXml] Cannot load mod mods/Sumário do OneNote.onetoc2
[12/08/2016 16:18:30] Line: 1, Info: Start tag expected, '<' not found


[12/08/2016 16:18:30]  failed!
[12/08/2016 16:18:30] > 7 mods were loaded (4 disabled).
[12/08/2016 16:18:30] >> Loading map and spawns...
[12/08/2016 16:18:35] > Map size: 65000x30000.
[12/08/2016 16:18:35] > Map descriptions: 
[12/08/2016 16:18:35] "Saved with Remere's Map Editor 2.2"
[12/08/2016 16:18:35] ""
[12/08/2016 16:18:38] Duplicate uniqueId 65535
[12/08/2016 16:18:44] Duplicate uniqueId 65535
[12/08/2016 16:18:49] Duplicate uniqueId 65535
[12/08/2016 16:18:50] > Map loading time: 20.079 seconds.
[12/08/2016 16:18:55] > Data parsing time: 5.507 seconds.
[12/08/2016 16:19:30] > Houses synchronization time: 34.201 seconds.
[12/08/2016 16:19:30] > Content unserialization time: 0.47 seconds.
[12/08/2016 16:19:30] >> Checking world type... PvP
[12/08/2016 16:19:30] >> Initializing game state modules and registering services...
[12/08/2016 16:19:31] > Global address: 127.0.0.1
[12/08/2016 16:19:31] > Local ports: 7171    7172    
[12/08/2016 16:19:31] >> All modules were loaded, server is starting up...
[12/08/2016 16:19:31] >> XTM server Online!

4 horas atrás, wougoplex disse:
4 horas atrás, wougoplex disse:

local tpId = 1387

local tps = {
["Shiny Reshiram] = {pos = {x=1232, y=337, z=8}, toPos = {x=1215, y=514, z=8}, time = 30},
}
 
function removeTp(tp)
local t = getTileItemById(tp.pos, tpId)
if t then
doRemoveItem(t.uid, 1)
doSendMagicEffect(tp.pos, CONST_ME_POFF)
end
end
 
function onDeath(cid)
local tp = tps[getCreatureName(cid)]
if tp then
doCreateTeleport(tpId, tp.toPos, tp.pos)
doCreatureSay(cid, "O teleport irá sumir em "..tp.time.." segundos."TALKTYPE_ORANGE_1)
addEvent(removeTp, tp.time*1000, tp)
end
return TRUE

end

 

@wougoplex tem algo errado ai, não aparece o portal.

Editado por kiinho (veja o histórico de edições)

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.7k

Informação Importante

Confirmação de Termo