跳转至

BinderTag

  • 种类: class
  • 命名空间: Runestone.AesirModules
  • 程序集: Runestone.AesirModules.OdinInspector

继承链: System.Object → UnityEngine.Object → UnityEngine.Component → UnityEngine.Behaviour → UnityEngine.MonoBehaviour → Sirenix.OdinInspector.SerializedMonoBehaviour → Runestone.AesirArchitecture.AesirMonoBehaviour → BinderTag

实现接口: Sirenix.Serialization.ISupportsPrefabSerialization,UnityEngine.ISerializationCallbackReceiver

声明

[DisallowMultipleComponent]
public class BinderTag : Runestone.AesirArchitecture.AesirMonoBehaviour, 
Sirenix.Serialization.ISupportsPrefabSerialization, 
UnityEngine.ISerializationCallbackReceiver

Binder 标签组件。挂载在需要自动绑定引用的子物体上,标记该物体可被 BinderAssistant 扫描并生成绑定信息。 一个物体上可绑定多个不同类型的组件,通过 ComponentNumber 指定数量。

构造方法

名称 描述
BinderTag() —

BinderTag()

public BinderTag()

属性

声明的属性

名称 描述
SelfObj 当前物体引用
Types 当前物体上可绑定的组件类型集合(含 GameObject 自身)。 排除 Missing 脚本组件(GetComponents{T} 对其返回 null 元素, 放行会在 GetType() 时抛空引用)与 BinderTag 自身,避免将标记组件或悬空脚本纳入绑定选项。
ComponentNumber 当前物体上需要绑定的组件数量。BinderAssistant 据此为每个组件生成一条 BinderInfo。
HierarchyPath —

继承的属性

名称 描述 声明类型
destroyCancellationToken — MonoBehaviour
gameObject — Component
hideFlags — Object
transform — Component
enabled — Behaviour
isActiveAndEnabled — Behaviour
runInEditMode — MonoBehaviour
useGUILayout — MonoBehaviour
name — Object
tag — Component
animation — Component
audio — Component
camera — Component
collider — Component
collider2D — Component
constantForce — Component
hingeJoint — Component
light — Component
networkView — Component
particleSystem — Component
renderer — Component
rigidbody — Component
rigidbody2D — Component

SelfObj

当前物体引用

public GameObject SelfObj { get; }

Types

当前物体上可绑定的组件类型集合(含 GameObject 自身)。 排除 Missing 脚本组件(GetComponents{T} 对其返回 null 元素, 放行会在 GetType() 时抛空引用)与 BinderTag 自身,避免将标记组件或悬空脚本纳入绑定选项。

public IEnumerable<Type> Types { get; }

ComponentNumber

当前物体上需要绑定的组件数量。BinderAssistant 据此为每个组件生成一条 BinderInfo。

[ShowInInspector]
[LabelText]
[PropertyRange]
public int ComponentNumber { get; set; }

HierarchyPath

public string HierarchyPath { get; }

方法

名称 描述 声明类型
GetComponent(Type) — Component
GetComponent(string) — Component
GetComponentInChildren(Type) — Component
GetComponentInChildren(Type, bool) — Component
GetComponentInParent(Type) — Component
GetComponentInParent(Type, bool) — Component
GetComponents(Type) — Component
GetComponentsInChildren(Type) — Component
GetComponentsInChildren(Type, bool) — Component
GetComponentsInParent(Type) — Component
GetComponentsInParent(Type, bool) — Component
StartCoroutine(IEnumerator) — MonoBehaviour
StartCoroutine(string) — MonoBehaviour
StartCoroutine(string, object) — MonoBehaviour
GetComponent() — Component
GetComponentInChildren() — Component
GetComponentInChildren(bool) — Component
GetComponentInParent() — Component
GetComponentInParent(bool) — Component
GetComponents() — Component
GetComponentsInChildren() — Component
GetComponentsInChildren(bool) — Component
GetComponentsInParent() — Component
GetComponentsInParent(bool) — Component
GetType() — object
CompareTag(string) — Component
IsInvoking() — MonoBehaviour
IsInvoking(string) — MonoBehaviour
TryGetComponent(Type, ref Component) — Component
TryGetComponent(ref T) — Component
GetComponentIndex() — Component
GetInstanceID() — Object
Equals(object) — Object
GetHashCode() — Object
ToString() — Object
BroadcastMessage(string) — Component
BroadcastMessage(string, SendMessageOptions) — Component
BroadcastMessage(string, object) — Component
BroadcastMessage(string, object, SendMessageOptions) — Component
CancelInvoke() — MonoBehaviour
CancelInvoke(string) — MonoBehaviour
GetComponents(Type, List<Component>) — Component
GetComponents(List<T>) — Component
GetComponentsInChildren(List<T>) — Component
GetComponentsInChildren(bool, List<T>) — Component
GetComponentsInParent(bool, List<T>) — Component
Invoke(string, float) — MonoBehaviour
InvokeRepeating(string, float, float) — MonoBehaviour
SendMessage(string) — Component
SendMessage(string, SendMessageOptions) — Component
SendMessage(string, object) — Component
SendMessage(string, object, SendMessageOptions) — Component
SendMessageUpwards(string) — Component
SendMessageUpwards(string, SendMessageOptions) — Component
SendMessageUpwards(string, object) — Component
SendMessageUpwards(string, object, SendMessageOptions) — Component
StopAllCoroutines() — MonoBehaviour
StopCoroutine(Coroutine) — MonoBehaviour
StopCoroutine(IEnumerator) — MonoBehaviour
StopCoroutine(string) — MonoBehaviour
MemberwiseClone() — object
Finalize() — object
OnAfterDeserialize() — SerializedMonoBehaviour
OnBeforeSerialize() — SerializedMonoBehaviour
StartCoroutine_Auto(IEnumerator) — MonoBehaviour

Additional Notes

首个 ## Additional Notes 是增量生成文档标识符,请勿修改标题级别和内容!本文档由 Script Doc Generator 辅助生成。