Faltou um ) no doTeleportThing.
Tenta isso;
function onSay(cid)
local configs = {
posX = (20800),
posY = (20801)
}
local result = {
x = getPlayerStorageValue(cid, configs.posX),
y = getPlayerStorageValue(cid, configs.posY)
}
local position = getCreaturePosition(cid)
setPlayerStorageValue(cid, configs.posX, position.x)
setPlayerStorageValue(cid, configs.posY, position.y)
if position.z ~= 0 then
repeat
doTeleportThing(cid, {x = position.x, y = position.y, z = position.z+1})
until
position = {x = result.x, y = result.y, z = 0}
end
return FALSE
end