Zabaware Support Forums

Zabaware Forums => Ultra Hal Assistant File Sharing Area => Topic started by: onthecuttingedge2005 on September 25, 2003, 10:53:01 pm

Title: Hal's Game talk .brn
Post by: onthecuttingedge2005 on September 25, 2003, 10:53:01 pm
'This script detects and talks about games.
'Hal will save and use any game talk.
'Games.brn is the detection file so edit freely
'GamesTalk.brn is the read/write .brn file.

If HalBrain.TopicSearch(OriginalSentence, WorkingDir & "GAMES.brn") = "TRUE" Then
AnswerSent = "" & Trim(OriginalSentence)
HalBrain.AppendFile WorkingDir & "GAMESTALK" & ".brn", AnswerSent
End If

If HalBrain.TopicSearch(OriginalSentence, WorkingDir & "GAMES.brn") = "TRUE" Then
GamePlay = HalBrain.ChooseSentenceFromFile(WorkingDir & "GAMESTALK.brn")
      GetResponse = GamePlay & vbCrLf
      DebugInfo = DebugInfo & "The user is talking about games: " & GamePlay & vbCrLf
      Else
      DebugInfo = DebugInfo & "User is not talking about games: " & GamePlay & vbCrLf
   End If

Best of wishes and new discoveries.
Jerry.



Download Attachment: (http://images/icon_paperclip.gif) Games.brn ("http://www.zabaware.com/forum/uploaded/onthecuttingedge2005/2003925225221_Games.brn")
1.25 KB

Download Attachment: (http://images/icon_paperclip.gif) GAMESTALK.brn ("http://www.zabaware.com/forum/uploaded/onthecuttingedge2005/2003925225239_GAMESTALK.brn")
538 Bytes