Preciso dessa spell mas assim não dá pra usar, só formata ela direitinho pois ficou tudo emendado e ta dando erro.
- Forums
- OTServ
- Recursos
- Scripting
- Globalevents e Spells
- [SPELL] Tank Mode
info
Group: Visconde
Joined: 09/08/10
Posts: 314
Reputation: +19
Tibia Character: não tenho

info
Group: Infante
Joined: 22/12/12
Posts: 2k
Reputation: +736
Gender: Masculino
Tibia Character: Marley

12 minutos atrás, diarmaint disse:Preciso dessa spell mas assim não dá pra usar, só formata ela direitinho pois ficou tudo emendado e ta dando erro.
É só dar enter no fim de cada linha.
info
Group: Visconde
Joined: 09/08/10
Posts: 314
Reputation: +19
Tibia Character: não tenho

Agora, bXnny disse:É só dar enter no fim de cada linha.
Eu até tentei só que toda tentativa dava crash no serv, não sei mto separar as linhas das funções.
info
Group: Colaborador
Joined: 27/12/10
Posts: 271
Reputation: +87
Gender: Masculino

tempo = 10 -- Tempo de duração da spell em segundos hp = 10000 -- Quanto HP vai healar a cada x segundos function heal(cid) if not isCreature(cid) then return true end if getPlayerStorageValue(cid, 13978) == 1 then doCreatureAddHealth(cid, hp) addEvent(heal, 3000, cid) return true end return true end function onCastSpell(cid, var) setPlayerStorageValue(cid, 13978, 1) doPlayerSetNoMove(cid, true)heal(cid) doSendMagicEffect(getCreaturePosition(cid), 26) addEvent(setPlayerStorageValue, tempo*1000, cid, 13978, -1) addEvent(doPlayerSetNoMove, tempo*1000, cid, false) return true end
info
Group: Visconde
Joined: 09/08/10
Posts: 314
Reputation: +19
Tibia Character: não tenho

21 minutos atrás, Kuro o Shiniga disse:tempo = 10 -- Tempo de duração da spell em segundos hp = 10000 -- Quanto HP vai healar a cada x segundos function heal(cid) if not isCreature(cid) then return true end if getPlayerStorageValue(cid, 13978) == 1 then doCreatureAddHealth(cid, hp) addEvent(heal, 3000, cid) return true end return true end function onCastSpell(cid, var) setPlayerStorageValue(cid, 13978, 1) doPlayerSetNoMove(cid, true)heal(cid) doSendMagicEffect(getCreaturePosition(cid), 26) addEvent(setPlayerStorageValue, tempo*1000, cid, 13978, -1) addEvent(doPlayerSetNoMove, tempo*1000, cid, false) return true end
Lua Script Error: [Spell Interface]
data/spells/scripts/diarmaint/tank.lua:onCastSpell
data/spells/scripts/diarmaint/tank.lua:16: attempt to call global 'doPlayerSetNoMove' (a nil value)
stack traceback:
[C]: in function 'doPlayerSetNoMove'
data/spells/scripts/diarmaint/tank.lua:16: in function <data/spells/scripts/diarmaint/tank.lua:14>



info
Group: Visconde
Joined: 23/02/17
Posts: 368
Reputation: +136
Gender: Masculino
È uma spell que ao usar voce heala "X" por "Y" segundos assim não podendo se mecher.! Uma script simples que pode ser usada por muitos.
data/spells/script
Tank.lua
Spells.xml: