Results 1 to 9 of 9

Thread: GrandExchange.scar [Small thing]

  1. #1
    Join Date
    Mar 2007
    Location
    <3
    Posts
    2,683
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default GrandExchange.scar [Small thing]

    GEGetMidPrice..

    SCAR Code:
    {*******************************************************************************
    Function GEGetMidPrice(ID: Integer): Integer;
    By: N1ke!
    Description: Gets the price from [url]www.runescape.com[/url].
    ID can be obtained by looking at runescapes grand exchange database link for
    the specific item.
    *******************************************************************************}

    Function GEGetMidPrice(ID: Integer): Integer;
    var
      Price: String;
      I: Integer;
      words: array of string;
    begin
      Price := Between('Market price:</b> ', '<', Getpage('http://itemdb-rs.runescape.com/viewitem.ws?obj=' + IntToStr(ID)));
      Words := [#13, #10, ',', ' '];
      For I := 0 To high(words) do
        Price := Replace(Price, words[I], '');
      Result := StrToInt(Price);
    end;

  2. #2
    Join Date
    May 2007
    Location
    Sydney, Australia (Faggot Region)
    Posts
    1,465
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Good for scripts to check how much items are


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

    Default

    no functions connecting to a website in SRL, if i remember correctly what wizzup said.

    ~RM

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

  4. #4
    Join Date
    Dec 2006
    Location
    Sweden
    Posts
    10,812
    Mentioned
    3 Post(s)
    Quoted
    16 Post(s)

    Default

    I think the guidelines say that as long as the website is approved, and doesn't send any personal data, it is allowed..


    Send SMS messages using Simba
    Please do not send me a PM asking for help; I will not be able to help you! Post in a relevant thread or make your own! And always remember to search first!

  5. #5
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    No it is not, I made one called GetBestRSWorld, it got the lowest world. If I remember it got denied on the grounds that anything that accessed the runescape website.

    A little add-on just in case:

    SCAR Code:
    {*******************************************************************************
    Function GEGetMidPrice(ID: Integer): Integer;
    By: N1ke!
    Description: Gets the price from [url]www.runescape.com[/url].
    ID can be obtained by looking at runescapes grand exchange database link for
    the specific item. Returns -1 if failed.
    *******************************************************************************}

    Function GEGetMidPrice(ID: Integer): Integer;
    var
      Price: String;
      I: Integer;
      words: array of string;
    begin
      Price := Between('Market price:</b> ', '<', Getpage('http://itemdb-rs.runescape.com/viewitem.ws?obj=' + IntToStr(ID)));
      Words := [#13, #10, ',', ' '];
      For I := 0 To high(words) do
        Price := Replace(Price, words[i], '');
      Result := StrToIntDef(Price, -1);
    end;

    Good man, your really turning out some stuff.

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

    Default

    Quote Originally Posted by Harry View Post
    I think the guidelines say that as long as the website is approved, and doesn't send any personal data, it is allowed..
    That's for scripts, not SRL.

    Nauman: there's now a function for that which doesn't need to connect to the website Check out /Core/WorldSwitcher.scar

    ~RM

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

  7. #7
    Join Date
    Jul 2008
    Location
    Poland
    Posts
    375
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    I made function which was connecting to the rs highscores and downloading all player stats, this function could be useful on pvp worlds to download oponents stats(attack, str, defc)....
    :P

  8. #8
    Join Date
    Dec 2008
    Posts
    2,813
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Iroki View Post
    I made function which was connecting to the rs highscores and downloading all player stats, this function could be useful on pvp worlds to download oponents stats(attack, str, defc)....
    That can be done with reflection, I thought?

  9. #9
    Join Date
    Mar 2007
    Location
    <3
    Posts
    2,683
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    My bad, didn't know.

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
  •