Code:
function IAmStill()
currentSpeed, runSpeed, flightSpeed, swimSpeed = GetUnitSpeed("Player")
if currentSpeed == 0 then
return true
else
return false
end
end
iam = {
still = IAmStill(),
}
Hi all, Hopefully someone can guide my blindness and show me the error of my ways. For some unknown reason i am unable to see why this is incorrectly displaying "true" even when its called when i am moving.
This is called by doing /script print(iam.still())
If i were to do print(IAmMoving()) this would show the correct result. (false when moving, true when still)
Thank you in advance to any whole can solve this annoying problem i have ran into.