GFHitBoxState3D¶
API Reference / Combat / 类索引
- 路径:
addons/gf/extensions/combat/hit_detection/gf_hit_box_state_3d.gd - 模块:
Combat - 继承:
Node3D - API:
public - 类别:运行时句柄 (
runtime_handle) - 首次版本:
3.17.0
3D 命中区域状态组。 统一启停子树内的 GFHitBox3D、GFHurtBox3D 与 Area3D,不处理伤害、阵营或技能规则。
成员概览¶
| 类型 | 名称 | 签名 |
|---|---|---|
| 信号 | active_changed |
signal active_changed(active: bool) |
| 属性 | active |
var active: bool = true: |
| 属性 | apply_on_ready |
var apply_on_ready: bool = true |
| 属性 | recursive |
var recursive: bool = true |
| 属性 | manage_enabled |
var manage_enabled: bool = true |
| 属性 | manage_monitoring |
var manage_monitoring: bool = true |
| 属性 | manage_visibility |
var manage_visibility: bool = false |
| 方法 | activate |
func activate() -> void: |
| 方法 | deactivate |
func deactivate() -> void: |
| 方法 | set_active_state |
func set_active_state(value: bool) -> void: |
| 方法 | apply_state |
func apply_state() -> void: |
| 方法 | get_managed_nodes |
func get_managed_nodes() -> Array[Node]: |
信号¶
active_changed¶
- API:
public
状态应用后发出。
参数:
| 名称 | 说明 |
|---|---|
active |
当前是否激活。 |
属性¶
active¶
- API:
public
当前状态是否激活。
apply_on_ready¶
- API:
public
是否在 _ready() 时应用当前状态。
recursive¶
- API:
public
是否递归管理子节点。
manage_enabled¶
- API:
public
是否同步 GFHitBox3D/GFHurtBox3D 的 enabled 字段。
manage_monitoring¶
- API:
public
是否同步 Area3D 的 monitoring 与 monitorable。
manage_visibility¶
- API:
public
是否同步 Node3D.visible。
方法¶
activate¶
- API:
public
激活状态组。
deactivate¶
- API:
public
关闭状态组。
set_active_state¶
- API:
public
设置状态组激活状态。
参数:
| 名称 | 说明 |
|---|---|
value |
是否激活。 |
apply_state¶
- API:
public
应用当前状态到所有受管理节点。
get_managed_nodes¶
- API:
public
获取受管理节点列表。
返回:节点列表。