Advertisement
Samatter

script_tps.label_start

May 29th, 2021 (edited)
79
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.90 KB | None
  1. Set(@tps_label_active,1)
  2. SetLabel("tps.label","Starting...")
  3. UnSafe()
  4. Do()
  5. #tick_1=%TICKS%
  6. Wait(10)
  7. #tick_2=%TICKS%
  8. &result="T1 = %#tick_1% / T2 = %#tick_2%\n"
  9. #tick_delta=#tick_2-#tick_1
  10. If(%#tick_delta%<0)
  11. Inc(#tick_delta,24000)
  12. EndIf
  13. If(%#tick_delta%>20000)
  14. &result="%&result%Heavy TPS Lag"
  15. Else
  16. &tps_array[]=Split("",%#tick_delta%)
  17. #tps_array_size=ArraySize(&tps_array[])
  18. If(%#tps_array_size%==1)
  19. &tps="0.%#tick_delta%"
  20. Else
  21. Pop(&tps_array[],&tps_array_last_digit)
  22. Push(&tps_array[],".%&tps_array_last_digit%")
  23. &tps=Join("",&tps_array[])
  24. EndIf
  25. &result="%&result%Current TPS = %&tps%"
  26. EndIf
  27. SetLabel("tps.label",%&result%)
  28. Loop
  29. EndUnSafe
Advertisement
RAW Paste Data Copied
Advertisement