Results 1 to 3 of 3

Thread: A small note to all scripters..

  1. #1
    Join Date
    Jul 2007
    Location
    Right now? Chair.
    Posts
    8,488
    Mentioned
    3 Post(s)
    Quoted
    12 Post(s)

    Default A small note to all scripters..

    I'm posting this just because I've seen this mistake ever since the stone age of SRL.

    The only times you need to use randomness is when you interact with RS.

    Things like these are pointless and harmfull:
    Simba Code:
    T := GetSystemTime + 2000 + Random(200); //baaaaad
      while (GetSystemTime < T) do
      begin
        if (FlagPresent) or (IsMoving) then
          Break;
        Wait(20);
      end;

    Why pointless? - Because NOBODY is monitoring this
    Why Harmful? - Because it is randomizing the rhythm of your script, making it harder to fine tune!

    ~RM

    I & I know Zion. It is in the spirit, body and mind of every one of us
    RMouse(obj: TMSIObject): boolean;

  2. #2
    Join Date
    Jan 2008
    Location
    Ontario, Canada
    Posts
    7,805
    Mentioned
    5 Post(s)
    Quoted
    3 Post(s)

    Default

    I disagree, by doing that you make the waits random, and thus harder to track.

    Placing the random there is silly. Doing wait(10+random(10)); makes more sense.
    Writing an SRL Member Application | [Updated] Pascal Scripting Statements
    My GitHub

    Progress Report:
    13:46 <@BenLand100> <SourceCode> @BenLand100: what you have just said shows you 
                        have serious physchological problems
    13:46 <@BenLand100> HE GETS IT!
    13:46 <@BenLand100> HE FINALLY GETS IT!!!!1

  3. #3
    Join Date
    Jul 2007
    Location
    Right now? Chair.
    Posts
    8,488
    Mentioned
    3 Post(s)
    Quoted
    12 Post(s)

    Default

    No one is tracking it in this particular place... it's internal to the script.

    You're better off just putting the random wait before the next time you interact with RS.
    Also, when you are analysing things that are critical to your script run you don't want useless waits. You want it done as quickly as possible so you can determine what the best action is.

    ~RM

    I & I know Zion. It is in the spirit, body and mind of every one of us
    RMouse(obj: TMSIObject): boolean;

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •