I'm trying to write a script for a game of mine

Let's say I'm playing (in a game or somewhere), I'd like my character to say ''Please do A'' if I type .A (or press a key) or say ''Please do B'' if I type .B (or press a key).
I can't seem to find anything for that.
If you need more explanation on this, please PM me so we can discuss it furthermore

tl;dr what's the command used to say something triggered by me typing something or pressing a button.
This post was edited by Hylia on Jun 27 2012 02:04am