Everything posted by Botre
- Alone on Valentines day?
-
Alone on Valentines day?
Everyone dies. Dead parents at least had sex once. You're still a forever alone virgin.
-
LinkedIn
https://be.linkedin.com/in/bjorn-krols-5a6347107
-
Can any1 figure it out
The formula to calculate the total (amount of involved money, ambigious) is: All the money you owe to person 1 + all the money you owe to person 2 = 150 + 100 = 150 However, the question assumes that the formula to calculate the total amount of involved money is: Part of the money you owe to person 1 + all of the money you owe to person 2 + chocolates = 70 + 20 + 20 = 140 The formula presented by the question is bogus.
-
Can any1 figure it out
brb changing my answer
-
[WIP] selection library, click & point, select it in game
Update: magic spells
-
[WIP] selection library, click & point, select it in game
This has nothing to do with graphics really. But ok. Why not ?
-
[WIP] selection library, click & point, select it in game
But can you use his code inside your code ? This isn't a script its a library of methods that will be accessible for all that
-
[WIP] selection library, click & point, select it in game
Nope
-
[WIP] selection library, click & point, select it in game
"Select the safespot you'd like to use" "Draw the path you would like to record" "Select the entity you would like to attack" "Select the item you'd like to alch" "Select your special attack weapon" "Select the food you would like to eat" "Select all positions to avoid" "Select the rocks you would like to mine" "Select the fishing spots to avoid" "Select your mule character" Etcetera. I hate when GUI's make me type. I hate to update comboboxes. Etcetera,
-
[WIP] selection library, click & point, select it in game
Update: - Added continual selection. - Added de-selection.
- Hi, I'm Newton
-
[WIP] selection library, click & point, select it in game
Update: prayer buttons.
-
[WIP] selection library, click & point, select it in game
Update: item container slots
-
How to determine when an action is completed.
You check for consequences of that action (experience increase, item mutation, player flags, etc...).
-
[WIP] selection library, click & point, select it in game
- [WIP] selection library, click & point, select it in game
SAPI Hello world. Here's a sneak peak of a little library I'm working on, its goal is to simplify high-level interaction between bot/script and game, useful when you need a superficial game variable but don't have the time or knowledge to fetch it via code or a clunky GUI. Currently, the following types are selectable (with more to come): Entities Widgets Positions Bank slots Inventory slots Prayer buttons Magic spells Currently, the following brushes are available (with more to come): Point Shapes: Arc2D, Ellipse2D, Rectangle2D, RoundRectangle2D The library will be free & available for everyone. No ETA but shouldn't be too long. Code example @ScriptManifest(author = "Botre", info = "", logo = "", name = "Example Script", version = 0) public class Example extends Script { private Sapi sapi; @Override public void onStart() throws InterruptedException { super.onStart(); // Initialize API. sapi = new Sapi(this); // Add a filter to the inventory module: only empty slots are made selectable. sapi.getInventorySlotModule().getFilters().add(slot -> slot.isEmpty()); // Change the painter. sapi.getInventorySlotModule().setPainter(new DefaultItemContainerSlotPainter(this) { @Override public void paint(Graphics2D g2d, ItemContainerSlot object) { g2d.setColor(Color.BLUE); g2d.drawString(object.getItem().getName(), 0, 0); super.paint(g2d, object); } }); // Activate the module / enable selection. sapi.getInventorySlotModule().setActive(true); // Start the API. sapi.start(); } @Override public void onExit() throws InterruptedException { super.onExit(); // Stop API. sapi.stop(); } @Override public int onLoop() throws InterruptedException { // Iterate over selected items. for (ItemContainerSlot slot : sapi.getInventorySlotModule().getSelected()) { log(slot.getItem().getName()); } return 500; } @Override public void onPaint(Graphics2D g2d) { super.onPaint(g2d); sapi.getInventorySlotModule().paintBrush(g2d); sapi.getInventorySlotModule().paintSelected(g2d); } } Screenshots- Do you sit down or stand up while you wipe?
Use your feet to spread your cheeks apart.- Type integers with getKeyboard class
Play around with these: int i = 0; String a = Integer.toString(i); String b = "" + i; String c = String.valueOf(i); String d = new Integer(i).toString();- onPaint caveats
You're asking me if: calculation_cost + constant_scheduling_overhead_cost < calculation_cost * 15 Well, that depends entirely on the cost of the calculations per call and how much the scheduling overhead actually is. Once the total cost of all calculations starts exceeding (constant_scheduling_overhead_cost / 14) it becomes worth using an additional thread from a performance POV.- onPaint caveats
Thread A changes String X twice per second. Thread B reads String X 30 times per second. The reason I'm putting String X in a variable is so it's available to both thread A & thread B, not for caching purposes (since Strings are pretty much automatically cached internally (like you just pointed out :p)).- The difference between dynamic and static skill levels
Read more here: https://github.com/Botre/OSBot-Tutorials/wiki/The-difference-between-dynamic-and-static-skill-levels- [Quick-guide] How to print onStart() error details
- [Quick-guide] How to print onStart() error details
Read more here: https://github.com/Botre/OSBot-Tutorials/wiki/How-to-log-the-stack-trace-of-an-exception-thrown-by-onStart()- Paint disappearing when minimizing client, will only show when I hover over it ?
onStart usually gets called AFTER the first onPaint called. So if you use onStart to initialize variables used inside onPaint you could run into trouble. You could use a static block to make sure the image gets initialize on time or you could null check the image variable in your onPaint. Or maybe it's something entirely different that's causing the issue :p Getting any errors? Try providing a gif if you can. - [WIP] selection library, click & point, select it in game