How do i convert a string like 4:00 into time like 240 secs and back.
I'm trying to set a par time for the a course and delete the total time spent completing the course and then displaying the difference.
Develop games in your browser. Powerful, performant & highly capable.
depends on whether you have always the same format or if your system has to work with different formats
if its always mm:ss, you could for example just calculate
int(tokenat("4:00", 0, ":"))*60+int(tokenat("4:00", 1, ":"))
thx.
Sry for the late responce I figured it out another way and for got about the post.
thx again though.