Page 2 of 3 FirstFirst 123 LastLast
Results 26 to 50 of 74

Thread: Are MMDots and Flag broken? (Keep talk about it in this thread!)

  1. #26
    Join Date
    Oct 2007
    Location
    #srl
    Posts
    6,102
    Mentioned
    39 Post(s)
    Quoted
    62 Post(s)

    Default

    Confirmed this working with npc:
    Simba Code:
    {*******************************************************************************
    function GetMiniMapDotsIn(WhatDot: String; x1, y1, x2, y2: Integer): TPointArray;
    By: euphemism, mormonman
    Description: Results the dots specified by WhatDot in the box x1, y1, x2, y2.
    Usage : 'npc', 'yellow', 'n', 'y' : Yellow Dot;
            'cape', 'blue', 'team', 't', 'b' : Blue Dot;
            'item', 'red', 'i', 'r' : Red Dot;
            'player', 'white', 'p', 'w' : White Dot;
            'friend', 'green', 'f', 'g' : Green Dot;
    *******************************************************************************}

    function GetMiniMapDotsIn(WhatDot: String; x1, y1, x2, y2: Integer): TPointArray;
    var
      I, Dif, Radius, Hi, C: Integer;
      TPA: TPointArray;
    begin
      case LowerCase(WhatDot) of
        'npc', 'n', 'yellow', 'y': Dif := 4369;
        'item', 'i', 'red', 'r': Dif := 23;
        'player', 'p', 'white', 'w': Dif := 1907997;
        'friend', 'f', 'green', 'g': Dif := 5376;
        {'team', 't', 'blue', 'b', 'cape': Dif := -1;
        'clan', 'c', 'orange', 'o': Dif := -1;}

      else
        srl_Warn('GetMiniMapDotsIn', '"' + WhatDot + '" is not a valid dot type', warn_AllVersions);
      end;
      Freeze;
      Radius := Max((x2-x1)/2, (y2-y1)/2);
      FindColorsPie(TPA, 65536, 0, 0, 360, 0, radius, x1, y1, x2, y2, (x1+x2)/2, (y1+y2)/2);
      Hi := High(TPA);
      SetLength(Result, Hi + 1);
      if (Hi < 0) then Exit;
      C := 0;
      for I := 0 to Hi do
      begin
        if (GetColor(TPA[I].X-1, TPA[I].Y-1) - GetColor(TPA[I].X, TPA[I].Y-1) = Dif) then
        begin
          Result[C] := Point(TPA[I].x, TPA[i].y - 2);
          Inc(C);
        end;
      end;
      Unfreeze;
      SetLength(Result, C);
    end;
    If someone can confirm the rest I'll commit.

  2. #27
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    Look at my post, I added an image. Get the color at both pixels surrounded by a green box. Subtract one on right from one on the left.
    Oh, haha. Literally the difference of the two numbers.

    E: Here it is with team dots working:
    Simba Code:
    function GetMiniMapDotsIn(WhatDot: String; x1, y1, x2, y2: Integer): TPointArray;
    var
      I, Dif, Radius, Hi, C: Integer;
      TPA: TPointArray;
    begin
      case LowerCase(WhatDot) of
        'npc', 'n', 'yellow', 'y': Dif := 4369;
        'item', 'i', 'red', 'r': Dif := 23;
        'player', 'p', 'white', 'w': Dif := 1907997;
        'friend', 'f', 'green', 'g': Dif := 5376;
        'team', 't', 'blue', 'b', 'cape': Dif := 2171941;
        {'clan', 'c', 'orange', 'o': Dif := -1;}
      else
        srl_Warn('GetMiniMapDotsIn', '"' + WhatDot + '" is not a valid dot type', warn_AllVersions);
      end;
      Freeze;
      Radius := Max((x2-x1)/2, (y2-y1)/2);
      FindColorsPie(TPA, 65536, 0, 0, 360, 0, radius, x1, y1, x2, y2, (x1+x2)/2, (y1+y2)/2);
      Hi := High(TPA);
      SetLength(Result, Hi + 1);
      if (Hi < 0) then Exit;
      C := 0;
      for I := 0 to Hi do
      begin
        if (GetColor(TPA[I].X-1, TPA[I].Y-1) - GetColor(TPA[I].X, TPA[I].Y-1) = Dif) then
        begin
          Result[C] := Point(TPA[I].x, TPA[i].y - 2);
          Inc(C);
        end;
      end;
      Unfreeze;
      SetLength(Result, C);
    end;

    E: Committed this for now since it works, and clan is probably never used, but can easily be added.
    Last edited by Coh3n; 12-07-2011 at 07:13 AM.

  3. #28
    Join Date
    Feb 2006
    Location
    Tracy/Davis, California
    Posts
    12,631
    Mentioned
    135 Post(s)
    Quoted
    418 Post(s)

    Default

    Pink... really?
    Saw it twice when I logged in at two different times today.
    Those are pinkish right...?


  4. #29
    Join Date
    Aug 2007
    Location
    Hawaii
    Posts
    3,880
    Mentioned
    7 Post(s)
    Quoted
    152 Post(s)

    Default

    Quote Originally Posted by YoHoJo View Post
    Pink... really?
    Saw it twice when I logged in at two different times today.
    Those are pinkish right...?

    They are pimps . Interestingly you really have to look close to notice they are pink.
    Faith is an oasis in the heart which will never be reached by the caravan of thinking.

  5. #30
    Join Date
    Feb 2006
    Location
    Tracy/Davis, California
    Posts
    12,631
    Mentioned
    135 Post(s)
    Quoted
    418 Post(s)

    Default

    They stood out to me instantly, wtfaa!
    I've logged in/out many times today doing things, but only twice did they appear pink.

  6. #31
    Join Date
    Jun 2008
    Location
    United States
    Posts
    818
    Mentioned
    60 Post(s)
    Quoted
    90 Post(s)

    Default

    Yes, no close look required. Those are very, very pink. The question is, will the legitimate player-base stand for these ridiculous color changes?
    [10/14/13:19:03] <BenLand100> this is special relatively, just cleverly disguised with yachts

  7. #32
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

    Default

    Quote Originally Posted by euphemism View Post
    Yes, no close look required. Those are very, very pink. The question is, will the legitimate player-base stand for these ridiculous color changes?
    I doubt it. It looks ridiculous.

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

    Default

    Edit2: Flag only changes when you reload client.
    I suggest we add a FlagColor variable? Once found for the first time it'll then make it faster to search for the correct color than to search for a color difference...

    RSColors.FlagColor, RSColors.PlayerDotColor, RSColors.NPCDotColor, etc..

    ... And then we could have our functions search for colors as we usually do, going through a FindColorThroughDifference function if Colour = 0

    ~RM

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

  9. #34
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

    Default

    Flag is working fine for me, and I've reloaded the client several times.

  10. #35
    Join Date
    Feb 2006
    Posts
    3,044
    Mentioned
    4 Post(s)
    Quoted
    21 Post(s)

    Default

    Simba Code:
    function FindFlagEx(var X, Y: Integer): Boolean;
    var
      AX, AY, XX, YY, W, H, Map : Integer;
      MapColors :T2DIntegerArray;
    begin
      AX:= MMX2 - MMX1;
      AY:= MMY2 - MMY1;
      Map := BitmapFromString(MMX2 - MMX1, MMY2 - MMY1, '');
      CopyClientToBitmap(Map, MMX1, MMY1, MMX2, MMY2);
      SetTargetBitmap(Map);
      GetBitmapSize(Map, W, H);
      MapColors := GetBitmapAreaColors(Map, 0, 0, W - 1, H - 1);
      for XX := 0 to AX do
        for YY := 0 to AY do
          If MapColors[XX][YY] = 65536 then
             If MapColors[XX - 1][YY - 1] - MapColors[XX][YY - 1] = 6381921 then
             begin
               Result := True;
               X := XX + MMX1;
               Y := YY + MMY1;
             end;
      FreeTarget(Map);
      FreeBitmap(Map);
    end;

    Takes 52 MS. To find.
    Might be little bit slower, but should be more accurate.


    ~Home

  11. #36
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Almost twice as fast.
    Simba Code:
    function FindFlagEx(var X, Y: Integer): Boolean;
    var
      i, Hi, W, H, MapB,
      KMTarget, ITarget : Integer;
      TPA: TPointArray;
    begin
      MapB := BitmapFromString(MMX2 - MMX1, MMY2 - MMY1, '');
      CopyClientToBitmap(MapB, MMX1, MMY1, MMX2, MMY2);
      KMTarget := GetKeyMouseTarget;
      ITarget := GetImageTarget;
      SetTargetBitmap(MapB);
      GetBitmapSize(MapB, W, H);
      if FindColors(TPA, 65536, 0, 0, W - 1, H - 1) then
      begin
        Hi := High(TPA);
        for i := 0 to Hi do
          if ((FastGetPixel(MapB, TPA[i].x - 1, TPA[i].y - 1)
                - FastGetPixel(MapB, TPA[i].x, TPA[i].y - 1)) = 6381921) then
          begin
           Result := True;
           X := TPA[i].x + MMX1;
           Y := TPA[i].y + MMY1;
           Break;
          end;
      end;
      FreeTarget(GetImageTarget);
      FreeBitmap(MapB);
      SetKeyMouseTarget(KMTarget);
      SetImageTarget(ITarget);
    end;

  12. #37
    Join Date
    Feb 2006
    Posts
    3,044
    Mentioned
    4 Post(s)
    Quoted
    21 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    Almost twice as fast.
    Simba Code:
    function FindFlagEx(var X, Y: Integer): Boolean;
    var
      i, Hi, W, H, MapB,
      KMTarget, ITarget : Integer;
      TPA: TPointArray;
    begin
      MapB := BitmapFromString(MMX2 - MMX1, MMY2 - MMY1, '');
      CopyClientToBitmap(MapB, MMX1, MMY1, MMX2, MMY2);
      KMTarget := GetKeyMouseTarget;
      ITarget := GetImageTarget;
      SetTargetBitmap(MapB);
      GetBitmapSize(MapB, W, H);
      if FindColors(TPA, 65536, 0, 0, W - 1, H - 1) then
      begin
        Hi := High(TPA);
        for i := 0 to Hi do
          if ((FastGetPixel(MapB, TPA[i].x - 1, TPA[i].y - 1)
                - FastGetPixel(MapB, TPA[i].x, TPA[i].y - 1)) = 6381921) then
          begin
           Result := True;
           X := TPA[i].x + MMX1;
           Y := TPA[i].y + MMY1;
           Break;
          end;
      end;
      FreeTarget(GetImageTarget);
      FreeBitmap(MapB);
      SetKeyMouseTarget(KMTarget);
      SetImageTarget(ITarget);
    end;
    Yes true.

    ~Home

  13. #38
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    Almost twice as fast.
    Simba Code:
    function FindFlagEx(var X, Y: Integer): Boolean;
    var
      i, Hi, W, H, MapB,
      KMTarget, ITarget : Integer;
      TPA: TPointArray;
    begin
      MapB := BitmapFromString(MMX2 - MMX1, MMY2 - MMY1, '');
      CopyClientToBitmap(MapB, MMX1, MMY1, MMX2, MMY2);
      KMTarget := GetKeyMouseTarget;
      ITarget := GetImageTarget;
      SetTargetBitmap(MapB);
      GetBitmapSize(MapB, W, H);
      if FindColors(TPA, 65536, 0, 0, W - 1, H - 1) then
      begin
        Hi := High(TPA);
        for i := 0 to Hi do
          if ((FastGetPixel(MapB, TPA[i].x - 1, TPA[i].y - 1)
                - FastGetPixel(MapB, TPA[i].x, TPA[i].y - 1)) = 6381921) then
          begin
           Result := True;
           X := TPA[i].x + MMX1;
           Y := TPA[i].y + MMY1;
           Break;
          end;
      end;
      FreeTarget(GetImageTarget);
      FreeBitmap(MapB);
      SetKeyMouseTarget(KMTarget);
      SetImageTarget(ITarget);
    end;
    There's also BitmapFromClient, I think. This doesn't look bad and is what I had in mind. You could still use Freeze I suppose, but that would load the entire client (in the backend anyway), rather than only a part. So if you're going for speed this is nice. Good work both of you. Now we just need to know it this works well enough.

    E: http://docs.villavu.com/simba/script...tmapfromclient
    Last edited by Wizzup?; 12-08-2011 at 10:11 PM.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  14. #39
    Join Date
    Nov 2006
    Posts
    2,369
    Mentioned
    4 Post(s)
    Quoted
    78 Post(s)

    Default

    Wow mormonman that looks great! I learned something very usefull from your code. I will probably be using your method to write FindColoredAreaTolerance

    Also is FastGetPixel faster than GetColor?
    Quote Originally Posted by DeSnob View Post
    ETA's don't exist in SRL like they did in other communities. Want a faster update? Help out with updating, otherwise just gotta wait it out.

  15. #40
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    It worked very well during my tests.

    Simba Code:
    function FindFlagEx2(var X, Y: Integer): Boolean;
    var
      i, Hi, W, H, MapB,
      KMTarget, ITarget : Integer;
      TPA: TPointArray;
    begin
      MapB := BitmapFromClient(MMX1, MMY1, MMX2, MMY2);
      KMTarget := GetKeyMouseTarget;
      ITarget := GetImageTarget;
      SetTargetBitmap(MapB);
      GetBitmapSize(MapB, W, H);
      if FindColors(TPA, 65536, 0, 0, W - 1, H - 1) then
      begin
        Hi := High(TPA);
        for i := 0 to Hi do
          if ((FastGetPixel(MapB, TPA[i].x - 1, TPA[i].y - 1)
                - FastGetPixel(MapB, TPA[i].x, TPA[i].y - 1)) = 6381921) then
          begin
           Result := True;
           X := TPA[i].x + MMX1;
           Y := TPA[i].y + MMY1;
           Break;
          end;
      end;
      FreeTarget(GetImageTarget);
      FreeBitmap(MapB);
      SetKeyMouseTarget(KMTarget);
      SetImageTarget(ITarget);
    end;

    Edit: New dots function too(its 1 ms faster :0 )
    Simba Code:
    function GetMiniMapDotsIn(WhatDot: String; x1, y1, x2, y2: Integer): TPointArray;
    var
      MapB, KMTarget, ITarget, W, H,
      I, Dif, Radius, Hi, C: Integer;
      TPA: TPointArray;
    begin
      case LowerCase(WhatDot) of
        'npc', 'n', 'yellow', 'y': Dif := 4369;
        'item', 'i', 'red', 'r': Dif := 23;
        'player', 'p', 'white', 'w': Dif := 1907997;
        'friend', 'f', 'green', 'g': Dif := 5376;
        'team', 't', 'blue', 'b', 'cape': Dif := 2171941;
        {'clan', 'c', 'orange', 'o': Dif := -1;}
      else
        srl_Warn('GetMiniMapDotsIn', '"' + WhatDot + '" is not a valid dot type', warn_AllVersions);
      end;
      MapB := BitmapFromClient(x1, y1, x2, y2);
      KMTarget := GetKeyMouseTarget;
      ITarget := GetImageTarget;
      SetTargetBitmap(MapB);
      GetBitmapSize(MapB, W, H);
      C := 0;
      if FindColors(TPA, 65536, 0, 0, W - 1, H - 1) then
      begin
        Hi := High(TPA);
        SetLength(Result, Hi + 1);
        for I := 0 to Hi do
        begin
          if ((FastGetPixel(MapB, TPA[i].x - 1, TPA[i].y - 1)
                - FastGetPixel(MapB, TPA[i].x, TPA[i].y - 1)) = Dif) then
          begin
            Result[C] := Point(TPA[I].x + x1, TPA[i].y + y1 - 2);
            Inc(C);
          end;
        end;
      end;
      FreeTarget(GetImageTarget);
      FreeBitmap(MapB);
      SetKeyMouseTarget(KMTarget);
      SetImageTarget(ITarget);
      SetLength(Result, C);
    end;
    Last edited by mormonman; 12-08-2011 at 10:43 PM.

  16. #41
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Quote Originally Posted by weequ View Post
    Wow mormonman that looks great! I learned something very usefull from your code. I will probably be using your method to write FindColoredAreaTolerance

    Also is FastGetPixel faster than GetColor?
    I used fastgetpixel because its a bitmap.

    Edit: Oops on the double post

  17. #42
    Join Date
    Sep 2007
    Location
    Michigan
    Posts
    3,862
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Have to agree, your FindFlag working the best for me as well.
    (Scripts outdated until I update for new SRL changes)
    AK Smelter & Crafter [SRL-Stats] - Fast Fighter [TUT] [SRL-Stats]
    If you PM me with a stupid question or one listed in FAQ I will NOT respond. -Narcle
    Summer = me busy, won't be around much.

  18. #43
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    I used fastgetpixel because its a bitmap.

    Edit: Oops on the double post
    I think GetColor should work on the bitmap as well, with the same speed.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  19. #44
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Quote Originally Posted by Wizzup? View Post
    I think GetColor should work on the bitmap as well, with the same speed.
    Run this

    Simba Code:
    program Default;
    {$DEFINE SMART}
    {$i srl\srl.scar}

    const
    {---SMART Setup Constants---}
      WORLD = 35;
      MEMBERS = false;
      SIGNED = true;
      SUPERDETAIL = false;
    {---------------------------}

    var
      bmp: integer;

    begin
      Smart_Members := MEMBERS;
      Smart_Server := WORLD;
      Smart_Signed := SIGNED;

      SetupSRL;

      Bmp := BitmapFromString(100, 65, 'meJzt2lsKgzAQBdCNtH92/xtT1' +
            '1CKYNtEYyKKjxw4H8FSSC8zYyw2j64BALib9ugNXNLr+TGuD98P96' +
            'VDE/qjN3BmC5VjcK2Orgb/N7h0IG3wlarEvzq6opyKohBXKNFZUx8' +
            'NAbo5si2NyYbamTUk5JSN0hp9jwEZJ/nKxeHkXKlW0QlTbp25tH+q' +
            '1RJCkWB2zTWmVCf9xtJHCxJxpS/CsqV/2pXWutwIhCNdgBl0X5ahl' +
            'rxIs5bj1mImImJfppas4EK0IZyDR0X5bMZgL+TxEAAAgDJvqvncXA==');
      SetTargetBitmap(bmp);
      writeln(GetColor(1,1));
      writeln(fastgetpixel(bmp,1,1));
    end.

  20. #45
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

    Default

    mormonman, I've added your versions of FindFlag and GetMiniMapDots in to my repos. I'm running a test run over night to make sure it all works without runtime errors, and I'll commit them, along with several other bug fixes tomorrow.

    E: FindFlag seems to be working, but GetMiniMapDotsIn returns 0 points, no matter which kind of dot I try.

    E2: FindFlag seems to work when I test like writeln(booltoStr(flagPresent)));, but when I use it in a loop, like this, it ALWAYS returns true, even when the player has stopped walking.
    Simba Code:
    mouse(577, 131, 3, 3, true);
      while (flagPresent) do
        wait(50);
    Could be something stupid I'm overlooking, it's late. >.<

    E: Seems like it always returns true after it's found it once.
    Last edited by Coh3n; 12-09-2011 at 05:53 AM.

  21. #46
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    Run this

    Simba Code:
    program Default;
    {$DEFINE SMART}
    {$i srl\srl.scar}

    const
    {---SMART Setup Constants---}
      WORLD = 35;
      MEMBERS = false;
      SIGNED = true;
      SUPERDETAIL = false;
    {---------------------------}

    var
      bmp: integer;

    begin
      Smart_Members := MEMBERS;
      Smart_Server := WORLD;
      Smart_Signed := SIGNED;

      SetupSRL;

      Bmp := BitmapFromString(100, 65, 'meJzt2lsKgzAQBdCNtH92/xtT1' +
            '1CKYNtEYyKKjxw4H8FSSC8zYyw2j64BALib9ugNXNLr+TGuD98P96' +
            'VDE/qjN3BmC5VjcK2Orgb/N7h0IG3wlarEvzq6opyKohBXKNFZUx8' +
            'NAbo5si2NyYbamTUk5JSN0hp9jwEZJ/nKxeHkXKlW0QlTbp25tH+q' +
            '1RJCkWB2zTWmVCf9xtJHCxJxpS/CsqV/2pXWutwIhCNdgBl0X5ahl' +
            'rxIs5bj1mImImJfppas4EK0IZyDR0X5bMZgL+TxEAAAgDJvqvncXA==');
      SetTargetBitmap(bmp);
      writeln(GetColor(1,1));
      writeln(fastgetpixel(bmp,1,1));
    end.
    Ah. That's because SMART is overriding the Simba GetColor method. Nothing we can do about that, until SMART adds support for EIOS.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  22. #47
    Join Date
    Sep 2007
    Location
    Michigan
    Posts
    3,862
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by Coh3n View Post
    mormonman, I've added your versions of FindFlag and GetMiniMapDots in to my repos. I'm running a test run over night to make sure it all works without runtime errors, and I'll commit them, along with several other bug fixes tomorrow.

    E: FindFlag seems to be working, but GetMiniMapDotsIn returns 0 points, no matter which kind of dot I try.

    E2: FindFlag seems to work when I test like writeln(booltoStr(flagPresent)));, but when I use it in a loop, like this, it ALWAYS returns true, even when the player has stopped walking.
    Simba Code:
    mouse(577, 131, 3, 3, true);
      while (flagPresent) do
        wait(50);
    Could be something stupid I'm overlooking, it's late. >.<

    E: Seems like it always returns true after it's found it once.
    Yeah what seems to work best for me is FFlag(10) to 20 with mormonman's FindFlag, but it still seems off sometimes.

    What it looks like so far is the color doesn't change unless you reload the client. I'm going to try a different approach by getting a temporary flag color and use that for FindFlag afterwards.
    (Scripts outdated until I update for new SRL changes)
    AK Smelter & Crafter [SRL-Stats] - Fast Fighter [TUT] [SRL-Stats]
    If you PM me with a stupid question or one listed in FAQ I will NOT respond. -Narcle
    Summer = me busy, won't be around much.

  23. #48
    Join Date
    Mar 2006
    Location
    Behind you
    Posts
    3,194
    Mentioned
    61 Post(s)
    Quoted
    63 Post(s)

    Default

    Doesn't one point on the flag never change color? If so you could get all the colors Around that spot in a box. Then get rid of all the color that have a duplicate. By get rid of I mean remove completely not clear duplicates that still leaves one of the color in the Array. After that you can take all the Remaining colors and do a count color tolerance for the Correct amount of colors. Then make the Colors of the Flag dynamic.

    That's the general Idea Anyway. Hope I explained it properly.

    "Sometimes User's don't need the Answer spelled out with Code. Sometimes all they need is guidance and explanation of the logic to get where they are going."

  24. #49
    Join Date
    Sep 2007
    Location
    Michigan
    Posts
    3,862
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by BraK View Post
    Doesn't one point on the flag never change color? If so you could get all the colors Around that spot in a box. Then get rid of all the color that have a duplicate. By get rid of I mean remove completely not clear duplicates that still leaves one of the color in the Array. After that you can take all the Remaining colors and do a count color tolerance for the Correct amount of colors. Then make the Colors of the Flag dynamic.

    That's the general Idea Anyway. Hope I explained it properly.
    Ahh, yes good idea. I will try this.
    (Scripts outdated until I update for new SRL changes)
    AK Smelter & Crafter [SRL-Stats] - Fast Fighter [TUT] [SRL-Stats]
    If you PM me with a stupid question or one listed in FAQ I will NOT respond. -Narcle
    Summer = me busy, won't be around much.

  25. #50
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    6,136
    Mentioned
    28 Post(s)
    Quoted
    17 Post(s)

    Default

    Or, you could grab the color of the flag once, and keep it in memory while we are still in the same session. I believe the flag color is stable for the session as long as you stay logged in, no?
    That would keep things simple. You might do a click on MMcentre once to grab the Flag color at script startup, and from that monent on do a simple findcolor like we used to do.
    SRL is a Library of routines made by the SRL community written for the Program Simba.
    We produce Scripts for the game Runescape.

Page 2 of 3 FirstFirst 123 LastLast

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
  •