Ir para conteúdo

Featured Replies

Postado

EAE GARERA FMZ?

QUERIA SCRIPT ASSIM

1 : O PLAYER VAI TER Q ESTAR COM SUMMON INVOCADO

2 : QUANDO ESTIVER COM SUMMON INVOCADO ELE USA SPELL "SABIO DOS SEIS CAMINHOS" 

3 : ELE GANHARA UMA NEWTYPE ESSA NEWTYPE DARA 300 MIL DE HP SEM PARAR DURANTE 5 MINUTOS OK E CONTINUANDO QUANDO ACABAR OS 5 MINUTOS ELE MORRE E NA TELA APAREÇE "ACABOU SEU TEMPO" E ELE MORRE ESSA NEWTYPE APOS MORRER SOME E QUANDO ELE MORRER NAO PERDER ITEM NEM NADA DO TIPO PQ  O PLAYER PODE ESTAR COM VIP

COLOCA COLDOWN VLW E TIPO HP +300MIL VLW REP +

 

ESSE SUMMON CHAMA-SE JUUBI

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

  • Respostas 26
  • Visualizações 1.5k
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • Bodak Reborn
    Bodak Reborn

    Eu não testei. O script apenas exige que o player esteja com um summon de nome Juubi, mas ele não summona um.   Spell: local config = { summonName = "Juubi", message = "Mensagem ao

  • Bodak Reborn
    Bodak Reborn

    Atualizei o código da spell com a correção. " Atualizei o código da spell com a correção. " Sobre o código, fale pelo post que ele criou...

  • Bodak Reborn
    Bodak Reborn

    Sim, troque por isso: doCreatureSetOutfit (cid, config.outfit, config.timeOutfit * 60 * 1000)  

Postado

Eu não testei.

O script apenas exige que o player esteja com um summon de nome Juubi, mas ele não summona um.

 

Spell:

local config = {
summonName = "Juubi",
message = "Mensagem ao morrer",
pos = {x = 1500, y = 1323, z = 7}, -- pos do templo.
timeOutfit = 5, -- quantos minutos vai ficar com a outfit.
outfit = {lookType = 30 , lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookAddons = 0},
health = 300000, -- quanto vai curar.
timeInterval = 5, -- segundos entre uma cura e outra. Tem que ser divisível por 60.
storageTime = 513269,
exhaust = 513270,
cooldown = 10, -- cooldown em minutos.
color = 30, -- cor do texto que vai sair quando o player for curado.
effectInYou = 29,
effectInSummon = 18,
}

local times = 0

local function doHealPlayer (cid, minutesHealing, interval, storageTime, health, color)
	if times == minutesHealing then
		setPlayerStorageValue (cid, storageTime, 0)
		setPlayerStorageValue (cid, 513271, -1)
		times = 0
		doRemoveCondition (cid, CONDITION_OUTFIT)
		doTeleportThing (cid, config.pos)
		doPlayerPopupFYI (cid, config.message)
		doCreatureSetNoMove (cid, true)
		addEvent (doRemoveCreature, 1000, cid)
	return true
	end
	
	if getPlayerStorageValue (cid, storageTime) >= 0 then
		setPlayerStorageValue (cid, storageTime, getPlayerStorageValue (cid, storageTime) + interval)
		doCreatureAddHealth (cid, health)
		addEvent (doHealPlayer, interval * 1000, cid, minutesHealing, interval, storageTime, health, color)
		doSendAnimatedText (getThingPos (cid), "+ "..health, color)
		
		if getPlayerStorageValue (cid, storageTime) == 60 then
			times = times + 1
			setPlayerStorageValue (cid, storageTime, 0)
		end
	end
return true
end

function onCastSpell(cid, var)
	if getCreatureSummons (cid)[1] and getCreatureName (getCreatureSummons (cid)[1]) == config.summonName and isPlayer (cid) then
		if getPlayerStorageValue (cid, config.exhaust) < os.time() then
			doSendMagicEffect (getThingPos(cid), config.effectInYou)
			doSendMagicEffect (getThingPos(getCreatureSummons(cid)[1]), config.effectInSummon)
			doRemoveCreature (getCreatureSummons (cid)[1])
			doSetCreatureOutfit (cid, config.outfit, config.timeOutfit * 60 * 1000)
			doHealPlayer(cid, config.timeOutfit, config.timeInterval, config.storageTime, config.health, config.color)
			setPlayerStorageValue (cid, config.exhaust, config.cooldown * 60 + os.time())
			doCreatureSay (cid, "AAAHHHHHHHHHHHHHHHH!!!!!!", 19)
		else
			doPlayerSendCancel (cid, "You're exhausted.")
		end
	else
		doPlayerSendCancel (cid, "Você precisa ter um summon com o nome de "..config.summonName..".")
	end
return true
end

 

creaturescripts/scripts

nome_arquivo.lua

function onLogin(cid)
	setPlayerStorageValue (cid, 513269, 0)
	if getPlayerStorageValue (cid, 513269) >= 0 and getPlayerStorageValue (cid, 513271) == 1 then
		doRemoveCondition (cid, CONDITION_OUTFIT)
		setPlayerStorageValue (cid, 513269, -1)
		setPlayerStorageValue (cid, 513271, -1)
	end
return true
end

function onLogout (cid)
	setPlayerStorageValue (cid, 513271, 1)
return true
end

 

XML:

<event type="login" name="eventName" event="script" value="nome_arquivo.lua"/>
<event type="logout" name="eventName" event="script" value="nome_arquivo.lua"/>

 

login.lua

registerCreatureEvent(cid, "eventName")

 

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

Não dou suporte via PM, crie um tópico caso tenha dúvidas.

Isso previne que outras pessoas com a mesma dúvida criem tópicos desnecessários.

Postado
  • Autor
17 minutos atrás, Talesigorvr disse:

Eu não testei.

O script apenas exige que o player esteja com um summon de nome Juubi, mas ele não summona um.

 

Spell:


local config = {
summon = getCreatureSummons (cid)[1],
summonName = "Juubi",
message = "Mensagem ao morrer",
pos = {x = 1500, y = 1323, z = 7}, -- pos do templo.
timeOutfit = 5, -- quantos minutos vai ficar com a outfit.
outfit = {lookType = 30 , lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookAddons = 0},
health = 300000, -- quanto vai curar.
timeInterval = 5, -- segundos entre uma cura e outra. Tem que ser divisível por 60.
storageTime = 513269,
exhaust = 513270,
cooldown = 10, -- cooldown em minutos.
color = 30, -- cor do texto que vai sair quando o player for curado.
}

local times = 0

local function doHealPlayer (cid, minutesHealing, interval, storageTime, health, color)
	if times == minutesHealing then
		setPlayerStorageValue (cid, storageTime, -1)
		setPlayerStorageValue (cid, 513271, -1)
		times = 0
		doRemoveCondition (cid, CONDITION_OUTFIT)
		doTeleportThing (cid, config.pos)
		doPlayerPopupFYI (cid, config.message)
		doCreatureSetNoMove (cid, true)
		addEvent (doRemoveCreature, 1000, cid)
	return true
	end
	
	if storageTime >= 0 then
		setPlayerStorageValue (cid, storageTime, getPlayerStorageValue (cid, storageTime) + interval)
		doCreatureAddHealth (cid, health)
		addEvent (doHealPlayer, interval * 1000, cid, minutesHealing, interval, storageTime, health, color)
		addEvent (doSendAnimatedText, interval * 1000, getThingPos (cid), "+ "..health, color)
		
		if getPlayerStorageValue (cid, storageTime) == 60 then
			times = times + 1
		end
	end
return true
end

function onCastSpell(cid, var)
	if config.summon and config.summon >= 1 and getCreatureName (config.summon) == config.summonName and isPlayer (cid) then
		if getPlayerStorageValue (cid, config.exhaust) < os.time() then
			doRemoveCreature (config.summon)
			doSetCreatureOutfit (cid, config.looktype, config.timeOutfit * 60 * 1000)
			doHealPlayer(cid, config.timeOutfit, config.timeInterval, config.storageTime, config.health, config.color)
			setPlayerStorageValue (cid, config.exhaust, config.cooldown * 60 + os.time())
		else
			doPlayerSendCancel (cid, "You're exhausted.")
		end
	end
return true
end

 

creaturescripts/scripts

nome_arquivo.lua


function onLogin(cid)
	setPlayerStorageValue (cid, 513269, 0)
	if getPlayerStorageValue (cid, 513269) >= 0 and getPlayerStorageValue (cid, 513271) == 1 then
		doRemoveCondition (cid, CONDITION_OUTFIT)
		setPlayerStorageValue (cid, 513269, -1)
		setPlayerStorageValue (cid, 513271, -1)
	end
return true
end

function onLogout (cid)
	setPlayerStorageValue (cid, 513271, 1)
return true
end

 

XML:


<event type="login" name="eventName" event="script" value="nome_arquivo.lua"/>
<event type="logout" name="eventName" event="script" value="nome_arquivo.lua"/>

 

login.lua


registerCreatureEvent(cid, "eventName")

 

so nao tendi aqui login e logout tipo

Juubi.lua eu coloco em cual dos 2?

Juubi.lua e o aquivo 2 q vc mandou nao é spell

<event type="login" name="eventName" event="script" value="nome_arquivo.lua"/>
<event type="logout" name="eventName" event="script" value="nome_arquivo.lua"/>
Postado

@zPerseu o creaturescript é o mesmo nome. Juubi.lua nos dois.

Apenas o primeiro código é spell.

Eu não sei muito bem criar spell para tibia, eu criei como se fosse uma talkaction... Fiz como spell por causa da vocation e tal. Suponho que seja dessa forma.

Não dou suporte via PM, crie um tópico caso tenha dúvidas.

Isso previne que outras pessoas com a mesma dúvida criem tópicos desnecessários.

Postado
  • Autor
4 minutos atrás, Talesigorvr disse:

@zPerseu o creaturescript é o mesmo nome. Juubi.lua nos dois.

Apenas o primeiro código é spell.

Eu não sei muito bem criar spell para tibia, eu criei como se fosse uma talkaction... Fiz como spell por causa da vocation e tal. Suponho que seja dessa forma.

http://prntscr.com/c9m6m5

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

Informação Importante

Confirmação de Termo