slow down bone bury slightly, check user still logged in

This commit is contained in:
RedSparr0w
2019-10-21 12:54:31 +13:00
parent 724e425f91
commit c8166df341
@@ -3,10 +3,7 @@ package ParaScript.strategies;
import ParaScript.data.Variables; import ParaScript.data.Variables;
import org.parabot.environment.api.utils.Time; import org.parabot.environment.api.utils.Time;
import org.parabot.environment.scripts.framework.Strategy; import org.parabot.environment.scripts.framework.Strategy;
import org.rev317.min.api.methods.Inventory; import org.rev317.min.api.methods.*;
import org.rev317.min.api.methods.Items;
import org.rev317.min.api.methods.Menu;
import org.rev317.min.api.methods.Players;
public class BuryBones implements Strategy { public class BuryBones implements Strategy {
@@ -33,8 +30,8 @@ public class BuryBones implements Strategy {
private void buryBones(){ private void buryBones(){
try { try {
Inventory.getItem(527).interact(Items.Option.SECOND); Inventory.getItem(527).interact(Items.Option.SECOND);
Time.sleep(250); Time.sleep(500);
if (hasBones()) buryBones(); if (Game.isLoggedIn() && hasBones()) buryBones();
} catch (Exception err) { } catch (Exception err) {
System.out.println("Bone burying error: ¯\\_(ツ)_/¯"); System.out.println("Bone burying error: ¯\\_(ツ)_/¯");
} }