anyDrop
returns bool
anyDrop(id: int, name: string, nameContains: string, within: int, area: area) -> bool
True when at least one drop matches. Stops at the first one, so it is cheaper than counting.
| Parameter | Type | What it does |
| idoptional |
int |
the item id from the cache, not the server index |
| nameoptional |
string |
the whole name, ignoring case |
| nameContainsoptional |
string |
part of the name, ignoring case |
| withinoptional |
int |
how many tiles away at most, straight line |
| areaoptional |
area |
must be standing inside this area |
Example
if anyDrop(name: "Bones", within: 4) { stop }
dropCount
returns int
dropCount(id: int, name: string, nameContains: string, within: int, area: area) -> int
How many drops match every option given. With no options, how many there are.
| Parameter | Type | What it does |
| idoptional |
int |
the item id from the cache, not the server index |
| nameoptional |
string |
the whole name, ignoring case |
| nameContainsoptional |
string |
part of the name, ignoring case |
| withinoptional |
int |
how many tiles away at most, straight line |
| areaoptional |
area |
must be standing inside this area |
Example
if dropCount(id: 10, within: 6) > 0 { walkTo(tile(303, 553)) }
drops
returns list<drop>
drops(id: int, name: string, nameContains: string, within: int, area: area) -> list<drop>
Every drop matching every option given, in whatever order the client holds them. With no options, all of them.
| Parameter | Type | What it does |
| idoptional |
int |
the item id from the cache, not the server index |
| nameoptional |
string |
the whole name, ignoring case |
| nameContainsoptional |
string |
part of the name, ignoring case |
| withinoptional |
int |
how many tiles away at most, straight line |
| areaoptional |
area |
must be standing inside this area |
Example
for loot in drops(within: 6) { walkTo(loot.tile) }
dropsByDistance
returns list<drop>
dropsByDistance(id: int, name: string, nameContains: string, within: int, area: area) -> list<drop>
Every drop matching every option given, closest first.
| Parameter | Type | What it does |
| idoptional |
int |
the item id from the cache, not the server index |
| nameoptional |
string |
the whole name, ignoring case |
| nameContainsoptional |
string |
part of the name, ignoring case |
| withinoptional |
int |
how many tiles away at most, straight line |
| areaoptional |
area |
must be standing inside this area |
Example
for loot in dropsByDistance(name: "Bones", within: 12) { walkTo(loot.tile) }
nearestDrop
returns drop?
nearestDrop(id: int, name: string, nameContains: string, within: int, area: area) -> drop?
The closest drop matching every option given, or none. Distance is straight-line from where you are standing, measured in the same reading the drop was read from.
| Parameter | Type | What it does |
| idoptional |
int |
the item id from the cache, not the server index |
| nameoptional |
string |
the whole name, ignoring case |
| nameContainsoptional |
string |
part of the name, ignoring case |
| withinoptional |
int |
how many tiles away at most, straight line |
| areaoptional |
area |
must be standing inside this area |
Example
let loot = nearestDrop(name: "Coins", within: 10)
No command on this page matches that. The search box looks across every page.