November 27, 20169 yr I kind of assumed it would be handled in the webwalking since it's so fancy. However, if you walk by draynor, and it runs into one of the tree npcs, it will literally just kill you in that spot over and over. Anyone have a workaround?
November 27, 20169 yr create your own solution to handle the obstacle? add it into the break condition if the tree is X distance away and handle it yourself
November 27, 20169 yr fail safe if ur hp bar is visable run away to square ... , ... hmm if he is around that area, what if he is attacked by the guards on the way?
November 27, 20169 yr isUnderAttack public boolean isUnderAttack() Whether the character is under attack. Returns: True if the hitbar is not visible OR the hitbar is visible and this character is interacting with another character. hmm if he is around that area, what if he is attacked by the guards on the way? u can add a area to it, using explv tool: http://explv.github.io/
November 27, 20169 yr isUnderAttack public boolean isUnderAttack() Whether the character is under attack. Returns: True if the hitbar is not visible OR the hitbar is visible and this character is interacting with another character. u can add a area to it, using explv tool: http://explv.github.io/ Just check for that darn tree haha
November 27, 20169 yr Just check for that darn tree haha there a few of them so better to just add the whole draynor manor area
November 27, 20169 yr there a few of them so better to just add the whole draynor manor area In general i personally don't recommend walking to current location + x because it will not work with WalkingEvent if the tile is not walkable which can be the case because you base it on current location + x Just my two cents
November 27, 20169 yr Author In general i personally don't recommend walking to current location + x because it will not work with WalkingEvent if the tile is not walkable which can be the case because you base it on current location + x Just my two cents exactly where im currently at lol what im thinking: if tree is north - walk west/east if tree is west/east walk north just figured someone had already written the code ;) Edited November 27, 20169 yr by dmm_slaver
November 27, 20169 yr Author create your own solution to handle the obstacle? add it into the break condition if the tree is X distance away and handle it yourself How to add it into the break condition so it stops the webwalk?
November 27, 20169 yr How to add it into the break condition so it stops the webwalk? WebWalkEvent: http://osbot.org/api/org/osbot/rs07/event/WebWalkEvent.html
November 27, 20169 yr Author WebWalkEvent: http://osbot.org/api/org/osbot/rs07/event/WebWalkEvent.html hmm maybe i am using it incorrectly [iNFO][bot #1][11/27 11:47:10 AM]: java.lang.NullPointerException at org.osbot.rs07.event.WebWalkEvent.execute(ji:29) at SharkMuler.onLoop(SharkMuler.java:134) at org.osbot.rs07.event.ScriptExecutor$InternalExecutor.run(mh:48) at java.lang.Thread.run(Thread.java:745) WebWalkEvent ev = new WebWalkEvent(edgeLever); ev.setBreakCondition(new Condition() { @[member=Override] public boolean evaluate() { return myPlayer().isHitBarVisible(); } }); ev.execute(); at SharkMuler.onLoop(SharkMuler.java:134) is ev.execute();
November 27, 20169 yr hmm maybe i am using it incorrectly WebWalkEvent ev = new WebWalkEvent(edgeLever); ev.setBreakCondition(new Condition() { @[member='Override'] public boolean evaluate() { return myPlayer().isHitBarVisible(); } }); ev.execute(); at SharkMuler.onLoop(SharkMuler.java:134) is ev.execute(); execute(ev);
November 27, 20169 yr Author execute(ev); Okay I am more confused now. It seems to be working, slightly. WebWalkEvent ev = new WebWalkEvent(edgeLever); ev.setBreakCondition(new Condition() { @[member=Override] public boolean evaluate() { log("Check"); return myPlayer().isHitBarVisible(); } }); execute(ev); when im walking normally, it says "check" every couple of steps. However, it seems to only check while i am moving. So if I get stuck behind the tree, and it's smacking me for 3 damage every tick, its just sitting there, and its not saying "check" at all until i pause the bot and move manually or it dies.
November 27, 20169 yr Okay I am more confused now. It seems to be working, slightly. WebWalkEvent ev = new WebWalkEvent(edgeLever); ev.setBreakCondition(new Condition() { @[member='Override'] public boolean evaluate() { log("Check"); return myPlayer().isHitBarVisible(); } }); execute(ev); when im walking normally, it says "check" every couple of steps. However, it seems to only check while i am moving. So if I get stuck behind the tree, and it's smacking me for 3 damage every tick, its just sitting there, and its not saying "check" at all until i pause the bot and move manually or it dies. Add me on skype.
Create an account or sign in to comment