All that for teleporting 6 sqm forward? o.o
Use "getClosestFreeTile(cid, pos)"
if (getTilePzInfo(aPos) == TRUE and getPlayerSkullType(cid) > 0) then
return tpError(cid, "You cannot teleport into a protection zone after attacking a player.")
end
Then the only neccessary part of your scripts is
Code:if (getTilePzInfo(aPos) == TRUE and getPlayerSkullType(cid) > 0) then return tpError(cid, "You cannot teleport into a protection zone after attacking a player.") end
And I'm just trying to help you, if you don't need my help then goodbye. You just have to realize that you ain't perfect, if I tell you it's too long why don't you try think about it instead? Or atleast READ what I say instead of telling me to read what you say >.>
Shortening scripts to me is not to try to place everything in one line. Rather that there are other ways of doing what you try to do, which is the right way.