Results 1 to 12 of 12

Thread: My Merchanter

  1. #1
    Join Date
    Dec 2006
    Posts
    78
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default My Merchanter

    Im working on making in auto merchanter, but i am getting this error when i try to compile my script.
    Line 18: [Error] (17996:1): Duplicate identifier 'x' in script C:\Documents and Settings\xxx\Desktop\rs2 programs\Scripts\LooneyScripts\looneymerchanter.sc ar

    SCAR Code:
    program LooneyMerchanter;

    {.Include SRL/SRL.Scar}
    {.include srl\srl\extended\xtext.scar}


    Const
    Message1 = 'Hiyah';
    procedure AutoTalk;
    begin
    sendkeys(Message1);
    SendKeysVb('{ENTER}',false);
    wait(5000+random(2000));
    end;


    var
    x,y,Bitmap:integer;

    procedure DeclareBMPS;
    begin
    Bitmap := BitmapFromString(28, 8, 'z78DAA593310EC03008' +
           '03BF843AD111A4FEFF4B919A858862DC646140600E93B8DB735F4' +
           'E47151195B2C6CCD59A0CCEE34877359C8CDA1EE1899F71223FFD' +
           '84F3ED9D0C3946E598596A0A12AC961DF8A8CF2E4D05181B7EE28' +
           '5F095BF774F9C4B6FCC57E470237E3A76AFD91D72E23B527F8178' +
           'CFD913EA9A997CEBEF44CD0181513B73');
    end;


    procedure ClickBMPS;
    begin
    wait(300+random(32))
    movemousesmooth(x,y)
    wait(32+random(16))
    clickmouse(x,y,true)
    end;


    Procedure FindBMPS;
    begin
     if(FindBitmap(Bitmap,x,y))then
    ClickBMPS;
    if not(FindBitmap (Bitmap,x,y)) then
    autotype;
    end;

    begin
    repeat
    wait(1300)
    DeclareBMPS;
    FindBMPS;
    until(false)
    end.

    I dont see how its a duplicate identifier... it doesnt make sense. Can anyone help me? Im so excited about realeasing this!! also what can i use besides sendkeys cuzz i think thats detectable

    Edit: I found out that when i remove srl, it works, but i need srl to use it. I had my script looking for a bitmap but now im gonna make it look for a color.. ill update, if someone can solve this please help, thanks
    Download Looney/GoFez0r's Merchanter v.1.1
    http://www.fenjer.com/adnan/SRLStats/57.png
    http://www.fenjer.com/adnan/SRL/8/2/...nt%20Alpha.png
    MSN:ghettogeec@hotmail.com
    Procedure CreateCommonItemMerchant;
    if CommonItemMerchant=Working then
    CreateFullMerchant;

    Scar= Me=

  2. #2
    Join Date
    Feb 2006
    Location
    New Zealand
    Posts
    1,330
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    It is because x and y are used inside srl itself. If you remove those from your variable declarations it will stop that error

  3. #3
    Join Date
    Dec 2006
    Posts
    78
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    if i remove srl then the autotyper wont work. is there an autotyper function that works without srl and i dont need to keep pressing f1 to use?

    Edit: ok i think i get ehat you were saying, i took out x,y and it works now. The only problem is it wont stop when i try to make it top, i press Ctrl+Alt+S and it keeps going... why?
    Download Looney/GoFez0r's Merchanter v.1.1
    http://www.fenjer.com/adnan/SRLStats/57.png
    http://www.fenjer.com/adnan/SRL/8/2/...nt%20Alpha.png
    MSN:ghettogeec@hotmail.com
    Procedure CreateCommonItemMerchant;
    if CommonItemMerchant=Working then
    CreateFullMerchant;

    Scar= Me=

  4. #4
    Join Date
    Jul 2006
    Location
    NY
    Posts
    371
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    you probably have more then 1 scar open, if thats the case it wont stop when you use the hot keys.

  5. #5
    Join Date
    Feb 2006
    Location
    Under a rock.
    Posts
    1,351
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    Quote Originally Posted by Junior View Post
    you probably have more then 1 scar open, if thats the case it wont stop when you use the hot keys.
    Or, if you opened to SCAR's, and closed the first one, the second one won't react with hotkeys. Save, close all SCAR's, and try again.
    SRL Developer
    ◘◘◘◘◘◘◘◘◘◘◘◘◘◘◘◘◘◘◘◘

  6. #6
    Join Date
    Sep 2006
    Posts
    63
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Cheesehunk View Post
    Or, if you opened to SCAR's, and closed the first one, the second one won't react with hotkeys. Save, close all SCAR's, and try again.
    Hey I had the same problem, thanks for the suggestion =)

  7. #7
    Join Date
    Dec 2006
    Posts
    78
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ok i need someone to help me with this. im looking for a partner that is good with srl and scar and we can make this together, and it iwll go in both our names, i hope someone out there can help me, im so eager to make scripts!!!
    Download Looney/GoFez0r's Merchanter v.1.1
    http://www.fenjer.com/adnan/SRLStats/57.png
    http://www.fenjer.com/adnan/SRL/8/2/...nt%20Alpha.png
    MSN:ghettogeec@hotmail.com
    Procedure CreateCommonItemMerchant;
    if CommonItemMerchant=Working then
    CreateFullMerchant;

    Scar= Me=

  8. #8
    Join Date
    Oct 2006
    Location
    I'm a figment of your imagination
    Posts
    422
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Just make x a different variable name, like xx and then change that in your procedure that needs "the other x".

    It's been a while... but I'm BACK!!!

  9. #9
    Join Date
    Dec 2006
    Posts
    78
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    OMG! i finally learned some things and got it to compile, but now its not even running right...well its not running at all, its not typing, looking for bitmaps, ANYTHING! Someone please help i would love to release this asap. oh, and thanks to everyone who posted here, it realy helped me out.

    SCAR Code:
    program LooneyMerchanter;

    {.Include SRL/SRL.Scar}
    {.include srl\srl\extended\xtext.scar}


    Const
     Message1 = 'Selling feathers 2ea-loon';



    procedure autotype;
    begin
     TypeSend(Message1);
     wait(1000);
     end;


    var
    xx,yy,accepttrade:integer;
    xc,yc,PublicChatOff:integer;
    xd,yd,PublicFriends:integer;
    xe,ye,PublicOn:integer;
    xf,yf,TradeFriends:integer;
    xg,yg,TradeOff:integer;
    xh,yh,TradeOn:integer;
    xi,yi,TradeOption:integer;


    procedure DeclareBMPS;
    begin
    accepttrade := BitmapFromString(19, 13, 'z78DA33301805A380D' +
           '6C01989A48F5DF845686717ADED1D281BF193C4E8A29D1F9DE91E' +
           'AA83D14600263E17DE');
        PublicChatOff := BitmapFromString(39, 15, 'z78DAB5955D0EC23' +
           '00C83AF84DA0EC1E340F4FE476210109E225BAECAFA60A12E4DFC' +
           'A53FF4FE1AA7F7288FB296169A677A1AF895A95ED5A1BA93D9F1C' +
           '0627A22657EB00338B42BBD0AFDD44B2DE58AD44E36DDBD1C19BF' +
           'A31663D75C8C1433EB18E62166703E0FC7AD2665EC59D18F76EBC' +
           '4300FB8EF79A77CD256EA5ABAC3EEE811A43A729E949D9CEC3C32' +
           '38AB58AD510F9A0B6F716446523683F338720CF23AAB742DC7037' +
           'B0D76156FDBEA85B965FE91E2CF6AFB716E10527F32333D824513' +
           '1D46BAB4B6D67B9CF4D02952D62B3DE3A8E465EFFFFEE6FEE8BEE' +
           'F76E2D5FDD7DE46892678B5C69E0663FCC65D6615E919188C41C5' +
           'EAA8F875863A3322E9EED502FFFA0CB018C692899CC851EA70722' +
           'E5B8E253493B20E605DEC09EB12EBEAA80EDC9AF4DF84A4A13EA9' +
           '3E0F2C26F756CF0FF326D2276B58FE06');
      PublicFriends := BitmapFromString(17, 16, 'z78DAAD93C10E022' +
           '110437FC90CB0E8118DFCFF27B93A979252C20A3D34A63BF42D3B' +
           'B1D6AF6E3F450BC5AA7B15F9D8C33D983DF0ACBDAD586CDA9EE76' +
           'CF2C47F77726AE67C46DC8F94E67622C7C4C5892BC558C2CBBDD3' +
           '36A48F136C665793EA9B2BCA61E7B9C4BE44A14451D0798FCE423' +
           'ACFF8D9790ACEAB3D22F76AF38CAB9DEEA528D67F3DBE4BE54CCC' +
           'F9C8295EF5FE7FAC15B2D62933775FA7F0D3BD147435B3EB2E28F' +
           '5261F8D156289');
      PublicOn := BitmapFromString(17, 20, 'z78DAAD92510EC2300C43' +
           'AF54A5DD069F03C1FD8FC4683ACDC873958AE5C30A69E6D734E45' +
           'B36BBE7AAEF1AA986BD6CB5E215CFB99228B013350B4A9FDBF764' +
           'F5FE6279B5779FA2B8FD9BBB2A4A9C1BD1510AB230D8D91D5AFED' +
           '87E4D4D6B1D29AA82750CEE698A146045946FAE742A65CDCF13D6' +
           '1F74454165FF947C375F1DF0070745F1BC393796876075DF8129E' +
           '8BFE775B3345DE89DABCEB63935658A074F8AA7A31454455177F8' +
           '7DDB638F7E1AA144266567DCE3B2CCCB542294FEA458E1BA53504' +
           '729FD7E4541F51EFE6ACFAFA1204BF95F45D95947E8FFCCF9699C' +
           'A29C23FA01D461B1B6');
      TradeFriends := BitmapFromString(13, 21, 'z78DACD93C10EC320' +
           '0C437F693574DA8E6C6BFFFF9356610E462608ED341F2C64252FB' +
           '46971A020A3FA5975AB620260DB0E7CB06FA59DE9D2A59E1E0978' +
           'D29DC63CAA8F68E430E9EEF6930F9EF10F682BCF789AE635738EC' +
           'E52794DB447DF72B447ADC948055DFD9CE65F88D628537D4EF3AF' +
           '6B4E537729596B1AED7565FB9CE95B505A737294B640D6B7E1B43' +
           'DE792DE03E632994E4E47131FE4CE91DC699A445306F70F7A9768' +
           '8173AF775C7D8DACE7881CE5ECE5C679A6738ABA1334D74AE7E81' +
           '4CA993E4BFF0AA545B7A5BC97FA02A1DF66EB');
      TradeOff := BitmapFromString(32, 11, 'z78DAA593C10E83300C43' +
           '7F09A565DA8E6C1AFFFF4943F561AE4C4C811E7C084EFA9C6EE55' +
           '9225EA5E9DACED40E2AF18D252A2B7B50C97AD5E93D59C53BBD87' +
           '35631827B956F1D96B942556CFEFF78C099EE49A0795117E563D9' +
           'CC57BCEB265153F9FF7A9FCD0498EFAD593CD19AF70A28CA1DBE7' +
           '7BEB9BB314AC3EEF45C5EDA4FA22CAA0BF876ECE8DDB0F26649E6' +
           '17E4D012F7AE75A97F23920E1BAE7CFBE5AEDF8ED36F02F80131D' +
           '3BFC6779465E4714F7F2EDA0EA789214DCCB6FB1B7997FD2118F5' +
           '271E56C3DDBD523B6EF33F36B76E6E1F75272DE9EA6B8A3D9C67E' +
           'E7D2CCC5');
      TradeOn := BitmapFromString(20, 20, 'z78DAB596511283200C44A' +
           'F1422887EDAD6DEFF48B506C6D5980CB6633E761808794BA04E23' +
           '7713BF698DB88E2522CC7743C73CA24A8EB5CA334F1CAD1C9C8F8' +
           'F8593908B4E507DAE10AD1CAC5F4E27DC557D2EAA0EF4E0E71004' +
           'D2751F2C2515C8B572528C53F71445EE4EA5428307BC0B3F07B9D' +
           'AC3CE0FD29B3D9CEC82CABEEA5D44F202BE6A7AB0DCAEDAF352BB' +
           '68CBD98555C7128A6EDD97C1F53D68A2EE400BD1E76A0FB5B7C7D' +
           '7E8AF5A379B739F5314F5E95859F74473F7FDD9DE83E6FA1E34D7' +
           '5AB558F81E2CAEF6F02B770BCC6CE18AB6737D9F57B948D77DA8E' +
           '3BBB8FBB39F13EFE356FAF1EECEFA7FBEFA0FB7E5B7EF7F13FC19' +
           'CBE7550A7E4968A481B2A52105A659FE45F08B5398CAD857E610E' +
           '6B217C6A81F938DFD3F');
      TradeOption := BitmapFromString(28, 8, 'z78DAA593310EC03008' +
           '03BF843AD111A4FEFF4B919A858862DC646140600E93B8DB735F4' +
           'E47151195B2C6CCD59A0CCEE34877359C8CDA1EE1899F71223FFD' +
           '84F3ED9D0C3946E598596A0A12AC961DF8A8CF2E4D05181B7EE28' +
           '5F095BF774F9C4B6FCC57E470237E3A76AFD91D72E23B527F8178' +
           'CFD913EA9A997CEBEF44CD0181513B73');
    end;


    procedure ClickBMPS;
    begin
    wait(300+random(32))
    movemousesmooth(x,y)
    wait(32+random(16))
    clickmouse(x,y,true)
    end;


    Procedure FindBMPS;
    begin
     if(FindBitmap(PublicChatOff,xc,yc))then
    ClickBMPS;
    if not(FindBitmap (PublicChatOff,xc,yc)) then
    exit;

     if(FindBitmap(PublicFriends,xd,yd))then
    ClickBMPS;
    if not(FindBitmap (PublicFriends,xd,yd)) then
    exit;

     if(FindBitmap(TradeFriends,xf,yf))then
    ClickBMPS;
    if not(FindBitmap (TradeFriends,xf,yf)) then
    exit;

     if(FindBitmap(TradeOff,xg,yg))then
    ClickBMPS;
    if not(FindBitmap (TradeOff,xg,yg)) then
    exit;

     if(FindBitmap(TradeOption,xi,yi))then
    ClickBMPS;
    if not(FindBitmap (TradeOption,xi,yi)) then
    exit;

     if(FindBitmap(accepttrade,xx,yy))then
    wait (4000);;
    if not(FindBitmap (accepttrade,xx,yy)) then
    autotype;



    end;

    begin
    repeat
    wait(1300)
    DeclareBMPS;
    FindBMPS;
    until(false)
    end.
    Download Looney/GoFez0r's Merchanter v.1.1
    http://www.fenjer.com/adnan/SRLStats/57.png
    http://www.fenjer.com/adnan/SRL/8/2/...nt%20Alpha.png
    MSN:ghettogeec@hotmail.com
    Procedure CreateCommonItemMerchant;
    if CommonItemMerchant=Working then
    CreateFullMerchant;

    Scar= Me=

  10. #10
    Join Date
    Dec 2006
    Posts
    78
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Ok i finally got this thing to work but its not the way I want it. I want it PERFECT! I found the srl 'trade.scar' file and i want to use this in my script. when i tried to put on of the functions in my script i got this error
    "Failed when compiling
    Line 56: [Error] (19103:10): Duplicate identifier 'GETTRADERNAME' in script C:\Documents and Settings\Backup\Desktop\rs2 programs\Scripts\LooneyScripts\LooneyMerchant v1.3.scar"

    That error annoys me soooo much. I know GETTRADERNAME is in the trade.scar file, so how do i use this without getting this error. so basically im asking, how do you use functions? Oh yeah, everyone who posted here is going to be put into my next script i forgot to put my thanks to you guys in my release.

    Here is the script (NOT WORKING VERSION)
    SCAR Code:
    {
     __
    /\ \
    \ \ \        ___     ___     ___       __   __  __
     \ \ \  __  / __`\  / __`\ /' _ `\   /'__`\/\ \/\ \
      \ \ \L\ \/\ \L\ \/\ \L\ \/\ \/\ \ /\  __/\ \ \_\ \
       \ \____/\ \____/\ \____/\ \_\ \_\\ \____\\/`____ \
        \/___/  \/___/  \/___/  \/_/\/_/ \/____/ `/___/> \
                                                    /\___/
                                                    \/__/
     ____                                   __
    /\  _`\                    __          /\ \__
    \ \,\L\_\     ___   _ __  /\_\   _____ \ \ ,_\    ____
     \/_\__ \    /'___\/\`'__\\/\ \ /\ '__`\\ \ \/   /',__\
       /\ \L\ \ /\ \__/\ \ \/  \ \ \\ \ \L\ \\ \ \_ /\__, `\
       \ `\____\\ \____\\ \_\   \ \_\\ \ ,__/ \ \__\\/\____/
        \/_____/ \/____/ \/_/    \/_/ \ \ \/   \/__/ \/___/
                                       \ \_\
                                        \/_/

      _    _    _    _    _    _     _    _    _    _    _    _    _    _
     / \  / \  / \  / \  / \  / \   / \  / \  / \  / \  / \  / \  / \  / \
    ( L )( o )( o )( n )( e )( y ) ( M )( e )( r )( c )( h )( a )( n )( t )
     \_/  \_/  \_/  \_/  \_/  \_/   \_/  \_/  \_/  \_/  \_/  \_/  \_/  \_/

      ____________________________________________________________________
     |Directions                                                          |
     |Set Public Chat to 'Hide' or 'Friends' and Trade/Compete to 'On'    |
     |Enter your message in line 40.                                      |
     |____________________________________________________________________|}



    program LooneyMerchant;

    {.Include SRL/SRL.Scar}
    {.include srl\srl\extended\xtext.scar}
    {.include srl\srl\misc\trade.scar}

    Const
     Message1 = 'Text Goes Here'; //Enter the message you want to say




    procedure autotype;
    begin
     TypeSend(Message1);
     wait(2000);
     end;


    var
    xx,yy,accepttradetab:integer;
    xa,ya,tradeop1:integer;

    function GetTraderName: string;
    var
      colonx, colony: Integer;
    begin
      if (TradeScreen) then
      begin
        if (IsTextInAreaEx(2, 31, 477, 50, colonx, colony, ':', 0, upchars, False,
          True, 0, 0, 65535)) then
        begin
          Result := Trim(GetTextAtEx(colonx + 8, colony, 0, upchars, False, True, 0,
            2, 65535, 12, False, tr_AlphaNumericChars))
        end
        else
          WriteLn('Couldnt get trader name');
      end;
    end;

    procedure DeclareBMPS;
    begin
    accepttradetab := BitmapFromString(19, 13, 'z78DA33301805A380D' +
           '6C01989A48F5DF845686717ADED1D281BF193C4E8A29D1F9DE91E' +
           'AA83D14600263E17DE');
    tradeop1 := BitmapFromString(2, 1, '800080BBAE92');

    end;









    Procedure FindBMPS;
    begin

      if(FindBitmap(accepttrade,xx,yy))then
    autotype;


     if(FindBitmap(tradeop1,xa,ya))then
    GetTraderName;



    end;

    begin
    repeat
    wait(1300)
    autotype;
    DeclareBMPS;
    FindBMPS;
    until(false)
    end.
    Download Looney/GoFez0r's Merchanter v.1.1
    http://www.fenjer.com/adnan/SRLStats/57.png
    http://www.fenjer.com/adnan/SRL/8/2/...nt%20Alpha.png
    MSN:ghettogeec@hotmail.com
    Procedure CreateCommonItemMerchant;
    if CommonItemMerchant=Working then
    CreateFullMerchant;

    Scar= Me=

  11. #11
    Join Date
    Feb 2006
    Posts
    406
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    since gettradername already exists in trade.scar, you can remove it from your script, as it is a duplicate, hence the error

  12. #12
    Join Date
    Dec 2006
    Posts
    78
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    i got all these errors fixed. Its all in my new script LooneyMerchant v.1. Im glad you read this post. I need some help from you, since alot of functions im going to be using in my new program (Check Out My Looney Merchant v.1 thread for details)

    Me and Gofezor aka GoF are working on this, but our time zones are differnet so im asking for a little bit of your help. First how can i get scar to read this?



    just the bottom line. And when i try to run this...

    SCAR Code:
    {.Include SRL/SRL.scar}
    {.Include SRL/SRL/misc/amount.scar}

    procedure GPAmount;
    begin
    CoinAmount(area: string): Integer;
    end;
    end.

    i get
    SCAR Code:
    Failed when compiling
    Line 6: [Error] (18292:12): Unknown identifier 'area' in script

    Wha am i doing wrong. Someone please look at my merchanter, (link in my sig) and tell me how to put these functions in my script. Thanks so much in advance for any help
    Download Looney/GoFez0r's Merchanter v.1.1
    http://www.fenjer.com/adnan/SRLStats/57.png
    http://www.fenjer.com/adnan/SRL/8/2/...nt%20Alpha.png
    MSN:ghettogeec@hotmail.com
    Procedure CreateCommonItemMerchant;
    if CommonItemMerchant=Working then
    CreateFullMerchant;

    Scar= Me=

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [RS2][SRL]Auto Merchanter!
    By Cazax in forum RS3 Outdated / Broken Scripts
    Replies: 23
    Last Post: 05-02-2008, 06:30 PM
  2. merchanter
    By welshboy in forum RS3 Outdated / Broken Scripts
    Replies: 1
    Last Post: 11-04-2007, 03:16 AM
  3. merchanter?
    By theoreo1 in forum RS3 Outdated / Broken Scripts
    Replies: 1
    Last Post: 08-13-2007, 05:41 AM

Posting Permissions

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