i have this problem on the console:
[3:22:34.021] [Error - Action Interface]
[3:22:34.021] data/actions/scripts/zao/zao arena 3.luanUse
[3:22:34.021] Description:
[3:22:34.021] (luaGetThingFromPos) Tile not found
and this is my creaturescript D= what happen?
and this is my action script
[3:22:34.021] [Error - Action Interface]
[3:22:34.021] data/actions/scripts/zao/zao arena 3.luanUse
[3:22:34.021] Description:
[3:22:34.021] (luaGetThingFromPos) Tile not found
and this is my creaturescript D= what happen?
local t = {
newPos = {x=33062, y=31029, z=7},
msg = "Eres el nuevo Herue de Kripton Recoje tu Outfit y largate xD.",
area = {
fromX = 33054, toX = 33073,
fromY = 31026, toY = 32346,
z = 3
}
}
function getCreaturesInRange(position, radiusx, radiusy, showMonsters, showPlayers, showSummons)
local creaturesList = {}
for x = -radiusx, radiusx do
for y = -radiusy, radiusy do
if not (x == 0 and y == 0) then
creature = getTopCreature({x = position.x+x, y = position.y+y, z = position.z, stackpos = 253})
if (creature.type == 1 and showPlayers == TRUE) or (creature.type == 2 and showMonsters == TRUE and (showSummons == FALSE or (showSummons == TRUE and getCreatureMaster(creature.uid) == (creature.uid)))) then
table.insert(creaturesList, creature.uid)
end
end
end
end
local creature = getTopCreature(position)
if(creature.type == 1 and showPlayers == TRUE) or (creature.type == 2 and showMonsters == TRUE and (showSummons == FALSE or (showSummons == TRUE and getCreatureMaster(creature.uid) == (creature.uid)))) then
if not(table.find(creaturesList, creature.uid)) then
table.insert(creaturesList, creature.uid)
end
end
return creaturesList
end
function onKill(cid, target, damage, flags)
local name = getCreatureName(target):lower()
if name == 'tirecz' then
local players = getCreaturesInRange({x=33063, y=31035,z=3}, 10, 9, FALSE, TRUE)
for i = 1, #players do
doTeleportThing(players, t.newPos)
doCreatureSay(players, t.msg, TALKTYPE_ORANGE_1, false, players, getCreaturePosition(players))
end
end
return true
end
and this is my action script
local room = { -- room with demons
fromX = 33053,
fromY = 31025,
fromZ = 3,
toX = 33073,
toY = 31044,
toZ = 3
}
local players_pos = {
{x = 33080, y =31014, z = 2, stackpos = 253},
{x = 33081, y =31014, z = 2, stackpos = 253}
}
local new_player_pos = {
{x = 33059, y = 31032, z = 3},
{x = 33057, y = 31034, z = 3}
}
local playersOnly = "yes"
local questLevel = 80
function getCreaturesInRange(position, radiusx, radiusy, showMonsters, showPlayers, showSummons, fromPosition, toPosition)
local creaturesList = {}
for x = -radiusx, radiusx do
for y = -radiusy, radiusy do
if not (x == 0 and y == 0) then
creature = getTopCreature({x = position.x+x, y = position.y+y, z = position.z, stackpos = 253})
if (creature.type == 1 and showPlayers == TRUE) or (creature.type == 2 and showMonsters == TRUE and (showSummons == FALSE or (showSummons == TRUE and getCreatureMaster(creature.uid) == (creature.uid)))) then
table.insert(creaturesList, creature.uid)
end
end
end
end
local creature = getTopCreature(position)
if (creature.type == 1 and showPlayers == TRUE) or (creature.type == 2 and showMonsters == TRUE and (showSummons == FALSE or (showSummons == TRUE and getCreatureMaster(creature.uid) == (creature.uid)))) then
if not(table.find(creaturesList, creature.uid)) then
table.insert(creaturesList, creature.uid)
end
end
return creaturesList
end
function Wave1()
doSendMagicEffect(getCreaturePosition(doSummonCreature('Baron Brute', {x = 33064, y = 31033, z = 3})), CONST_ME_TELEPORT)
doSendMagicEffect(getCreaturePosition(doSummonCreature('The Axeorcist', {x = 33065, y = 31034, z = 3})), CONST_ME_TELEPORT)
addEvent(Wave2, 30 * 1000)
end
function Wave2()
doSendMagicEffect(getCreaturePosition(doSummonCreature('Menace', {x = 33064, y = 31033, z = 3})), CONST_ME_TELEPORT)
doSendMagicEffect(getCreaturePosition(doSummonCreature('Fatality', {x = 33065, y = 31034, z = 3})), CONST_ME_TELEPORT)
addEvent(Wave3, 35 * 1000)
end
function Wave3()
doSendMagicEffect(getCreaturePosition(doSummonCreature('Incineron', {x = 33064, y = 31033, z = 3})), CONST_ME_TELEPORT)
doSendMagicEffect(getCreaturePosition(doSummonCreature('Coldheart', {x = 33065, y = 31034, z = 3})), CONST_ME_TELEPORT)
addEvent(Wave4, 40 * 1000)
end
function Wave4()
doSendMagicEffect(getCreaturePosition(doSummonCreature('Dreadwing', {x = 33064, y = 31033, z = 3})), CONST_ME_TELEPORT)
doSendMagicEffect(getCreaturePosition(doSummonCreature('Doomhowl', {x = 33065, y = 31034, z = 3})), CONST_ME_TELEPORT)
addEvent(Wave5, 40 * 1000)
end
function Wave5()
doSendMagicEffect(getCreaturePosition(doSummonCreature('Haunter', {x = 33064, y = 31033, z = 3})), CONST_ME_TELEPORT)
addEvent(Wave6, 40 * 1000)
end
function Wave6()
doSendMagicEffect(getCreaturePosition(doSummonCreature('The Dreadorian', {x = 33064, y = 31033, z = 3})), CONST_ME_TELEPORT)
doSendMagicEffect(getCreaturePosition(doSummonCreature('Rocko', {x = 33065, y = 31034, z = 3})), CONST_ME_TELEPORT)
doSendMagicEffect(getCreaturePosition(doSummonCreature('Tremorak', {x = 33064, y = 31032, z = 3})), CONST_ME_TELEPORT)
addEvent(Wave7, 40 * 1000)
end
function Wave7()
doSendMagicEffect(getCreaturePosition(doSummonCreature('Tirecz', {x = 33065, y = 31034, z = 3})), CONST_ME_TELEPORT)
end
function onUse(cid, item, fromPosition, itemEx, toPosition)
local all_ready, monsters, player, level = 0, 0, {}, 0
if item.itemid == 1945 then
for i = 1, #players_pos do
table.insert(player, 0)
end
for i = 1, #players_pos do
player = getThingfromPos(players_pos)
if player.itemid > 0 then
if string.lower(playersOnly) == "yes" then
if isPlayer(player.uid) == TRUE then
all_ready = all_ready+1
else
monsters = monsters+1
end
else
all_ready = all_ready+1
end
end
end
if all_ready == #players_pos then
for i = 1, #players_pos do
player = getThingfromPos(players_pos)
if isPlayer(player.uid) == TRUE then
if getPlayerLevel(player.uid) >= questLevel then
level = level+1
end
else
level = level+1
end
end
if level == #players_pos then
if string.lower(playersOnly) == "yes" and monsters == 0 or string.lower(playersOnly) == "no" then
for i = 1, #players_pos do
doSendMagicEffect(players_pos, CONST_ME_POFF)
doTeleportThing(player.uid, new_player_pos, FALSE)
doSendMagicEffect(new_player_pos, CONST_ME_ENERGYAREA)
doTransformItem(item.uid,1946)
end
Wave1()
else
doPlayerSendTextMessage(cid,19,"Only players can do this quest.")
end
else
doPlayerSendTextMessage(cid,19,"All Players have to be level "..questLevel.." to do this quest.")
end
else
doPlayerSendTextMessage(cid,19,"You need "..table.getn(players_pos).." players to do this quest.")
end
elseif item.itemid == 1946 then
local player_room = 0
for x = room.fromX, room.toX do
for y = room.fromY, room.toY do
for z = room.fromZ, room.toZ do
local pos = {x=x, y=y, z=z,stackpos = 253}
local thing = getThingfromPos(pos)
if thing.itemid > 0 then
if isPlayer(thing.uid) == TRUE then
player_room = player_room+1
end
end
end
end
end
if player_room >= 1 then
doPlayerSendTextMessage(cid,19,"There is already a team in the quest room.")
elseif player_room == 0 then
for x = room.fromX, room.toX do
for y = room.fromY, room.toY do
for z = room.fromZ, room.toZ do
local pos = {x=x, y=y, z=z,stackpos = 253}
local thing = getThingfromPos(pos)
if thing.itemid > 0 then
doRemoveCreature(thing.uid)
end
end
end
end
doTransformItem(item.uid,1945)
end
end
return TRUE
end