> For the complete documentation index, see [llms.txt](https://raster.gitbook.io/zh-hans_choicescript-guide/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://raster.gitbook.io/zh-hans_choicescript-guide/input-text.md).

# Input text

The ***input\_text*** command is used for displaying a text box that allows the player to type in some English alphanumeric characters. It is commonly used to allow the player to input a name for their character.\
*input\_text 命令用于显示一个文本框，允许玩家输入一些英文字母和数字字符。它通常用于让玩家为他们的角色输入一个名字。*

### Usage 用法

In order to use this command, you must [create](https://choicescriptdev.fandom.com/wiki/Create) a string variable in [startup.txt](https://choicescriptdev.fandom.com/wiki/Startup.txt) (or create a [\*temp](https://choicescriptdev.fandom.com/wiki/Temp) (temporary) variable in the [scene](https://choicescriptdev.fandom.com/wiki/Scenes) file) to be modified by the player's input.\
为了使用此命令，你必须在 startup.txt 中 \*创建一个字符串变量（或在场景文件中创建一个 \*temp（临时）变量），以便由玩家的输入进行修改。

```choicescript
*temp first_name ""

What is your name?

*input_text first_name
```

In this case, the player's input is being saved to a "string" (textual) [variable](https://choicescriptdev.fandom.com/wiki/Variable_types) called "first\_name", allowing it to be used in the story as required, such as displaying on the Stats screen, or spoken by another character when addressing the player-character.\
在这种情况下，玩家的输入被保存到一个名为 "first\_name" 的 "字符串"（文本）变量中，允许在故事中按需使用它，例如在状态屏幕上显示，或由其他角色在称呼玩家角色时说出。
