Represents a raw text or binary file asset.
You can use raw text files in your project as assets and get their contents through
this class. For more information, see text.
You can access the file as a raw byte array to access data from binary files. For more
information on how to access data from binary files, see bytes and GetData.
For more information about importing text or binary files into your project as Text Assets,
see Text Asset.
bytes | 文本资源的原始字节。(只读) |
dataSize | The size of the text asset data in bytes. (Read Only) |
text | The text contents of the file as a string. (Read Only) |
TextAsset | 使用指定文本内容创建一个新 TextAsset。此构造函数创建 TextAsset,它与纯文本文件不同。当使用 AssetDatabase 类保存到磁盘时,应使用 .asset 扩展名保存 TextAsset。 |
GetInstanceID | Gets the instance ID of the object. |
Destroy | 移除 GameObject、组件或资源。 |
DestroyImmediate | 立即销毁对象 /obj/。强烈建议您改用 Destroy。 |
DontDestroyOnLoad | 在加载新的 Scene 时,请勿销毁 Object。 |
FindAnyObjectByType | Retrieves any active loaded object of Type type. |
FindFirstObjectByType | Retrieves the first active loaded object of Type type. |
FindObjectOfType | 返回第一个类型为 type 的已加载的激活对象。 |
FindObjectsByType | Retrieves a list of all loaded objects of Type type. |
FindObjectsOfType | Gets a list of all loaded objects of Type type. |
Instantiate | 克隆 original 对象并返回克隆对象。 |
bool | 该对象是否存在? |
operator != | 比较两个对象是否引用不同的对象。 |
operator == | 比较两个对象引用,判断它们是否引用同一个对象。 |