How to add random wait times properly:

Discussion in 'RuneScape 3 Cheating' started by Govind, Nov 30, 2008.

How to add random wait times properly:
  1. Unread #1 - Nov 30, 2008 at 11:44 PM
  2. Govind
    Joined:
    Apr 22, 2005
    Posts:
    7,825
    Referrals:
    13
    Sythe Gold:
    23
    Prove it! Trole Tier 1 Prizebox Tortoise Penis Le Monkey UWotM8? Wait, do you not have an Archer rank? Potamus

    Govind The One Musketeer
    Mudkips Highly Respected Retired Administrator

    How to add random wait times properly:

    In C++[Win32]:
    Code:
    #include <windows.h>
    #include <stdlib.h>
    void RandWait(DWORD nMinSleepTime, DWORD nMaxSleepTime)
    {
        srand(GetTickCount());
        Sleep((rand()%nMaxSleepTime-nMinSleepTime)+nMinSleepTime);
    }
    VB6:
    Code:
    Private Declare Function GetTickCount Lib "kernel32" () As Long
    Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliSeconds As Long)
    
    Private Sub RandWait(Min As Long, Max As Long)
    Randomize GetTickCount
    Sleep Int(Rnd * (Max - Min)) + Min
    End Sub
    C#:
    Code:
    	[DllImport("kernel32.dll")]
    		public static extern void Sleep(int dwMilliSeconds);
    		static void RandWait(int min, int max)
    		{
    			Random RandomClass = new Random();
    			int RandomNumber = RandomClass.Next();
    			Sleep((RandomNumber%(max-min))+min);
    		}
    This is virtually the same thing I used for my autoclicker.
     
  3. Unread #2 - Nov 30, 2008 at 11:50 PM
  4. Nerdsta Son
    Joined:
    May 20, 2008
    Posts:
    293
    Referrals:
    1
    Sythe Gold:
    0

    Nerdsta Son Forum Addict
    Banned

    How to add random wait times properly:

    Oo sweet thanks
     
< Autofighter NX | Script Idea! >

Users viewing this thread
1 guest


 
 
Adblock breaks this site