Jump to content
Frequently Asked Questions
  • Are you not able to open the client? Try following our getting started guide
  • Still not working? Try downloading and running JarFix
  • Help! My bot doesn't do anything! Enable fresh start in client settings and restart the client
  • How to purchase with PayPal/OSRS/Crypto gold? You can purchase vouchers from other users
  • Mouse.click will right click sometimes


    greekhaima

    Recommended Posts

    Posted
    sleepUntil ( () ->org.dreambot.api.methods.magic.Magic.castSpell(toCast), 40);
    sleepUntil ( () ->Mouse.move(enemy), 300);
    Mouse.click(false);

     

    I have the following code but it will right click sometimes instead. 

     

    Also tried this but it will move the camera randomly and weird sometimes:

     

    Magic.castSpellOn(toCast, enemy), 100)
    Posted
    9 hours ago, greekhaima said:
    sleepUntil ( () ->org.dreambot.api.methods.magic.Magic.castSpell(toCast), 40);
    sleepUntil ( () ->Mouse.move(enemy), 300);
    Mouse.click(false);

     

    I have the following code but it will right click sometimes instead. 

     

    Also tried this but it will move the camera randomly and weird sometimes:

     

    Magic.castSpellOn(toCast, enemy), 100)

    Try enemy.interactForceLeft();

    Posted

    You don't need to sleep until, do:

    if(!Magic.castSpellOn(toCast, enemy)) return;

    Sleep.sleep(300,1000);

    You need to always randomize your sleeping times, Sleep#sleep, if you give two numbers, it will randomize the sleeping time for you, and when you're using Sleep#sleepUntil, use Calculations.random(2000,4000) for the timeout:

    sleepUntil ( () ->Mouse.move(enemy), 300); =====> sleepUntil ( () ->Mouse.move(enemy), Calculations.random(300,600));

    Hope this helps.

     

    Archived

    This topic is now archived and is closed to further replies.

    ×
    ×
    • Create New...

    Important Information

    We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.