hi, i am an lua noobie and i am trying to learn so...
here's a question:
i have this command you see (its made by myself)
function displayPlayerCoordinates(thePlayer, command)
local x,y,z = getElementPosition(thePlayer)
outputChatBox("your coordinates:".. x ..",".. y ..","..z, thePlayer)
end
addCommandHandler("pos", displayPlayerCoordinates)
but when i type the command ingame it works perfectly, but it only shows coordinates that is a big float.
now my question is: how can i make my command so that is dispays the float shorter like this:
your coordinates: 567.12,542.89,8457.12
instead of
your coordinates: 567.1232385 ,542.898776, 8457.1296396
regards prolol1337
i hope you ca help me out