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
  • Jad Flicking Script


    ScripterSteve

    Recommended Posts

    Posted

    I can code a JAD prayer flicking script but would like someone to test it works, if people would like this and anyone would be happy to test - please let me know

    Posted
    3 hours ago, ScripterSteve said:

    I can code a JAD prayer flicking script but would like someone to test it works, if people would like this and anyone would be happy to test - please let me know

    If you already have the animations Ids then that would be a very easy thing to do. Although it won't deny the hits, you can try testing it on an npc with multiple attack styles.

    Posted
    12 hours ago, ScripterSteve said:

    I can code a JAD prayer flicking script but would like someone to test it works, if people would like this and anyone would be happy to test - please let me know

    Tagging, healers and pulling them while flicking jad sounds fun in a script

    Posted

    Noob question from someone who plans on making a combat script: how do you make a prayer flick script? Wouldn't that be very bot like? How are you randomizing click times in such a short window?

    Posted

    never done it for dreambot but osbot code is something like:

     private void duringCombat() {
            long timestampTick = 0;
            boolean firstAttack = false;
            long attackCycle = 2400;
            long ticksUntilWeNeedToPray;
            while (getCombat().isFighting()) {
                long curTick = System.currentTimeMillis() / 600;
                if (focussedTzhaar().getAnimation() == 2610 && !firstAttack) {
                    log("attack registered");
                    timestampTick = System.currentTimeMillis();
                    firstAttack = true;
                } else if (firstAttack) {
                    log(timestampTick);
                    ticksUntilWeNeedToPray = ((System.currentTimeMillis() - timestampTick) / 600) % 4;
                    log(ticksUntilWeNeedToPray);
                    if (ticksUntilWeNeedToPray < 2) {
                        try {
                            sleep(random(200, 400));
                        } catch (Exception e) {
                        }
                        if (getPrayer().isActivated(PrayerButton.PROTECT_FROM_MELEE)) {
                            getPrayer().set(PrayerButton.PROTECT_FROM_MELEE, false);
                        }
                        if (getSkills().getDynamic(PRAYER) < 10) {
                            pray();//pray
                        } else if (getSkills().getDynamic(HITPOINTS) < 20 && this.config.getArmourMode() != "Dharoks") {//panic eat for if guthaning
                            eat();
                        } else if (this.config.getArmourMode() == ("Guthans") && myPlayer().getHealthPercent() < eatPercentage) {
                            heal();//heal using guthans
                        } else if (this.config.getArmourMode() == ("Guthans") && myPlayer().getHealthPercent() > 90 && (int) (Math.random() * 33) < 3) {
                            reEquipStartingGear();//re-equipping starting gear if using guthans
                        } else if (this.config.getArmourMode() == ("Dharoks") && getSkills().getDynamic(HITPOINTS) > dhHP && Math.random() * 25 < 1) {//guzzling if using dharoks
                            log("low hp, guzzling");
                            Filter<Item> cake = item -> item.getName().contains("Dwarven rock cake") && item.hasAction("Guzzle");
                            getInventory().interact("Guzzle", cake);
                            dhHP = 1;
                        } else if (this.config.getArmourMode() == "Dharoks" && System.currentTimeMillis() - this.lastFlickedPrayer > this.msToWaitTillFlick) {
                            flick();
                            log("Flicking Rapid heal");
                        }
                        else if (getTabs().getOpen() != Tab.PRAYER) {
                            getTabs().open(Tab.PRAYER);
                        }
                        //Prayer flick coming up; prepare for it, and do it once we're at 0 ticks left
                    } else {
    //                if(ticksUntilWeNeedToPray == 3 ){
                            try {
                                sleep(random(150, 400));
                            } catch (Exception e) {
                            }
                            if (!getPrayer().isActivated(PrayerButton.PROTECT_FROM_MELEE)) {
                                getPrayer().set(PrayerButton.PROTECT_FROM_MELEE, true);
                                log("Flicked Melee");
    
                            }
                            //              }
                            //We've got time; do other less important things. But quickly! (including turning off prayer)
                        }
    
                        //int cycleTick = combatTick % enemyAttackSpeedTicks;
                    }
                }
    
    
        }
    Posted

    I am sure there are much better ways of doing it but above is actual flicking prayer if you read it through basically if hit is on tick 4 puts pray up on tick 3 takes down on tick 4/1 i believe

    • 3 weeks later...
    Posted

    I was thinking of writing this myself, so if you did it I'd be most pleased. It would definitely suck to test/debug it though; get all the way to Jad and the script fucks you lmao

    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.