Key Condition

Definition: The Key condition checks if the key displayed in its Key parameter is pressed.

If the key indicated is pressed, the condition is true. Otherwise, the condition is false.

The Key condition can be used to assign real-time control characters on the keyboard. You might also use it to assign "hot key" values to get agents to act out specified actions. To get Key conditions to function as hot keys you will have to place them in rules in a method that is checked at every simulation cycle.

Parameters: key
Example: The Cursor agent in the ABC project detects key strokes and types the corresponding letter. For example, if the A key is pressed on the keyboard, the Cursor will create a Character A agent, advance to the right, and identify the newly created character.

See the ABC simulation.

| Next | Previous | Reference Manual | Getting Started Manual |