Burgershot
  • Home
  • Members
  • Team
  • Help
  • Search
  • Register
  • Login
  • Home
  • Members
  • Help
  • Search
Burgershot SA-MP Pawn Scripting [Pawn] record time

 
  • 0 Vote(s) - 0 Average
Pawn record time
Zow
Offline

Burgershot Member
Posts: 34
Threads: 20
Joined: Apr 2019
Reputation: 0
Location: Malaysia
#1
2021-11-12, 11:05 PM
PHP Code:
main() { 
SetTimer("update", 10, true);
}

ReturnTime(timevariable)
//Used in the OnPlayerEnterRaceCheckpoint code.
{
    new milliseconds = timevariable, string[20];
    while(milliseconds > 999)
    {
        //Add to the seconds variable
        milliseconds = milliseconds - 10;
        //Take away 10 from the ms variable
    }
    format(string, sizeof(string), "%05d", milliseconds);
    return string;
} 


Quote:00588
00589
00590
00591
00592
00593
00594
00595
00596
00597
00598
00599

I just want them to be like this https://youtu.be/v62Gt38ngzM?t=28
[Image: unknown.png]

7.865 second

Any help please
Y_Less
Offline

Administrator

Posts: 323
Threads: 16
Joined: Feb 2019
Reputation: 90
#2
2021-11-18, 11:20 PM
Divide by 60000 for minutes, mod by 60000 for milliseconds, divide that by 1000 for seconds.
« Next Oldest | Next Newest »



  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Burgershot - Powered by our Community and MyBB Original Theme by Emerald

Linear Mode
Threaded Mode