3 horas atrás, Yan18 disse:
De nada! Que bom que funcionou, porém eu estava pensando aqui, e do jeito que eu fiz pode ser que dê problema em uma ocasião, caso o player deslogue com a outfit de monstro. Faz um teste, desloga com a outfit de monstro e loga novamente, vê se volta normal como player, e se voltar como monstro, clica no item e vê se vira outro monstro.
Sobre o outro tópico, eu vi, mas não entendi muito bem o seu pedido, quando fala de summon está falando de monstro ou de criar um teleport?
naverdade yan ja errei denovo o topico deveria ser spells acredito eu pq tem os sunovos sumons do tibia eu tenho eles no meu servidor 8.6 mas os sumons nao teleporta se eu subir uma escada ou descer eles nao vai ate o player nao sei pq na versao 12 eles ja teleporta ate o player usando mesmo script vou mandar o script pra vc da uma olhada
local config = {
[7737] = {7, 96, 214, 70, 23, 859, 857, 21},
[7739] = {220, 35, 244, 55, 91, 854, 855, 856, 13},
[9076] = {47, 237, 78, 257, 99, 854, 855, 856, 859, 857, 60}
}
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
local storage = 33330 -- Escolha a Storage do seu Agrado!
local monsterNames = config[item.itemid]
local condition = Condition(CONDITION_OUTFIT)
local dale = monsterNames[math.random(#monsterNames)]
condition:setOutfit(dale, dale)
condition:setTicks(300*1000)
if not monsterNames then
return true
end
if player:getStorageValue(storage) < 1 then
player:sendTextMessage(MESSAGE_STATUS_DEFAULT, 'You will stay 5 minutes transformed in a monster!')
player:addAchievementProgress('Masquerader', 100)
item:getPosition():sendMagicEffect(40)
player:addCondition(condition)
player:setStorageValue(storage, 2)
player:changeSpeed(40)
addEvent(function() if player:getStorageValue(storage) == 2 then player:changeSpeed(-40) player:setStorageValue(storage, 0) end end, 300*1000)
else
player:sendTextMessage(MESSAGE_STATUS_DEFAULT, 'You lost your monster disguise!')
player:removeCondition(CONDITION_OUTFIT)
player:setStorageValue(storage, 0)
player:changeSpeed(-40)
end
return true
end
e esse outro script seria de uma das criaturas ai ja nao sei se teria que mecher no script do spells do sumons ou da criatura vo mandar aki embaixo o da criatura.
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Grovebeast" nameDescription="Grovebeast" race="undead" speed="500" manacost="3000">
<health now="20000" max="20000" />
<look type="993" corpse="0" />
<targetchange interval="4000" chance="20" />
<targetstrategies nearest="70" health="10" damage="10" random="10" />
<flags>
<flag pet="1" />
<flag summonable="0" />
<flag attackable="1" />
<flag hostile="0" />
<flag illusionable="0" />
<flag convinceable="0" />
<flag pushable="1" />
<flag canpushitems="0" />
<flag canpushcreatures="1" />
<flag staticattack="98" />
<flag targetdistance="0" />
<flag runonhealth="9000" />
</flags>
<attacks>
<attack name="melee" interval="200" chance="45" min="-100" max="-300" />
<attack name="earth" interval="1000" chance="10" target="1" spread="0" min="0" max="-800">
<attribute key="areaEffect" value="stones" />
</attack>
<attack name="lifedrain" interval="2000" chance="20" target="1" range="1" min="-50" max="-200">
<attribute key="areaEffect" value="redshimmer" />
</attack>
<attack name="earth" interval="2000" chance="15" length="2" spread="3" min="-250" max="-500">
<attribute key="areaEffect" value="carniphila" />
</attack>
<attack name="Challenge" interval="500" chance="3" radius="8">
<attribute key="areaEffect" value="exeta res" />
</attack>
</attacks>
<defenses armor="78" defense="95">
<defense name="healing" interval="3000" chance="16" min="80" max="600">
<attribute key="areaEffect" value="blueshimmer" />
</defense>
<defense name="Challenge" interval="100" chance="15">
<attribute key="areaEffect" value="exeta res" />
</defense>
</defenses>
<elements>
<element firePercent="0" />
<element earthPercent="0" />
<element energyPercent="0" />
<element deathPercent="0" />
<element physicalPercent="0" />
<element holyPercent="0" />
<element icePercent="0" />
</elements>
<immunities>
<immunity paralyze="1" />
<immunity invisible="1" />
</immunities>
</monster>