Adblock breaks this site

need help with scar

Discussion in 'Scar/Simba Help' started by madd-x, Apr 25, 2010.

  1. madd-x

    madd-x Newcomer

    Joined:
    Apr 25, 2010
    Posts:
    3
    Referrals:
    0
    Sythe Gold:
    0
    need help with scar

    so i need to know what code i need to use,

    if i want the mouse click on a certain coordinate
    when a certain colour in a certain coordinate changes.

    example

    coordinate 0,0 changes colour
    so the mouse will click on coordinate 1,1

    ty if any1 could help
     
  2. beesafree

    beesafree Newcomer

    Joined:
    Apr 24, 2010
    Posts:
    5
    Referrals:
    0
    Sythe Gold:
    0
    need help with scar

    i would do something like:

    Code:
    program New;
    
    var
    x, y, x1, y1: integer;
    complete: boolean;
    
    begin
      complete:= false
      if findcolor(x,y,INSERTCOLORHERE,0,0,8000,8000) = true then
      begin
        repeat
          if findcolor(x1,y1,INSERTCOLORHERE,x,y,x,y) = false then
          begin
            complete:= true
            movemousesmooth(x1,y1)
            clickmouse(x1+1,y1+1,true)
          end;
        until (complete = true);
      end;
    end.
    replace INSERTCOLORHERE, with the starting color
    then the program will search the entire screen for the first instance of that color, and it will focus on that exact pixel until it changes colors, at that point it will click 1 pixel lower, and 1 pixel right to it, it will then end
     
  3. madd-x

    madd-x Newcomer

    Joined:
    Apr 25, 2010
    Posts:
    3
    Referrals:
    0
    Sythe Gold:
    0
    need help with scar

    ty so much
     
  4. Lugii

    Lugii Active Member
    Banned

    Joined:
    Feb 2, 2010
    Posts:
    191
    Referrals:
    0
    Sythe Gold:
    0
    need help with scar

    yeh exactly
     
  5. madd-x

    madd-x Newcomer

    Joined:
    Apr 25, 2010
    Posts:
    3
    Referrals:
    0
    Sythe Gold:
    0
    need help with scar

    Code:
    program New;
    
    var
    x, y, x1, y1: integer;
    complete: boolean;
    
    begin
      complete:= false
      if findcolor(x,y,INSERTCOLORHERE,0,0,8000,8000) = true then
      begin
        repeat
          if findcolor(x1,y1,INSERTCOLORHERE,x,y,x,y) = false then
          begin
            complete:= true
            movemousesmooth(x1,y1)
            clickmouse(x1+1,y1+1,true)
          end;
        until (complete = true);
      end;
    end.
    nice code, but what code would i change to scan one specific coordinate than scanning the whole area
     
  6. beesafree

    beesafree Newcomer

    Joined:
    Apr 24, 2010
    Posts:
    5
    Referrals:
    0
    Sythe Gold:
    0
    need help with scar

    at the beginning?

    it would be these coordinates: (in bold)

    if findcolor(x,y,INSERTCOLORHERE,0,0,8000,8000) = true then

    where the 0,0 is the upper left starting corner, and 8000,8000 is the lower right corner, i just put 8000, 8000 cause that will cover almost ALL screens (unless you have a ridiculous screen size)
     
< Commands On Stop | Ultimate SCAR Scripting Tutorial >


 
 
Adblock breaks this site