Results 1 to 13 of 13

Thread: Making image finder script!

  1. #1
    Join Date
    Jun 2008
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Making image finder script!

    Hi. I am quite new to this stuff but I want to request a script. So I want to tell you the idea of it. You see on one site there is a competition, they post a picture which is zoomed in and it's only a small part of the real picture. So we need to find the pictures somewhere on the site.  All images on site is viewable by users. But it's quit difficult because it's zoomed.

    The script probably could find the image on site by checking all images and comparing them whit the given one and show matching image/s. Can someone make this? P.S.

  2. #2
    Join Date
    Aug 2007
    Location
    Georgia, U.S.
    Posts
    890
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    just use:

    SCAR Code:
    program New;
    {.include SRL/SRL.scar}

    var
     OurBMP, x, y: integer;

    begin
      SetupSRL;
      OurBMP := BitmapFromString(1, 1, ''); //you have to paste the real code here
      if FindBitmap(OurBMP, x, y) then //looks for the bmp
      MMouse(x, y, 0, 0); //Moves the mouse to the pic
    end.

  3. #3
    Join Date
    Jun 2008
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Oh, oh. Is there some tutorial to do this?

  4. #4
    Join Date
    Aug 2007
    Location
    Georgia, U.S.
    Posts
    890
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    you have to load the bitmap from a file.

    read this tut:
    http://www.villavu.com/forum/showthread.php?t=1609

  5. #5
    Join Date
    Jun 2008
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thank you, is the script right which I sent you?

  6. #6
    Join Date
    Aug 2007
    Location
    Georgia, U.S.
    Posts
    890
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    yeah, that should work.

  7. #7
    Join Date
    Jun 2008
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Now I need to do what? Only click run script?

    When I do it it shows error:

    Failed when compiling
    Line 1: [Error] (1:1): Unable to register function function FindGapsTPA(TPA : TPointArray; MinPixels: Integer): T2DPointArray; in script D:\Program Files\SCAR 3.12\Scripts\Test\imagetest.scar

  8. #8
    Join Date
    Mar 2008
    Posts
    1,492
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Get Scar3.15 or 3.15b install subversion and redownload SRL #17...

  9. #9
    Join Date
    Sep 2006
    Posts
    6,089
    Mentioned
    77 Post(s)
    Quoted
    43 Post(s)

    Default

    Remove the {.include SRL/SRL.scar} at the top and remove SetupSRL from the mainloop, replace MMouse(x, y, 0, 0) with MoveMouse(x, y) and it should compile.
    Hup Holland Hup!

  10. #10
    Join Date
    Jun 2008
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Everything is fixed.

  11. #11
    Join Date
    Apr 2007
    Posts
    994
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    It has'nt found the bitmap. You probably need to
    SCAR Code:
    repeat
      if findbitmap(...) then
      begin
        movemouse(x,y);
        break;
      end;
    until(isfkeydown(11));
    That will repeat finding the bitmap until F11 is pressed. I still don't think the whoel thing will work though, because You say the bitmap will be resized?
    [QUOTE]<GoF`> oh no its Raymooond
    <Raymooond> Heya
    <GoF`> is it ray or some other ray?
    <LeeLokHin> No idea
    <LeeLokHin> Raymond, what's the game you like the most?
    <Raymooond> Runescape
    <-- LeeLokHin has kicked Raymooond from #srl (Faker.)[/QUOTE]

  12. #12
    Join Date
    Jun 2008
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Lee Lok Hin View Post
    It has'nt found the bitmap. You probably need to
    SCAR Code:
    repeat
      if findbitmap(...) then
      begin
        movemouse(x,y);
        break;
      end;
    until(isfkeydown(11));
    That will repeat finding the bitmap until F11 is pressed. I still don't think the whoel thing will work though, because You say the bitmap will be resized?
    Someone told me this:

    alternativly in SCAR you could have every single image that the mystery pic could possibly be saved to an external harddrive or whatnot, and have it scan and compare to those images that might theoretically take less time, but im not sure

  13. #13
    Join Date
    Jun 2013
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    i want the tutoria if there is

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 14
    Last Post: 06-07-2013, 02:46 AM
  2. Creating a pick head finder, and gas finder
    By Tom_Gower in forum OSR Help
    Replies: 7
    Last Post: 11-07-2008, 07:06 AM
  3. Dynamic script stats image fails:s
    By PvH in forum Web Development
    Replies: 5
    Last Post: 07-12-2008, 04:17 PM
  4. Bank Symbol Finder & Clicker Script!
    By RiSe AgAiNsT in forum RS3 Outdated / Broken Scripts
    Replies: 13
    Last Post: 11-12-2007, 06:16 PM

Posting Permissions

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