Hameq
Banned User
- Joined
- Aug 8, 2010
- Messages
- 374
- Reaction score
- 36
Hello,
First my character is Focused with npc, second character trying to Focus he i supposed to wait in queue, npc said he have to wait, everything is normal but when i logout the second character and ungreet first i geting this error. Dunno if Jiddo's npc system fail or someting anyway i need help.
error:
I think here is something wrong:
First my character is Focused with npc, second character trying to Focus he i supposed to wait in queue, npc said he have to wait, everything is normal but when i logout the second character and ungreet first i geting this error. Dunno if Jiddo's npc system fail or someting anyway i need help.
error:
Code:
[06/10/2011 13:03:02] Lua Script Error: [Npc interface]
[06/10/2011 13:03:02] data/npc/scripts/frodo.lua:onThink
[06/10/2011 13:03:02] luaGetCreaturePosition(). Creature not found
I think here is something wrong:
Code:
function NpcHandler:isInRange(cid)
local playerPos = getPlayerPosition(cid)
if playerPos == LUA_ERROR or playerPos == LUA_NO_ERROR then
return false
end
local sx, sy, sz = selfGetPosition()
local dx = math.abs(sx-playerPos.x)
local dy = math.abs(sy-playerPos.y)
local dz = math.abs(sz-playerPos.z)
local dist = (dx^2 + dy^2)^0.5
return (dist <= self.talkRadius and dz == 0)
end
Last edited: