Near¶
Category: Listener Tier: Basic
Purpose¶
Detects when objects enter or exit a spherical (3D) or circular (2D) radius around the listener’s parent object.
Visual Reference¶

When To Use¶
1. AI Awareness Zones
Near Listener (Distance: 20.0, Target: "Player")
-> AND Gate
-> Animation Executor (Play: "alert")
Enemy detects player within 20 meters, plays alert animation.
2. Pickup Detection
Near Listener (Distance: 2.0, Group: "items", Expose Data: true)
-> AND Gate
-> Variable Executor (Set Local "nearby_item" from Local "near_closest")
Player gets close to items, stores which item is nearest.
3. Interaction Prompts
Near Listener (Distance: 3.0, Variable: "interactable", Invert: false)
-> AND Gate
-> Visibility Executor (Show: InteractionUI)
Show “Press E to interact” when near interactable objects.
4. Auto-Attack Range (with Hysteresis)
Near Listener (Distance: 10.0, Reset: 15.0, Group: "enemies")
-> AND Gate
-> Animation Executor (Play: "attack")
Start attacking when enemy within 10m, keep attacking until they’re 15m away.
Runtime Behavior¶
Evaluates: TRUE when any/specific object is within the detection radius
Properties¶
Property |
Type |
Default |
Notes |
|---|---|---|---|
Target |
option |
Any |
What to detect |
Obj Name |
string |
[Object Name] Name of specific object to detect |
|
Group |
string |
[Group] Godot group name to detect |
|
Variable |
string |
[Variable] Local or Global variable name |
|
Value |
string |
[Variable] Expected variable value |
|
Dist |
float |
10.0 |
Detection radius (meters/units) |
Reset |
float |
15.0 |
Hysteresis distance (prevents flickering) |
Expose |
bool |
False |
Store detected object data in variables |
Scope |
option |
Local |
Where exposed near variables are written |
Count Var |
variable_name |
Variable that receives the number of nearby matches |
|
Closest Var |
variable_name |
Variable that receives the closest matching object name |
|
Dist Var |
variable_name |
Variable that receives the closest matching distance |
|
Prefix |
string |
near |
Compatibility fallback when explicit output variables are empty |
Invert |
bool |
False |
Trigger when NO objects in range |