Ir para conteúdo

Featured Replies

Postado

Olá pessoal, por algum motivo meu EVENTO WOE funciona quase 100% a não ser de um coisa. Quando tento fazer que player possa sumona o guardinha o mesmo não funciona.

Script:
 

dofile("./_woe.lua")

local delays = 60

local guards_price = 30000	--30k

function onUse(cid, item, fromPosition, itemEx, toPosition)
	Woe.getInfo()
	if item.actionid == Castle.banderas then
		if Woe.isTime() then
			if Woe.isStarted() then
				if infoLua[2] == getPlayerGuildId(cid) then
					doTeleportThing(cid, Castle.guildEntry, false)
				else
					doPlayerSendCancel(cid, "You are not member of ".. Woe.guildName() ..".")
				end
			end
		else
			if infoLua[2] == getPlayerGuildId(cid) then
				doTeleportThing(cid, Castle.guildEntry, false)
			else
				doPlayerSendCancel(cid, "You are not member of ".. Woe.guildName() ..".")
			end
		end
	elseif (item.uid == 3134) then
		if not Woe.isStarted() or (infoLua[2] ~= getPlayerGuildId(cid)) or (getPlayerGuildLevel(cid) ~= GUILDLEVEL_LEADER) then
			return true
		end
		if (getPlayerMoney(cid) < guards_price) then
			return doPlayerSendCancel(cid, "Not enough money.")
		end
		local varDelay = getGlobalStorageValue(24503)
		if (varDelay < 0) or ((os.time() - varDelay) >= delays) then
			if Woe.check() then
				Woe.summon()
				doPlayerRemoveMoney(cid, guards_price)
			else
				doPlayerSendCancel(cid, "There are still guards alive.")
			end
		else
			doPlayerSendCancel(cid, "Delay no listo.")
		end
	end
	return true
end

Foto do suposto erro:
 

Screenshot_2.png

Postado

Você não criou o monstro "guard". Deve ter alguma coisa relacionada no tópico onde você tirou o script.

Não se esqueça de dar REP+ para quem te ajudou e caso seja a solução marcar como melhor resposta!

 

NÃO CLIQUE AQUI!

NEM AQUI!

________________________________________________________________________________________________________________________________________________________________________________________________________________________

 

A imaginação é mais importante que o conhecimento.” Albert Einstein

Postado
  • Autor

Tenho o mostro guard, está perfeito o mostro kkk

<?xml version="1.0" encoding="UTF-8"?>
<monster name="Guard" nameDescription="a guard" race="blood" experience="0" speed="220" manacost="0">
	<health now="240000" max="240000"/>
	<look type="57" corpse="6080"/>
	<targetchange interval="10000" chance="1"/>
	<strategy attack="100" defense="0"/>
	<flags>
		<flag summonable="0"/>
		<flag attackable="1"/>
		<flag hostile="1"/>
		<flag illusionable="0"/>
		<flag convinceable="0"/>
		<flag pushable="0"/>
		<flag canpushitems="1"/>
		<flag canpushcreatures="1"/>
		<flag targetdistance="1"/>
		<flag staticattack="90"/>
		<flag runonhealth="0"/>
	</flags>
	<attacks>
		<attack name="melee" interval="2000" skill="30" attack="70"/>
	</attacks>
	<defenses armor="20" defense="22">
		<defense name="healing" interval="1000" chance="17" min="30" max="50">
			<attribute key="areaEffect" value="blueshimmer"/>
		</defense>
		<defense name="speed" interval="1000" chance="10" speedchange="300" duration="3000">
			<attribute key="areaEffect" value="redshimmer"/>
		</defense>
	</defenses>
	<elements>
		<element holyPercent="50"/>
		<element deathPercent="50"/>
		<element physicalPercent="-15"/>
	</elements>
	<immunities>
		<immunity invisible="1"/>
	</immunities>
	<voices interval="5000" chance="10">

	</voices>
</monster>

Aqui está ele.

Postado

Vou tentar te ajudar.

Além de ter o script.xml do guard, tem que adiciona-lo no arquivo monster.xml, caso tu tenha feito isso e continua com erro, posta o arquivo woe.

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