Por Newtonnotwen, 09 de ago. de 2012 em Globalevents e Spells
info
Grupo: Conde
Registrado: 04/08/12
Posts: 762
Reputação: +80
Aew, galera venho trazer pra vocês uma spell que sumona um bixo, e apos certo tempo ele some.
local removeTime = 1.0
local mana = 1000
local HAVE_CLONE = 655370
local arr = {
{
{0, 0, 0},
{0, 2, 0},
{0, 1, 0}
}
local function removeCreatures(cid, creature)
setPlayerStorageValue(cid, HAVE_CLONE, 0)
if isCreature(creature) == TRUE then
doRemoveCreature(creature)
end
function onTargetTile(cid, pos)
local creature = doSummonCreature("crystal spider", pos)
doCreatureAddMana(cid, -2000)
doCreatureSay(cid, "Utevo Aura", TALKTYPE_ORANGE_1)
doConvinceCreature(cid, creature)
addEvent(removeCreatures, removeTime * 5000, cid, creature)
return TRUE
local combat = {}
for i = 1, 1 do
combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_POFF)
setCombatArea(combat, createCombatArea(arr))
_G["onTargetTile" .. i] = onTargetTile
setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile" .. i)
function onCastSpell(cid, var)
local level = getPlayerLevel(cid)
if getPlayerStorageValue(cid, HAVE_CLONE) < 1 then
if level > 350 then
doCombat(cid, combat[1], var)
else
setPlayerStorageValue(cid, HAVE_CLONE, 1)
doPlayerSendCancel(cid, "a crystal spider ja foi sumonada.")
Laranja: nome do monstro
Vermelho: altere de acordo com o(a)
-Verde: Tempo que vai remover o monstro (1000 = 1segundo)
- - - - - - - - - - - - - - - - - - -Daqui pra baixo os créditos são totalmente de lordbug99
By: lordbug99
Vai em creaturescript/script abre login.lua e antes do ultimo end coloca:
setPlayerStorageValue(cid, 655370, 0)
info
Grupo: Conde
Registrado: 04/08/12
Posts: 762
Reputação: +80
Aew, galera venho trazer pra vocês uma spell que sumona um bixo, e apos certo tempo ele some.
local removeTime = 1.0
local mana = 1000
local HAVE_CLONE = 655370
local arr = {
{
{0, 0, 0},
{0, 2, 0},
{0, 1, 0}
}
}
local function removeCreatures(cid, creature)
setPlayerStorageValue(cid, HAVE_CLONE, 0)
if isCreature(creature) == TRUE then
doRemoveCreature(creature)
end
end
function onTargetTile(cid, pos)
local creature = doSummonCreature("crystal spider", pos)
doCreatureAddMana(cid, -2000)
doCreatureSay(cid, "Utevo Aura", TALKTYPE_ORANGE_1)
doConvinceCreature(cid, creature)
addEvent(removeCreatures, removeTime * 5000, cid, creature)
return TRUE
end
local combat = {}
for i = 1, 1 do
combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_POFF)
setCombatArea(combat, createCombatArea(arr))
_G["onTargetTile" .. i] = onTargetTile
setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile" .. i)
end
function onCastSpell(cid, var)
local level = getPlayerLevel(cid)
if getPlayerStorageValue(cid, HAVE_CLONE) < 1 then
if level > 350 then
doCombat(cid, combat[1], var)
else
doCombat(cid, combat[1], var)
end
setPlayerStorageValue(cid, HAVE_CLONE, 1)
else
doPlayerSendCancel(cid, "a crystal spider ja foi sumonada.")
end
end
Laranja: nome do monstro
Vermelho: altere de acordo com o(a)
-Verde: Tempo que vai remover o monstro (1000 = 1segundo)
- - - - - - - - - - - - - - - - - - -Daqui pra baixo os créditos são totalmente de lordbug99
By: lordbug99
Vai em creaturescript/script abre login.lua e antes do ultimo end coloca: