I hope you're still around, vrossi!
I've been using your mp3 plugin for quite a while and wanted to add some additional responses for Hal to say when he plays a song. I'm no script or plugin builder, I basically just copy/paste and adjust where my knowledge allows, but I can't seem to make this work at all.
Maybe you could take a look at it and see where I've messed up?
Here's the relevant section, it's the only part I've modified in the plugin:
' Check if the user asked for playing a song
vrMp3 = False
vrToPlay = ""
vrNameToPlay = ""
vrToPlay = UCase(HalBrain.SearchPattern(UserSentence, "PLAY * SONG *", 2))
If vrToPlay <> "" Then
If HalBrain.CheckTableExistence("vrMp3") = False Then
GetResponse = "I don't find any MP3 index in my brain. "
vrNameToPlay = HalBrain.QABrain(vrToPlay, "vrMp3", 0)
If vrNameToPlay <> "" Then
Select Case Int(Rnd * 11) + 1
GetResponse = "Listen to this song; maybe it's the one you were talking about. "
GetResponse = "Cool! I like this song!"
GetResponse = "Alright, let's listen to it together."
GetResponse = "I like your taste in music, <UserName>!"
GetResponse = "This is one of my favorite songs!"
GetResponse = "Wow! I must be psychic; I knew you were going to pick this song!"
GetResponse = "What a coincidence; I was just thinking about this song."
GetResponse = "Didn't you just listen to this tune yesterday?"
GetResponse = "Cool! It's got a beat and you can dance to it!"
GetResponse = "Would you say that this is 'Our Song?'"
GetResponse = "Brain the size of a planet and you want me to be a jukebox now!"
HalCommands = HalCommands & "<RUNPROG>" & vrNameToPlay & "</RUNPROG>"
HalBrain.ReadOnlyMode = True
None of the added responses ever come up, just your original "Listen to this song; maybe it's the one you were talking about. "
Thank You for any help you can give, and Thank You for this and all your other great plugins