用户工具

站点工具


侧边栏



Unity3D中文文档

script:unityengine:classes:textasset:textasset

TextAsset 文本资源

Namespace: UnityEngine / Inherits from: Object

Description 描述

Text file assets.

文本文件资源。

You can use raw text files in your project as assets and get their contents through this class. Also, you can access the file as a raw byte array if you want to access data from binary files. See the Text Asset manual page for further details about importing text and binary files into your project as Text Assets.

在你的项目里,你可以使用原始的文本文件作为资源,可以通过该类获取它们的内容。同时,如果你想访问二进制数据文件,你能访问这个文件作为原始字节数组。参见资源手册页面了解文本资源和二进制文件的进一步信息。

Variables 变量

bytesThe raw bytes of the text asset. (Read Only)
该文本资源的原始字节。(只读)
textThe text contents of the .txt file as a string. (Read Only)
该.txt文件的文本内容作为字符串。(只读)
script/unityengine/classes/textasset/textasset.txt · 最后更改: 2016/08/02 05:35 (外部编辑)