Results 1 to 18 of 18

Thread: sendKeys not working

  1. #1
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default sendKeys not working

    I want to use
    Simba Code:
    sendKeys('1', 60 + random(60), 60 + random(60));
    to load my bank preset, but it's not working.

    I use
    Simba Code:
    sendKeys(' ', 60 + random(60), 60 + random(60));
    to start making potions in the progress screen, but this does work.


    Does aynyone know why the first one is not working?
    Is there another way to load presets with keybinds?

  2. #2
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

  3. #3
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    I used that as an alternative. I just think it's very bot like because when I'm playing legit I NEVER click the button, the keybind is much more convenient (and faster).
    Almost a year ago I used and made a modified Clarity's ClarityWell. Then it worked just fine. I used a different pc, could that be the problem?

    I wanted to change the sendKeys procedure in the include, but I failed to find it.

    Edit: Nvm, I somehow skipped the "useKey" part. Thank you very much for helping!!

  4. #4
    Join Date
    Dec 2011
    Posts
    193
    Mentioned
    5 Post(s)
    Quoted
    51 Post(s)

    Default

    Lol your use of this
    Simba Code:
    60 + random(60), 60 + random(60));
    reminds of this image.

    But it does actually have a good use in this instance as it'll produce wait times that are biased towards the center, this is a lot more alike human typing than the equal spread you'd typically get with normal use of random.

    So kudos for that.

    OSRS Color Scripts: Borland_Salamanders | Borland_Iron_Ores
    Utilities & Snippets: [Color] OSBuddy Item Looting

  5. #5
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by Borland View Post
    Lol your use of this
    Simba Code:
    60 + random(60), 60 + random(60));
    reminds of this image.

    But it does actually have a good use in this instance as it'll produce wait times that are biased towards the center, this is a lot more alike human typing than the equal spread you'd typically get with normal use of random.

    So kudos for that.
    Except it doesn't work anymore^^

  6. #6
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    I tried it but it doesn't work. No matter if I use false, true or leave it blank, it will always withdraw my preset with the mouse.
    Am I the only one having this problem? Should I maybe update my includes?

  7. #7
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Quote Originally Posted by DonVitoCorleone View Post
    I tried it but it doesn't work. No matter if I use false, true or leave it blank, it will always withdraw my preset with the mouse.
    Am I the only one having this problem? Should I maybe update my includes?
    post the code please
    are you using SMART or official client?

  8. #8
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by acow View Post
    post the code please
    are you using SMART or official client?
    I'm using the official Java client.
    I sent my script in PM

  9. #9
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Quote Originally Posted by DonVitoCorleone View Post
    I'm using the official Java client.
    I sent my script in PM
    Simba Code:
    bankScreen.clickButton(BANK_BUTTON_PRESET_1);
    What you have ^ seems fine.
    It likely tries to open the bank, fails via using the key and then uses clicking the button as a failsafe.

    What operating system are you on (e.g. windows 7)?
    & Could you try to see if it works for you on SMART?

  10. #10
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by acow View Post
    Simba Code:
    bankScreen.clickButton(BANK_BUTTON_PRESET_1);
    What you have ^ seems fine.
    It likely tries to open the bank, fails via using the key and then uses clicking the button as a failsafe.

    What operating system are you on (e.g. windows 7)?
    & Could you try to see if it works for you on SMART?
    Well dammit, both the clickButton and sendKeys work when using SMART. Seems like I just wasted a lot of time using the official client.
    Thanks again for your help!

  11. #11
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Quote Originally Posted by DonVitoCorleone View Post
    Well dammit, both the clickButton and sendKeys work when using SMART. Seems like I just wasted a lot of time using the official client.
    Thanks again for your help!
    What operating system are you on (e.g. windows 7)?

  12. #12
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by acow View Post
    What operating system are you on (e.g. windows 7)?
    Windows 10, the pc is 3 monthts old.
    the
    Simba Code:
    bankScreen.open(BANK_NPC_BLUE(or any other bank location));
    also only works on SMART, maybe these 2 problems are related.

  13. #13
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Quote Originally Posted by DonVitoCorleone View Post
    Windows 10, the pc is 3 monthts old.
    the
    Simba Code:
    bankScreen.open(BANK_NPC_BLUE(or any other bank location));
    also only works on SMART, maybe these 2 problems are related.
    Run this and tell me the output please.
    Simba Code:
    program new;

    begin
      writeln(GetKeyCode('1'));
    end.

  14. #14
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by acow View Post
    Run this and tell me the output please.
    Simba Code:
    program new;

    begin
      writeln(GetKeyCode('1'));
    end.
    This is the output:

    Compiled successfully in 312 ms.
    49
    Successfully executed.

  15. #15
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Quote Originally Posted by DonVitoCorleone View Post
    This is the output:

    Compiled successfully in 312 ms.
    49
    Successfully executed.
    Aww, same as mine (windows 8).
    Probably a user setup error (*shrugs*) or a simba on windows 10 issue. Maybe somebody more knowledgeable / who has actually tested out simba on windows 10 has some input.

  16. #16
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by acow View Post
    Aww, same as mine (windows 8).
    Probably a user setup error (*shrugs*) or a simba on windows 10 issue. Maybe somebody more knowledgeable / who has actually tested out simba on windows 10 has some input.
    "user setup" as in it's a good idea to redownload Simba or an interface/settings problem?

  17. #17
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Quote Originally Posted by DonVitoCorleone View Post
    "user setup" as in it's a good idea to redownload Simba or an interface/settings problem?
    The only potential issue outside of insufficiently supported operating system that comes to mind is having a foreign keyboard type. Idk if that causes issues but it may.

  18. #18
    Join Date
    Apr 2016
    Posts
    126
    Mentioned
    1 Post(s)
    Quoted
    37 Post(s)

    Default

    Quote Originally Posted by acow View Post
    The only potential issue outside of insufficiently supported operating system that comes to mind is having a foreign keyboard type. Idk if that causes issues but it may.
    That could be the problem. I'm from Belgium so I'm using an azerty keyboard, it's from Dell though.

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
  •