Sigoles
Discord: @sigoles
- Joined
- Nov 20, 2015
- Messages
- 1,209
- Solutions
- 2
- Reaction score
- 154
I trying to do something like this:
When player is in X position, the npc turn East, someone can help? Thanks
Code:
function onThink()
local cid = getNpcCid()
local npc = Creature(cid)
local npcpos = {x = 32352, y = 32226, z = 7}
local posplayer = {x = 32354, y = 32226, z = 7} -- 32354, 32226, 7
if ppos.x == posplayer.x and ppos.y == posplayer.y then
selfTurn(EAST)
else
selfTurn(SOUTH)
end
end
When player is in X position, the npc turn East, someone can help? Thanks
Last edited by a moderator: