Everything posted by Explv
- States
-
Explv's AIO [13 skill AIO in 1 script]
It's more than 10,000 lines, it's pretty well organised, so if someone tells me that there is a bug with x in y skill, I know where to look
-
Explv's AIO [13 skill AIO in 1 script]
I have pushed a fix for crafting, it will be available when the SDN is next updated. Thanks I will add something to fix this, if not tonight, then tomorrow. Thanks for the report I have pushed a fix for the amulet crafting, it will be available the next time the SDN is updated.
-
trading
I'm glad you found it useful
-
Explv's AIO [13 skill AIO in 1 script]
Thanks, i'll try and add something to prevent that from happening
-
Explv's AIO [13 skill AIO in 1 script]
Thanks for the report, I am aware of the crafting issues for things like amulets, I'll get it fixed asap. Thanks
-
trading
Bot with items to trade: if inventory contains x items if bank is open close bank else if not in trade use trade interaction on target player sleep until in trade else if in trade with wrong player close trade else if on first trade screen if not offered x items offer x items else if not accepted accept trade else if on second screen if not accepted trade accept trade else if not bank is open open bank else if bank contains x items withdraw x items else stop Bot receiving items: bool trade On received message: if message is of type trade and message is from target player set trade to true On loop: if trade is true if not in trade do trade interaction with target player sleep until in trade else if not trading target player close trade else if on first window if other player accepted accept trade else if on second window if other player accepted accept trade set trade to false
-
Heeeeeyguiz
- Is it possible to run a bat file from inside a script?
Take a look at the ServerSocket and Socket classes, there are plenty of examples online- Is it possible to run a bat file from inside a script?
Indeed, I expected that OSBot would prevent you from executing files like that. Im not sure if there is a -allow CLI parameter for allowing such things, but I doubt it. You will need to figure out an alternative solution for muling For example you could write a server that listens on a socket, when it receives a message from your script it runs the muling script- Is it possible to run a bat file from inside a script?
If you want to start another script you can do: List<String> command = new ArrayList<>(); Collections.addAll(command, "java", "-jar", "C:\\Path\\To\\OSBot.jar"); Collections.addAll(command, "-login", "username:password"); // add all the other parameters like above ProcessBuilder processBuilder = new ProcessBuilder(command); processBuilder.start(); You can check out the source of my OSBot Manager to see how I did it: https://github.com/Explv/osbot_manager/blob/master/src/script_executor/ScriptExecutor.java If you really want to store it in a .bat file then you can do the same as above but replacing the command with: List<String> command = new ArrayList<>(); Collections.addAll(command, "cmd", "/c", "start"); command.add("C:\\Path\\To\\.bat");- Checking if player is within an area
tl;dr It's all the same shit. The Area class has several contains methods: public boolean contains(Entity entity) { return contains(entity.getX(), entity.getY()) && plane == entity.getZ(); } public boolean contains(Position position) { return contains(position.getX(), position.getY()) && plane == position.getZ(); } public boolean contains(int x, int y, int z) { return contains(x, y) && plane == z; } public boolean contains(int x, int y) { return (new java.awt.geom.Area(polygon)).contains((double)x, (double)y); } So, when you call: area.contains(myPlayer()) That will call the contains(Entity entity) method, because the Player is an Entity, which will then call the contains(int x, int y) method with the x coordinate and y coordinate of that entity, and also check if the z vlaues are the same. When you call: area.contains(myPosition()) That will call the contains(Position position) method, which will then call the contains(int x, int y, int z) method using the x, y and z coordinates of that Position, which then will call the contains(int x, int y) method, and also check the z values are the same. Either way, they both end up calling the same method contains(int x, int y) which checks that the polygon of the Area contains those coordinates, and also check that the z value is the same.- Checking if player is within an area
No, i'm not.- Checking if player is within an area
The player object for your own player can be accessed with: Player player = myPlayer(); The method: myPosition() Just does: myPlayer().getPosition()- Checking if player is within an area
if (area.contains(myPosition())- Explv's AIO [13 skill AIO in 1 script]
When I have tested everything fully and ironed out the bugs, then I will probably request it to be premium- Explv's AIO [13 skill AIO in 1 script]
Thanks for the report, I will make sure it selects the inventory to prevent that happening. I will also try and add something to avoid that pesky Mugger- How can I play H1Z1?`
_ It depends on what his other PC specs are though, because we have not seen them. It would be pointless upgrading to a 1060 if his CPU isn't good enough for example- How can I play H1Z1?`
You could pick up an RX460 or GTX 1050 for $100-$150- How can I play H1Z1?`
You do not need to save for a gtx1080 to play H1Z1. The gtx 1080 is the latest high end graphics card. The recommended gfx card for H1Z1 is a gtx560 or better. Take a look at the recommended specs for the game and try to upgrade your PC to at least as good as that, or better if you want to play other more demanding games in the future- How can I play H1Z1?`
What does this have to do with software development?- Enable input on script start
No, it was removed from the API- Explv's OSBot Manager
Are you sure the path is correct?- IntelliJ Paint Not Working
You nearly did it correctly, I'm not sure if this is the best way (someone correct me if there is a better method) but what you can do is create a new folder in the artifact called "resources" and then add the contents of the resources folder in your project to that folder.Currently what you are doing is putting the contents of resources into your jar, but they will no longer be in a directory called resources. Sorry if that is unclear Also you do not need to include the OSBot jar in your artifact- Explv's Tutorial Island [Free] [Random Characters]
No you are correct, I will update it when I am home, thanks - Is it possible to run a bat file from inside a script?