Advertisement
EzFlow997

DLL Delay Example

Apr 17th, 2024
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. timeCheckDelay := 922 // time delay in ms
  2. Start(){
  3. While(toggle = 1){
  4. Send {Space Down}
  5. DllCall("QueryPerformanceFrequency", "Int64*", freq) // initialize Performance Frequency value to Variable
  6. DllCall("QueryPerformanceCounter", "Int64*", CounterBefore) // initialize Performance Counter value to Variable
  7. DllCall("QueryPerformanceCounter", "Int64*", CounterAfter) // initialize Performance Counter value to Variable
  8. While((CounterAfter - CounterBefore) / freq * 1000 <= timeCheckDelay){ // waits for 922 ms
  9. DllCall("QueryPerformanceCounter", "Int64*", CounterAfter) // updates CounterAfter value
  10. }
  11. Send {Space Up}
  12. ;Debug()
  13. }
  14. }}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement