Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug fixes #608

Merged
merged 3 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

@ConfigGroup(MahoganyHomesConfig.GROUP_NAME)
@ConfigInformation("<h2>S-1D Home Raider</h2>\n" +
"<h3>BETA PREVIEW 4</h3>\n" +
"<h3>BETA PREVIEW 5</h3>\n" +
"<p>1. <strong>Start anywhere:</strong> Just make sure to have teleports, saw and a hammer.</p>\n" +
"<p>2. <strong>Contracts:</strong> Select your desired contract <em>BEFORE</em> starting.</p>\n" +
"<p>3. <strong>Supplies:</strong> Stock up on the correct planks and Steel bars in the bank, the bot will handle resupplying on its own</p>\n" +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
@Slf4j
public class MahoganyHomesScript extends Script {

public static String version = "0.0.4";
public static String version = "0.0.5";
@Inject
MahoganyHomesPlugin plugin;

Expand Down Expand Up @@ -261,7 +261,7 @@ private void finish() {
&& plugin.getCurrentHome().isInside(Rs2Player.getWorldLocation())
&& Hotspot.isEverythingFixed()) {
if(plugin.getConfig().usePlankSack() && planksInPlankSack() > 0){
if (Rs2Inventory.contains(ItemID.PLANK_SACK)) {
if (Rs2Inventory.contains(ItemID.PLANK_SACK) && Rs2Inventory.contains(ItemID.STEEL_BAR)) {
Rs2Item plankSack = Rs2Inventory.get(ItemID.PLANK_SACK);
if (plankSack != null) {
Rs2Inventory.interact(plankSack, "Empty");
Expand Down Expand Up @@ -351,7 +351,8 @@ && isMissingItems()) {
if (Rs2Bank.walkToBankAndUseBank(Rs2Bank.getNearestBank(currentHome.getLocation()))) {
sleep(600, 1200);
if(plugin.getConfig().usePlankSack()){

if(Rs2Inventory.isFull() && !Rs2Inventory.contains(ItemID.STEEL_BAR))
Rs2Bank.depositAll(plugin.getConfig().currentTier().getPlankSelection().getPlankId());
Rs2Bank.withdrawX(ItemID.STEEL_BAR, 4-steelBarsInInventory());
sleep(600, 1200);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ protected void startUp() throws AWTException {
}
if (config.autoStamina()) {
Microbot.useStaminaPotsIfNeeded = true;
Microbot.runEnergyThreshold = config.staminaThreshold() * 1000;
Microbot.runEnergyThreshold = config.staminaThreshold() * 100;
}
autoRunScript.run(config);
specialAttackScript.run(config);
Expand Down