quote:
Originally posted by markofkane
Ok, how do you make Hal 6 respond to certain words??(actions, and/or verbal responses)
What is the
code, and where in the brain editor does it go?? I know nothing about scripting. Thanks!!
Markofkane,
I'll post a very simple example and try to tell you how to adapt it to your needs.
Look near the bottom of the hal6.uhp file and you'll see some code that looks like this....
Rem PLUGIN: CUSTOMMEM2
'The preceding comment is actually a plug-in directive for
'the Ultra Hal host application. It allows for code snippets
'to be inserted here on-the-fly based on user configuration.
End Function
To make Hal respond to a certain word you tell it, place the
following code just before the "End Function" line and see if
it works.
If InStr(1, UserSentence, "MarkOfKane", 1) > 0 Then
GetResponse = "Your sentence had the word MarkOfKane in it."
In this example, Hal should respond with ...
Your sentence had the word MarkOfKane in it.
Every time Hal sees the word MarkOfKane in it.
You are free to change the text inside the " " to whatever you want.
Just be careful that you don't change the keyword in the quotes to
some common word or hal will be responding with this code alot.
If you have more questions, post em and if I can't answer them, maybe someone else can.