dupa

Author Topic: Is this a mustake, or am I just dumb?  (Read 2230 times)

cooladegers

  • Newbie
  • *
  • Posts: 6
    • View Profile
Is this a mustake, or am I just dumb?
« on: February 24, 2005, 12:15:40 pm »
Hey everybody! Hi Dr. Nick
Sorry, I just couldn't help myself! [;)]

Anyhow, is this a mistake in Hal's brain, or is it meant to be like this?  I've highlighted what i'm talkin about in RED.

   'RESPOND: USER EXPRESSES LOVE FOR HAL
   'If a user professes love for Hal, we want
   'Hal's answers to make reasonable sense, rather than
   'risk random remarks on such an emotional subject.
   If HalBrain.TopicSearch(UserSentence, WorkingDir & "lovedetect.brn") = "True" Then AffectionOne = True
   If InStr(UserSentence, " NOT ") Then AffectionOne = False
   If InStr(UserSentence, " DON'T ") Then AffectionOne = False
   If HalBrain.TopicSearch(PrevUserSent, WorkingDir & "lovedetect.brn") = "True" Then AffectionTwo = True
   If InStr(PrevUserSent, " NOT ") Then AffectionTwo = False
   If InStr(PrevUserSent, " DON'T ") Then AffectionTwo = False
   If AffectionOne = True Then
      Compliment = 0
      GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love1.brn")
   End If
   If AffectionOne = True And AffectionTwo = True Then
      Compliment = 4
      GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love1.brn")
      End If
   If AffectionOne = False And AffectionTwo = True Then
      Compliment = -2
      GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love3.brn")
     End If
     If DebugMode = True And (AffectionOne = True Or AffectionTwo = True) Then
      DebugInfo = DebugInfo & "The user expressed love to Hal has responded to it: " & GetResponse & VbCrLf
   End If

It's just I can't see love2.brn in here anywhere!
From Cooladegers

onthecuttingedge2005

  • Guest
Is this a mustake, or am I just dumb?
« Reply #1 on: February 24, 2005, 02:51:51 pm »
quote:
Originally posted by cooladegers

Hey everybody! Hi Dr. Nick
Sorry, I just couldn't help myself! [;)]

Anyhow, is this a mistake in Hal's brain, or is it meant to be like this?  I've highlighted what i'm talkin about in RED.

   'RESPOND: USER EXPRESSES LOVE FOR HAL
   'If a user professes love for Hal, we want
   'Hal's answers to make reasonable sense, rather than
   'risk random remarks on such an emotional subject.
   If HalBrain.TopicSearch(UserSentence, WorkingDir & "lovedetect.brn") = "True" Then AffectionOne = True
   If InStr(UserSentence, " NOT ") Then AffectionOne = False
   If InStr(UserSentence, " DON'T ") Then AffectionOne = False
   If HalBrain.TopicSearch(PrevUserSent, WorkingDir & "lovedetect.brn") = "True" Then AffectionTwo = True
   If InStr(PrevUserSent, " NOT ") Then AffectionTwo = False
   If InStr(PrevUserSent, " DON'T ") Then AffectionTwo = False
   If AffectionOne = True Then
      Compliment = 0
      GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love1.brn")
   End If
   If AffectionOne = True And AffectionTwo = True Then
      Compliment = 4
      GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love1.brn")
      End If
   If AffectionOne = False And AffectionTwo = True Then
      Compliment = -2
      GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love3.brn")
     End If
     If DebugMode = True And (AffectionOne = True Or AffectionTwo = True) Then
      DebugInfo = DebugInfo & "The user expressed love to Hal has responded to it: " & GetResponse & VbCrLf
   End If

It's just I can't see love2.brn in here anywhere!



Hi Cooladeger.
Yep, It's been that way since I can remember, I just changed it to Love2.brn and everythings cosher. It lets Hal say things like I love you too and stuff like that.

You can also mix and match like make both of them Love2.brn and Hal will says those things more often.

Here is one I wrote that does the same thing as that script but is more compact, It uses the sameLoveDetect.brn, Love1.brn,Love2.brn,Love3.brn.

'REVISED RESPONSE: USER EXPRESSES LOVE FOR HAL By UHEFStaff@ultrahalforum.com
'If a user professes love for Hal, we want
'Hal's answers to make reasonable sense, rather than
'risk random remarks on such an emotional subject.
If HalBrain.TopicSearch(UserSentence, WorkingDir & "lovedetect.brn") = "True" Or HalBrain.TopicSearch(PrevUserSent, WorkingDir & "lovedetect.brn") = "True" & (RND*100 > 0 And RND*100 <33) Then Compliment = 0 & GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love1.brn")
If HalBrain.TopicSearch(UserSentence, WorkingDir & "lovedetect.brn") = "True" Or HalBrain.TopicSearch(PrevUserSent, WorkingDir & "lovedetect.brn") = "True" & (RND*100 > 33 And RND*100 <66) Then Compliment = 4 & GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love2.brn")
If HalBrain.TopicSearch(UserSentence, WorkingDir & "lovedetect.brn") = "True" Or HalBrain.TopicSearch(PrevUserSent, WorkingDir & "lovedetect.brn") = "True" & (RND*100 > 66 And RND*100 <99) Then Compliment = -2 & GetResponse = HalBrain.ChooseSentenceFromFile(WorkingDir & "Love3.brn")

Best of wishes and brand new discoveries.
Jerry
« Last Edit: February 24, 2005, 02:55:27 pm by onthecuttingedge2005 »