+Delta68 Posted January 13, 2015 Share Posted January 13, 2015 What's the easiest way to calculate moving speed? I don't need to display it. Basically, I want a timer to start when the player slows from a normal walking pace. Thanks M Quote Link to comment
+charlenni Posted January 13, 2015 Share Posted January 13, 2015 Create a countdown timer with 5 s and a variable for last position. When starting the timer, init the variable with the position of the player. In timer tick calculate the distance to the last position and save the new position to the variable (for next calculation). Now you have a walked distance in meters and a time of 5 s. distance * 720 is the speed in km/h of the player. Check this result. If it is ok, start timer again. If not, do whatever you want. Quote Link to comment
+Delta68 Posted January 13, 2015 Author Share Posted January 13, 2015 Thanks charlenni I'll give it a try Quote Link to comment
+Delta68 Posted January 20, 2015 Author Share Posted January 20, 2015 How do I get the current location of the player? Thanks Quote Link to comment
Ranger Fox Posted January 20, 2015 Share Posted January 20, 2015 How do I get the current location of the player? Player.ObjectLocation.latitude Player.ObjectLocation.longitude Quote Link to comment
+Delta68 Posted January 21, 2015 Author Share Posted January 21, 2015 Player.ObjectLocation.latitude Player.ObjectLocation.longitude Thanks for that! M Quote Link to comment
+ionka Posted October 28, 2015 Share Posted October 28, 2015 Sorry for ikstupid question: but how do this in Urwigo? Is possible in Urwigo to calculate speed like in this case? (sorry for my english). I would like avoid cheatning (e.g geocacher should walk from zone A to zone B in 5 min. The use of bicycles is prohibited) Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.