1-- Defina os outfits (ajuste os lookTypes conforme seu servidor)
2
3
4
5function onCastSpell(creature, variant)
6 local player = creature:getPlayer()
7 if not player then
8 return false
9 end
10
11
12 local storedOutfit = player:getOutfit()
13
14
15 player:setVocation(3)
16 player:setOutfit(temporaryOutfit)
17 player:sendExtendedOpcode(193, "3")
18
19
20 player:getPosition():sendMagicEffect(121)
21
22
23 addEvent(function()
24 if player and player:isPlayer() then
25 player:setVocation(2)
26
27 player:setOutfit(originalOutfit)
28 player:sendExtendedOpcode(193, "2")
29
30 player:getPosition():sendMagicEffect(121)
31 end
32 end, 12000) -- 120000 ms = 2 minutos
33
34 return true
35end
36