1
0

timertest.pwn 705 B

12345678910111213141516171819202122232425262728293031
  1. #include <a_samp>
  2. forward OneSecTimer();
  3. main()
  4. {
  5. print("\n----------------------------------");
  6. print(" This is a blank GameModeScript");
  7. print("----------------------------------\n");
  8. //printf("GetVehicleComponentType %u",GetVehicleComponentType(1100));
  9. }
  10. public OnGameModeInit()
  11. {
  12. // Set timer of 1 second.
  13. SetTimer("OneSecTimer", 1000, 1);
  14. print("GameModeInit()");
  15. SetGameModeText("Timer Test");
  16. AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
  17. return 1;
  18. }
  19. public OneSecTimer() {
  20. new sText[256];
  21. format(sText,sizeof(sText),"GetTickCount = %d",GetTickCount());
  22. print(sText);
  23. SendClientMessageToAll(0xFF0000, sText);
  24. }