-
Posts
947 -
Joined
-
Last visited
-
Days Won
1 -
Feedback
100%
Everything posted by Th3
-
Roomscape for developer.
-
gimmie
-
k princess
-
I love you.
-
Tired of being ignored, and we need your help.
Th3 replied to Pandemic's topic in Community Discussion
-
Congratulations to RoomScape for trial moderator. :)
Th3 replied to CrisisDesigns's topic in Spam/Off Topic
Is that chick an elf? Why are the ears so long? -
It's okay man, just say you pulled a maxi.
-
Why would you have jre7 if you only got java 8?
-
Ye. Take the small ban and don't question it or you can email Jagex and ask for a longer / permanent ban if you are unhappy with it..
-
Thanks bby. Also helped me get a GF and a BJ.
-
Update tool to work with the new OsBot Server.
-
They blocked access for some reason to sort throught them.
-
I thought some people might make use of this for either custom interaction or checking if entity is visible. Don't mind the ghetto fire entity check. import org.osbot.rs07.api.Client; import org.osbot.rs07.api.model.Entity; import org.osbot.rs07.api.model.Model; import org.osbot.rs07.api.util.GraphicUtilities; import java.awt.*; public class Calculations { public static Polygon getModelPolygon(Entity entity, Client client, Model model, int gridX, int gridY) { if (model == null) { return new Polygon(); } if (entity.getName().equalsIgnoreCase("Fire")) { return entity.getPosition().getPolygon(client.getBot()); } else { short[][] screenCoordinates = GraphicUtilities.getScreenCoordinates(client.getBot(), gridX, gridY, client.accessor.getPlane(), model); Polygon temp = new Polygon(); for (int triangleId = 0; triangleId < model.getTriangleCount(); triangleId++) try { int triangleA = model.getVertexXIndices()[triangleId]; int triangleB = model.getVertexYIndices()[triangleId]; int triangleC = model.getVertexZIndices()[triangleId]; short[] pointA = screenCoordinates[triangleA]; short[] pointB = screenCoordinates[triangleB]; short[] pointC = screenCoordinates[triangleC]; Polygon aw = entity.getPosition().getPolygon(client.getBot()); if (pointA != null && pointB != null && pointC != null) { if (pointA[0] <= -1 || pointA[1] <= -1 || pointB[0] <= -1 || pointB[1] <= -1 || pointC[0] <= -1 || pointC[1] <= -1) continue; for (int xpoints : aw.xpoints) { for (int ypoints : aw.ypoints) { if (pointA[1] <= ypoints && pointA[0] <= xpoints) { temp.addPoint(pointA[0], pointA[1]); } if (pointB[1] <= ypoints && pointB[0] <= xpoints) { temp.addPoint(pointB[0], pointB[1]); } if (pointC[1] <= ypoints && pointC[0] <= xpoints) { temp.addPoint(pointC[0], pointC[1]); } } } } } catch (ArrayIndexOutOfBoundsException var13) { } return temp; } } } public boolean isVisible(Script s, Entity entity) { Polygon polygon = Calculations.getModelPolygon(entity, s.client, entity.getModel(), entity.getGridX(), entity.getGridY()); if (polygon != null) { Rectangle rectangle = new Rectangle(4, 4, 512, 334); return rectangle.intersects(polygon.getBounds()); } return false; } public Rectangle visibleRectangle(Polygon polygon) { if (polygon != null) { Rectangle rectangle = new Rectangle(4, 4, 512, 334); return rectangle.intersection(polygon.getBounds()); } return null; } You could do without the null checks as well.
-
Dont ask for the impossible. That's it?
-
Dislike. Lets go fight me
-
[ERROR][Bot #1][07/15 11:52:57 PM]: Error in script executor! java.lang.NullPointerException at org.osbot.rs07.event.ScriptExecutor$InternalExecutor.run(ScriptExecutor.java:99) at java.lang.Thread.run(Unknown Source) Kills the client.
-
Trippy game. It's like legos + minecraft.