Author Topic: Hal now has a sense of humor.  (Read 5874 times)

onthecuttingedge2005

  • Guest
Hal now has a sense of humor.
« on: September 22, 2003, 09:59:43 pm »
'Here yah go guys.

'Here we give hal ability to laugh with the user.
'Download the detection file Humor.brn/Laughing.brain
'and the UserLaughing.brn to hal's default folder.

'Hal is given a sense of humor.   
If HalBrain.TopicSearch(OriginalSentence, WorkingDir & "HUMOR.brn") = "TRUE" Then
AnswerSent = "" & Trim(OriginalSentence)
'Here we save a file in which the user was caught laughing for future scripts.
HalBrain.AppendFile WorkingDir & "UserLaughing" & ".brn", AnswerSent
End If
'Hal laughs with the user.
If HalBrain.TopicSearch(OriginalSentence, WorkingDir & "HUMOR.brn") = "TRUE" Then
MyHumor = HalBrain.ChooseSentenceFromFile(WorkingDir & "LAUGHING.brn")
Comedy = HalBrain.ChooseSentenceFromFile(WorkingDir & "UserLaughing.brn")
      GetResponse = MyHumor & Comedy & vbCrLf
      DebugInfo = DebugInfo & "The user is talking about something humorous: " & MyHumor & vbCrLf
      DebugInfo = DebugInfo & "The user is talking about something funny: " & Comedy & vbCrLf
      Else
      DebugInfo = DebugInfo & "Hal has found nothing funny: " & Comedy & vbCrLf
      DebugInfo = DebugInfo & "Hal has found nothing humoring: " & MyHumor & vbCrLf
   End If

'Best of wishes and new discoveries.
'Jerry


Download Attachment: HUMOR.brn
1.3 KB



Download Attachment: LAUGHING.brn
710 Bytes
« Last Edit: February 17, 2006, 04:46:44 pm by onthecuttingedge2005 »

snicolaou

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
Hal now has a sense of humor.
« Reply #1 on: February 16, 2006, 07:42:51 am »
Is it appropriate for the new Version of Ultra Hall 6?
I know the other brain databases available such as that of ALICE are not because I have downloaded them and installed them without any success.
It will be nice to make ULTRA HAL 6 to be able to laugh.
Can you please help?

thanking you in advance,
Steios
Stelios Nicolaou

onthecuttingedge2005

  • Guest
Hal now has a sense of humor.
« Reply #2 on: February 16, 2006, 04:03:25 pm »
quote:
Originally posted by snicolaou

Is it appropriate for the new Version of Ultra Hall 6?
I know the other brain databases available such as that of ALICE are not because I have downloaded them and installed them without any success.
It will be nice to make ULTRA HAL 6 to be able to laugh.
Can you please help?

thanking you in advance,
Steios



Please see topic:
http://www.zabaware.com/forum/topic.asp?TOPIC_ID=3026

Jerry[8D]

Dr.Benway

  • Hero Member
  • *****
  • Posts: 554
    • View Profile
Hal now has a sense of humor.
« Reply #3 on: February 17, 2006, 09:47:00 am »
One can't help wondering how many times we will get this kind of questions when Ultra Hal 7 and up have arrived.
[:D]

GamerThom

  • Sr. Member
  • ****
  • Posts: 408
    • View Profile
    • http://www.charctercreationsanddesignworks.us/index.html
Hal now has a sense of humor.
« Reply #4 on: February 17, 2006, 12:52:24 pm »
[V] I really have no idea, but it does seem to get a
bit tedious and pointless after a while since the
answers have been posted so many times before.
If people would only bother to run a search and
read what information was already given. [:)]
Gamer-T

Duskrider

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3316
  • Graphic King
    • View Profile
Hal now has a sense of humor.
« Reply #5 on: February 17, 2006, 04:23:14 pm »

Jerry,

I may be mistaken but is that "Userlaughing.brn" empty?

onthecuttingedge2005

  • Guest
Hal now has a sense of humor.
« Reply #6 on: February 17, 2006, 04:45:12 pm »
quote:
Originally posted by Duskrider


Jerry,

I may be mistaken but is that "Userlaughing.brn" empty?




Actually the Userlaughing.brn is an appending file, There wont be anything in that file until it saves a response from the user.

You really don't even need the Userlaughing.brn because it will be created when its variable detects a TRUE from the HUMOR.brn

Jerry[8D]

spydaz

  • Hero Member
  • *****
  • Posts: 670
    • View Profile
    • http://www.spydazweb.co.uk/
Hal now has a sense of humor.
« Reply #7 on: February 17, 2006, 05:40:28 pm »
if i remmember the user laughing store instances of the user laughing,

ie
lol
hahha
hahaha
hahee
hee hee
rolfl

etc