Hello,
This is when my character advance make same effects cloud i dont want it... how it remove??
this is my script
I want on advance that say yellow "LEVEL UP" and make DistanceShoot how ediy it??
my script in creaturescript:
This is when my character advance make same effects cloud i dont want it... how it remove??
this is my script
I want on advance that say yellow "LEVEL UP" and make DistanceShoot how ediy it??
my script in creaturescript:
Code:
function useRandomColor()
local colors = {0, 5, 18, 35, 66, 78, 89, 112, 120, 129, 144, 152, 154, 156, 180, 190, 192, 205, 210, 215, 255}
return colors[math.random(1, #colors)]
end
local config = {
[0] = "Fist skill UP",
[1] = "Club skill UP",
[2] = "Sword skill UP",
[3] = "Axe skill UP",
[4] = "Distance skill UP",
[5] = "Shield skill UP",
[6] = "Fishing skill UP",
[7] = "Magic level UP",
[8] = "Level UP"
}
function onAdvance(cid, skill, oldlevel, newlevel)
local pos = getThingPosition(cid)
local effectPositions = {
{x = pos.x, y = pos.y - 3, z = pos.z},
{x = pos.x, y = pos.y + 3, z = pos.z},
{x = pos.x - 3, y = pos.y, z = pos.z},
{x = pos.x + 3, y = pos.y, z = pos.z},
{x = pos.x - 2, y = pos.y - 2, z = pos.z},
{x = pos.x + 2, y = pos.y - 2, z = pos.z},
{x = pos.x + 2, y = pos.y + 2, z = pos.z},
{x = pos.x - 2, y = pos.y + 2, z = pos.z}
}
doSendAnimatedText(pos, config[skill], useRandomColor())
for _, ePos in ipairs(effectPositions) do
doSendDistanceShoot(pos, ePos, CONST_ANI_SMALLHOLY)
end
return true
end