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