Optionaloptions: EntityQueryOptionsAdditional options that can be used to filter the set of entities returned.
An entity array.
Returns a set of entities based on a set of conditions defined via the EntityQueryOptions set of filter criteria.
const query = {
type: "item",
location: targetLocation,
};
const items = overworld.getEntities(query);
for (const item of items) {
const itemComp = item.getComponent("item") as any;
if (itemComp) {
if (itemComp.itemStack.id.endsWith("feather")) {
console.log("Success! Found a feather", 1);
}
}
}
Optionaloptions: EntityQueryOptionsAdditional options that can be used to filter the set of players returned.
A player array.
This function can't be called in read-only mode.
Command to run. Note that command strings should not start with slash.
For commands that return data, returns a CommandResult with an indicator of command results.
A class that represents a particular dimension (e.g., The End) within a world.