Using Microsoft Agent
Let's quickly review how to manipulate Microsoft Agent with this printer-friendly rundown:
- To 'initialise' your Agent character:
Dim Assistant As IAgentCtlCharacterExAgentControlOnForm.Characters.Load "Assistant"Set Assistant = Agent1.Characters("Assistant")
- To show or hide your Agent character:
Assistant.ShowAssistant.Hide
- To make your Agent character talk:
Assistant.Speak ("Speech Text Goes Here")
- To make your Agent character think:
Assistant.Think ("Think Text Goes Here")
- To animate your character:
Assistant.Play("AnimationName")
- To find out what animations your character is capable of:
Dim Animation As VariantFor Each Animation In Assistant.AnimationNames MsgBox AnimationNext
- To place emphasis on a particular word:
Assistant.Speak ("He is bad. \emp\Very bad.")
- To whisper a sentence:
Assistant.Speak ("\Chr=""Whisper""\But don't tell him I told you!")
Page 6 of 7
This article was originally published on November 20, 2002