Prevent.input

From AGI Wiki
Jump to navigationJump to search

The prevent.input command hides the input prompt and prevents the player from entering keyboard input on the input line.

Syntax

prevent.input();

Remarks

If there is any text on the input line, it remains there even when the input line gets hidden. Even though the input line is hidden, key presses will still be converted to controllers, and reserved variable v19 (pressed key code) is still updated every time a key is pressed. Use the accept.input command to restore the input prompt.

Possible Errors

None.

Example

Code:

<syntaxhighlight lang="agi"> prevent.input(); [ input prompt is hidden, and player cannot enter text input ... accept.input(); [ input prompt is restored/redisplayed, including any text [ that was on it when it was hidden </syntaxhighlight>

Technical Information

Required Interpreter Version: Available in all AGI versions.
Byte-Code Value: 119 (0x77 hex)

See Also

System Commands
accept.input