scape Posted May 4, 2013 Share Posted May 4, 2013 (edited) final int[] arrowids = { 882, 884, 886, 888, 890, 892, 863, 864, 865 };public int arrowid; void findarrowid() { Player player = client.getMyPlayer(); if (arrowid < 800) { List<GroundItem> list = client.getCurrentRegion().getItems(); Player player = client.getMyPlayer(); NPC attackables = closestNPC(attackable); for (GroundItem g : list) { for (int i : arrowids) { if (attackables != null) { if (player.isUnderAttack() && g.getPosition().distance( player.getPosition()) == 1 && i == g.getId()) { arrowid = g.getId(); log("Arrow id is now " + arrowid + "!"); } } } } } } Pickup method: void pickup() { List<GroundItem> list = client.getCurrentRegion().getItems(); Player player = client.getMyPlayer(); for (GroundItem g : list) { if (g.getId() == arrowid) { try { if (g.getPosition().distance(player.getPosition()) <= 2 && !player.isMoving()) { selectEntityOption(g, "Take"); sleep(random(3000)); } } catch (Exception e) { } } } } Edited May 4, 2013 by scape Link to comment Share on other sites More sharing options...
Pieter Posted May 4, 2013 Share Posted May 4, 2013 for what would someone need this? Link to comment Share on other sites More sharing options...
scape Posted May 4, 2013 Author Share Posted May 4, 2013 for what would someone need this? To find the id to pickup an arrow Link to comment Share on other sites More sharing options...
Nicholas Posted May 4, 2013 Share Posted May 4, 2013 this may help a lot of AIO fighter/combat scripts Link to comment Share on other sites More sharing options...
zweetkonijn Posted May 4, 2013 Share Posted May 4, 2013 Did you add bolts? Link to comment Share on other sites More sharing options...
XavierM Posted May 4, 2013 Share Posted May 4, 2013 for arrow id you could get the item id from equipment interface Link to comment Share on other sites More sharing options...
Vitanet Posted May 4, 2013 Share Posted May 4, 2013 Did you add bolts? in this part final int[] arrowids = { 882, 884, 886, 888, 890, 892, 863, 864, 865 }; you need add ids of bolts toy want example: final int[] arrowids = { 882, 884, 886, 888, 890, 892, 863, 864, 865, you new id, you othernew id, etc }; Link to comment Share on other sites More sharing options...