api: use deques for projectiles and graphicsobjects
This commit is contained in:
@@ -1039,14 +1039,14 @@ public interface Client extends GameEngine
|
||||
*
|
||||
* @return all projectiles
|
||||
*/
|
||||
List<Projectile> getProjectiles();
|
||||
Deque<Projectile> getProjectiles();
|
||||
|
||||
/**
|
||||
* Gets a list of all graphics objects currently drawn.
|
||||
*
|
||||
* @return all graphics objects
|
||||
*/
|
||||
List<GraphicsObject> getGraphicsObjects();
|
||||
Deque<GraphicsObject> getGraphicsObjects();
|
||||
|
||||
/**
|
||||
* Creates a RuneLiteObject, which is a modified {@link GraphicsObject}
|
||||
|
||||
@@ -427,9 +427,7 @@ class DevToolsOverlay extends Overlay
|
||||
|
||||
private void renderProjectiles(Graphics2D graphics)
|
||||
{
|
||||
List<Projectile> projectiles = client.getProjectiles();
|
||||
|
||||
for (Projectile projectile : projectiles)
|
||||
for (Projectile projectile : client.getProjectiles())
|
||||
{
|
||||
int projectileId = projectile.getId();
|
||||
String text = "(ID: " + projectileId + ")";
|
||||
@@ -446,9 +444,7 @@ class DevToolsOverlay extends Overlay
|
||||
|
||||
private void renderGraphicsObjects(Graphics2D graphics)
|
||||
{
|
||||
List<GraphicsObject> graphicsObjects = client.getGraphicsObjects();
|
||||
|
||||
for (GraphicsObject graphicsObject : graphicsObjects)
|
||||
for (GraphicsObject graphicsObject : client.getGraphicsObjects())
|
||||
{
|
||||
LocalPoint lp = graphicsObject.getLocation();
|
||||
Polygon poly = Perspective.getCanvasTilePoly(client, lp);
|
||||
|
||||
Reference in New Issue
Block a user