Everything posted by BravoTaco
-
Morytania Diary (Easy)
That would help tremendously. I'll add you on discord when I get home from work. I can give you auth to the script if you would like, for helping me out.
-
How to increase/decrease attack radius?
Np
-
Morytania Diary (Easy)
Thanks, I have the codebase setup to where it would be easy to add new tasks to it. I just don't have the requirements for the all the medium tasks so wouldn't be able to test them. Maybe later in the future once I get some higher stats and some quests completed.
-
How to increase/decrease attack radius?
Code snippet to help ya out: //Some variables to be used in calculating the npc. Area areaAroundPlayer = myPlayer().getArea(10); String npcName = "NPCName"; //Creating a filter for the npc. Filter<NPC> npcFilter = new Filter<NPC>() { @Override public boolean match(NPC npc) { return areaAroundPlayer.contains(npc) && npc.getName().equals(npcName) && npc.isAttackable() && getMap().canReach(npc); } }; //You can also use lambda expressions to create the filter which would look like this Filter<NPC> npcFilter = npc -> areaAroundPlayer.contains(npc) && npc.getName().equals(npcName) && npc.isAttackable() && getMap().canReach(npc); //Using the filter to obtain an npc. NPC npc = getNpcs().closest(npcFilter);
-
Pyro
Have tested for about an hour on two seperate accounts, one at fally, and the other at the GE, and have not been able to reproduce this. Could you copy paste the contents from the logger for me. Go To Settings in the top right -> Toggle Logger
-
Pyro
Interesting. Are you able to give me what is printed in the console if there is anything? Will test that location now.
-
Morytania Diary (Easy)
Features: How To Use: Pictures: Bug Report Form: Changelog:
-
Trade Handler
Do you mean like not trade that person again? If so this will have to be done in your own script logic. An example would be to add that player to a blacklist after he has declined the trade or keep track of how many times that player has declined the trade and if it exceeds a certain threshold add them to the blacklist to not be traded again. Example Code Without Threshold (Untested): Example Code With Threshold (Untested):
-
Trade Handler
Sure can 🙂 Trading Items: Receiving Items:
- Mouse movement in menus
-
Trade Handler
Hopefully this works, haven't tested. Let me know if it doesn't
-
Trade Handler
For this, check to see if the items that you are attempting to trade are in/out of the players inventory. Ill edit this to make it work in that way once i get home.
-
BravoTacos SOS
It should already do this, I have added more checks before starting to walk to the stronghold and after buying all items. I haven't been able to reproduce this are you able to give me what is printed in the logger? Go to Settings in the top right, select toggle logger, copy paste the contents.
-
Webwalker/walk overshooting position
You dont need to walk to it, as the interaction method will do this for you. Just check to see if it is not null than interact with it.
-
getInventory.contains problems
Very interesting. Might be as token said. You could get all the items in the inventory and see if it detects any items at all. getInventory.getItems() - returns item array, i think 🙂 Loop through that and log the name of the items.
-
getInventory.contains problems
Try putting the code directly into the OnLoop without using your phreeBot call just do getInventory().contains(name) If that works than it might be how your setting the phreeBot var.
-
Detecting if an enchanted bolt has activated
No idea if each bolt has a special sound associated with it, or even if it your able to grab the sound id, but you could try to use the onPlayAudio() method.
-
Drop Methods
I thought the exchangeContext method was deprecated. Was this changed recently? Updated the code with this. I thought about that when i was writing this, but that would require two different for loops in each drop method, one that adds to i and another that subtracts from it. Or set i depending on the boolean value to 0 or the length of the array and than update it inside the for loop. I felt that it was easier to read if i just reversed the array. If i added the release key into drop() than it would release the key before the dropping is done.
-
Drop Methods
Two drop methods but, both of them are able to be reversed. You can also add item name(s) that you don't want to be dropped. Example: Code:
-
unable to pm
Go up to the messages tab in the top right corner, click it, and on the button that says Compose new, Right click that and open it in a new tab.
-
Help: Walk from any location to a predefined mob area
Np. Need any help feel free to drop me a pm. Gl on your scripting endeavour. 🙂
- Couple Sleep Methods
- BravoTacos SOS
-
Help: Walk from any location to a predefined mob area
To customize it you will have to use a WebWalkEvent and a PathPreferenceProfile. I don't think you can change how it clicks. There is few different options to be used so you will have to reference the API to see them all, but here is a quick example. WebWalkEvent webWalkEvent = new WebWalkEvent(location); //This will ignore using roads and take a more direct path to the destination. webWalkEvent.useSimplePath(); PathPreferenceProfile pathPreferenceProfile = new PathPreferenceProfile(); pathPreferenceProfile.setAllowSpiritTrees(false); pathPreferenceProfile.setAllowGliders(false); webWalkEvent.setPathPreferenceProfile(pathPreferenceProfile); execute(webWalkEvent);
-
Is this too cluttered
Just a couple of things that I noticed are: Redundant Cast: Type Arguments That Are Not Needed If Statement Always Returns False? Also maybe try and break it up into separate methods for easier debugging and readability. 🙂