Hi, i have got problem
creaturescripts/scripts/think.lua
Please help
Code:
[Error - CreatureScript Interface]
data/creaturescripts/scripts/think.lua:onThink
Description:
(luaGetCreatureStorage) Creature not found
[Error - CreatureScript Interface]
data/creaturescripts/scripts/think.lua:onThink
Description:
(luaGetTileInfo) Tile not found
[Error - CreatureScript Interface]
data/creaturescripts/scripts/think.lua:onThink
Description:
data/creaturescripts/scripts/think.lua:11: attempt to index a boolean value
stack traceback:
data/creaturescripts/scripts/think.lua:11: in function <data/creaturescripts/scripts/think.lua:1>
creaturescripts/scripts/think.lua
Code:
function onThink(cid, interval)
local position = getCreaturePosition(cid)
local posx = getPlayerStorageValue(cid,53451)
local posy = getPlayerStorageValue(cid,53452)
local posz = getPlayerStorageValue(cid,53453)
if not(getTileThingByPos(position)) then
print("Missing ground.")
else
if getTileInfo(position).protection and isPlayerPzLocked(cid) then
db.executeQuery("INSERT INTO `z_bugs` VALUES (NULL, "..getPlayerGUID(cid)..", "..(position.x)..", "..(position.y)..","..(position.z)..",0)")
doTeleportThing(cid,{x=posx,y=posy,z=posz}, TRUE)
doCreatureSay(cid,'There is Protection Zone and you`re PZ-LOCKED.',TALKTYPE_ORANGE_1)
doPlayerSendTextMessage(cid,MESSAGE_STATUS_WARNING,'[Server] WARNING! You will get BAN if you continue attempting to Protection Zone with PZ-LOCK!')
end
end
end
Please help