fluffos/docs/apply/interactive/process_input.md

29 lines
760 B
Markdown
Raw Permalink Normal View History

2018-12-30 16:43:04 -08:00
---
title: interactive / process_input
---
2023-11-25 09:50:24 -08:00
# process_input
2018-12-30 16:43:04 -08:00
### NAME
2018-12-30 16:59:01 -08:00
process_input() - provide a hook for the driver to send a copy of what the
player is typing to the player object.
2018-12-30 16:43:04 -08:00
### SYNOPSIS
2018-12-30 16:59:01 -08:00
string process_input( string );
2018-12-30 16:43:04 -08:00
### DESCRIPTION
2018-12-30 16:59:01 -08:00
2018-12-30 16:43:04 -08:00
If process_input is present in the player object, then the MudOS driver
parser will send it a copy of each line the player types.
Process_input makes it easy to implement features like command history
and protection against wizcuffs. process_input can also modify the
player input before it is parsed. If process_input returns a non-zero
string, that string is used by the driver instead of what the player
typed.
### AUTHOR
2018-12-30 16:59:01 -08:00
Truilkan@TMI