Skip to content

Conversation

@Gage307
Copy link
Contributor

@Gage307 Gage307 commented Jan 28, 2026

numerous bug fixes

}
Microbot.log("Drinking");
if(Rs2GameObject.interact(rej, "Drink")){
if(rej.click("Drink")){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't this break if you're not executing it on the client thread?


public void fightrev(revKillerConfig config){
Rs2NpcModel Rev = (Rs2Npc.getNpc(config.selectedRev().getName()));
Rs2NpcModel Rev = Rs2Npc.getNpc(config.selectedRev().getName());

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace with rs2NpcCache

if(!Rs2Dialogue.isInDialogue()){
Microbot.log("At the cave, clicking.");
if(Rs2GameObject.interact(31555, "Enter")){
if(Microbot.getRs2TileObjectCache().query().withId(31555).nearest().click("Enter")){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace with rs2TileObjectCache

if(revenentKnight() == null) return;

if(Rs2Npc.attack("Revenant knight")){
if(Rs2Npc.interact(revenentKnight(), "Attack")){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace with rs2NpcCache


if(Rs2GroundItem.isItemBasedOnValueOnGround(500,10)){
return;
if(goodLootOnGround()){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit-picking, but please apply proper formatting: a space after if and after the closing )

if(!super.isRunning()){
break;
List<Rs2TileItemModel> itemsOnGround = Microbot.getRs2TileItemCache().query().where(it -> it.getWorldLocation().distanceTo(Rs2Player.getWorldLocation()) < 12 && !it.getName().contains("arrow") && it.getTotalGeValue() > 500).toList();
List<Rs2TileItemModel> BlightedItemsOnGround = Microbot.getRs2TileItemCache().query().where(it -> it.getWorldLocation().distanceTo(Rs2Player.getWorldLocation()) < 12

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

variable names should be camelCase

break;
List<Rs2TileItemModel> itemsOnGround = Microbot.getRs2TileItemCache().query().where(it -> it.getWorldLocation().distanceTo(Rs2Player.getWorldLocation()) < 12 && !it.getName().contains("arrow") && it.getTotalGeValue() > 500).toList();
List<Rs2TileItemModel> BlightedItemsOnGround = Microbot.getRs2TileItemCache().query().where(it -> it.getWorldLocation().distanceTo(Rs2Player.getWorldLocation()) < 12
&& (it.getName().toLowerCase().contains("blighted")

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would personally keep the strings in a static final Set/List and iterate over it

sleepUntil(()-> !Rs2Player.isAnimating() && !Rs2Inventory.isFull(), 1500);
}
}
if(!Rs2Inventory.isFull()){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An else would be more appropriate here instead of this if

}
}
if(!Rs2Inventory.isFull()){
if(Microbot.getRs2TileItemCache().query().withId(theItem.getId()).nearest() != null){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use injected version instead of static one.

if(Rs2Player.isMoving()){
sleepUntil(()-> !Rs2Player.isMoving(), Rs2Random.between(3000,6000));
if(!Rs2Inventory.isFull()){
if(Microbot.getRs2TileItemCache().query().withId(theItem.getId()).nearest() != null){

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use injected version instead of static one.

@chsami chsami merged commit 408583f into chsami:development Jan 29, 2026
1 check passed
chsami added a commit that referenced this pull request Jan 29, 2026
Rev killer, Barrows updates (#298)

* fix(BarrowsScript): numerous bug fixes

* fix(RevKillerScript): numerous bug fixes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants