Gicu
Well-Known Member
- Joined
- Feb 26, 2011
- Messages
- 187
- Reaction score
- 52
-----------------START--------------
Hello I see many question about this spell i make this for all. can crash so make copies!
English LOW ALERT!
-add line to spells.xml
-create data/spells/inv.lua
- addEvent(OMG, 5 * 1000) here u can change time!
- Error write!
--------------END---------------
Hello I see many question about this spell i make this for all. can crash so make copies!
English LOW ALERT!
-add line to spells.xml
Lua:
<instant group="support" spellid="144" name="INV" words="INV" lvl="1" mana="1" aggressive="0" selftarget="1" cooldown="1000" groupcooldown="1000" needlearn="0" script="inv.lua">
</instant>
-create data/spells/inv.lua
Lua:
local combat = Combat()
combat:setParameter(COMBAT_PARAM_EFFECT, 63)
combat:setParameter(COMBAT_PARAM_AGGRESSIVE, false)
local condition = Condition(CONDITION_INVISIBLE)
condition:setParameter(CONDITION_PARAM_TICKS, 5000)
combat:setCondition(condition)
function onCastSpell(creature, variant, isHotkey)
local player = Player(creature)
local function OMG()
player:setGhostMode(isGhost)
return true
end
addEvent(OMG, 5 * 1000)
local position = player:getPosition()
local isGhost = not player:isInGhostMode()
player:setGhostMode(isGhost)
return combat:execute(creature, variant)
end
- addEvent(OMG, 5 * 1000) here u can change time!
- Error write!
--------------END---------------