entity.find_nearby
Overview
- [deprecated] Use entity.scan_characters instead.
Metadata
| Field | Value |
|---|---|
| Display | Find Nearby (→ scan_characters) |
| Category | entity |
| Access | Public |
| Scope | B1Standalone |
| Tags | — |
| Aliases | — |
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| radius | float | no | — | Search radius in meters (default 100) |
Returns
Returns a JSON object with the following fields:
| Field | Type | Required | Description |
|---|---|---|---|
ref | string | yes | Reference direction used (camera/pawn) |
radius | float | yes | Search radius in meters |
count | int | yes | Number of characters returned |
characters | array | yes | Nearby characters |
characters[].entity_id | entityId | yes | Character entity id |
characters[].first_name | string | yes | First name |
characters[].last_name | string | yes | Last name |
characters[].gender | string | yes | Gender enum name (Male/Female) |
characters[].gender_text | string | yes | Localized gender label |
characters[].age_group | string | yes | Growth step name |
characters[].age_group_text | string | yes | Localized age group label |
characters[].portrait_url | string | yes | Cached portrait url |
characters[].distance | float | yes | Distance in meters |
characters[].angle | float | yes | Signed angle in degrees (-left/+right) |
characters[].direction | string | yes | Direction label (front/behind/left/right) |
Usage
await inzoi.cli.execute('entity.find_nearby', {
radius: 0.0, // optional
});