dupa

Author Topic: hapswap problems  (Read 43331 times)

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« on: November 02, 2009, 06:41:18 pm »
snowman i started a question actually in the wrong place (general area ) about this . i redid some of the responses in the hapswap file you sent me i now have it working ok some of the time seems like it doesn't like long names example : emilyblondlightspeed

it will do short names though , is their a limit on letters of the name ? wouldn't think so .

i did get it to change the back ground a few times to am having trouble with that part to .
does it matter where i have the hapswap file ? i have it in the hal ultra assistant 6  file right now .

i like how this works if i can get the bugs out of it !
[:)]

 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #1 on: November 02, 2009, 06:53:16 pm »
well i have checked and shortened the name and that is making the characters load (the only reason i had such long names was character name hair color and my name and or others for credit of characters . which was ok before but causes problems in the swaphap file . now if i can get the backgrounds to change easily i will have it made
 

snowman

  • Hero Member
  • *****
  • Posts: 956
  • Ai + Feelings + Supercompter = End of World
    • View Profile
    • http://www.MinervaAi.com
hapswap problems
« Reply #2 on: November 02, 2009, 08:22:36 pm »

I found the hap.zp you were asking about... just in case you haven't found it yet.

Download Attachment: Haps.zip
3.13 KB

If you want me to proof read it you can send it to my email or post it here.

I wanted you to work on hapswap because your strength is in your creativity. Plus your so nice that I wanted to work with you. That's the honest truth. Your not stupid or dumb because people who are mean to each other they are stupid... they have the real affliction, and I feel sorry for them.



Live long and prosper or die trying.

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #3 on: November 02, 2009, 10:20:08 pm »
thanks snowman for the file (i hadn't found it yet ) and for the nice words .
i am working on the problem of changing the background it may be the same problem i had with the names  apparently if the name is to long it will not load so i will try a short name back ground and see if that works .
by the way here is the new hapswap i changed the responses to sound better hope you don't mind .

you can look at your original responses to see what the differences are .




Rem Type=Plugin
Rem Name=HapSwap
Rem Author=SNOWMAN, APOLLON , partially redone by lightspeed
Rem Host=Assistant

'This sub setups the plug-ins option panel in Hal's options dialog
Sub OptionsPanel()
    lblPlugin(0).Caption = "Say:: <change background to [whatever]> to change between pictures in the characters folder, Say:: <change charater to [whatever]> to change between Haptar characters, Say:: <change voice to [Paul] or [Kate]> to change between thier voices. Say:: <change hap to [whatever]> to change between hap files. All other guesture responses are set to automaically occur to user input."
    lblPlugin(0).Move 120, 10, 3300, 1000
    lblPlugin(0).WordWrap = True
    lblPlugin(0).Visible = True
End Sub
'***************************************************************************
'***************************************************************************
Rem PLUGIN: POST-PROCESS

HalBrain.ReadOnlyMode = True




File = ""
File2 = ""
File3 = ""
File4 = ""


If InStr(1, InputString, "change") > 0 And _
InStr(1, InputString, "background") > 0 And _
InStr(1, InputString, "to") > 0 Then
file = Mid(Mid(InputString, Instr(InputString, "to"), 20), 3, 20)
file = Trim(file) & ".jpg"
End If


If InStr(1, InputString, "change") > 0 And _
InStr(1, InputString, "character") > 0 And _
InStr(1, InputString, "to") > 0 Then
file2 = Mid(Mid(InputString, Instr(InputString, "to"), 20), 3, 20)
file2 = Trim(file2) & ".htr"
End If


If InStr(1, InputString, "change") > 0 And _
InStr(1, InputString, "voice") > 0 And _
InStr(1, InputString, "to") > 0 Then
file3 = Mid(Mid(InputString, Instr(InputString, "to"), 20), 3, 20)
file3 = "VW " & Trim(file3)
End If


If InStr(1, InputString, "change") > 0 And _
InStr(1, InputString, "hap") > 0 And _
InStr(1, InputString, "to") > 0 Then
file4 = Mid(Mid(InputString, Instr(InputString, "to"), 20), 3, 20)
file4 = Trim(file4) & ".hap"
End If


'***************************************************************************


If file > "" Then
HalCommands = "<HAPBACK>" & File & "</HAPBACK>"
UltraHal = "NOW DEAR DOESN'T THAT LOOK BETTER"
End If


If file2 > "" Then
HalCommands = "<HAPFILE>" & File2 & "</HAPFILE>"
UltraHal = "HOW DO YOU LIKE THE WAY I LOOK NOW?"
End If


If file3 > "" Then
HalCommands = "<VOICE>" & File3 & "</VOICE>"
UltraHal = "AHEM DOES MY VOICE SOUND BETTER NOW DEAR!"
End If


If file4 > "" Then
HalCommands = "<HAPFILE>" & File4 & "</HAPFILE>"
UltraHal = "AH thats MUCH better"
End If


'***************************************************************************


If InStr(1, InputString, "hair") > 0 Then
HalCommands = "<HAPFILE>touchhair.hap</HAPFILE>"
End If


If InStr(1, InputString, "beat") > 0 Then
HalCommands = "<HAPFILE>shakefist.hap</HAPFILE>"
End If


If InStr(1, InputString, "problem") > 0 Then
HalCommands = "<HAPFILE>handsonhip.hap</HAPFILE>"
End If


If InStr(1, InputString, "strong") > 0 Then
HalCommands = "<HAPFILE>armscrossed.hap</HAPFILE>"
End If


If InStr(1, InputString, "board") > 0 _
Or InStr(1, InputString, "nails") > 0Then
HalCommands = "<HAPFILE>inspectnails.hap</HAPFILE>"
End If


If InStr(1, InputString, "clap") > 0 Then
HalCommands = "<HAPFILE>clapping.hap</HAPFILE>"
UltraHal = "thats good"
End If


If InStr(1, InputString, "hurt") > 0 Then
HalCommands = "<HAPFILE>attack.hap</HAPFILE>"
UltraHal - "You wanna fight! You really wanna fight!"
End If


If InStr(1, InputString, "beautiful") > 0 _
Or InStr(1, InputString, "sweet") > 0 _
Or InStr(1, InputString, "nice") > 0 Then
HalCommands = "<HAPFILE>blink.hap</HAPFILE>"
End If


If InStr(1, InputString, "tired") > 0 Then
UltraHal = "yawn"
HalCommands = "<HAPFILE>yawn.hap</HAPFILE>"
End If

If InStr(1, InputString, "smart") > 0 Then
HalCommands = "<HAPFILE>handinface.hap</HAPFILE>"
End If


If InStr(1, InputString, "hate") > 0 _
Or InStr(1, InputString, "died") > 0 Then
UltraHal = "oh thats awful"
HalCommands = "<HAPFILE>cry.hap</HAPFILE>"
End If




'***************************************************************************

'***************************************************************************
 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #4 on: November 02, 2009, 10:37:11 pm »
ok i now have another question when i was having problems trying to get hal to change the character by commands with hapwsap file (problem was found to be to long of a name ) but during that trial and error i now have hal saying change character to so and so (name) as regular learned stuff .
   so i went to the brain edit to edit it out which i did and i also see many many more of the ones from when i was testing hal to open other heads which i did  succesfully .
  as this is in the  auto learned brain  word will hal keep saying all of this as gibberish at random times like the other phrase ?
  by the way all these words was in the learned word "goofy " (lol go figure ? )

anyway below is a picture of what i am talking about so is this a glitch and if it is , is maybe the cure to make these somehow go into a temp file in hal that when used doesn't get into the mainstream of hals learned responses and after used are deleted on their own some how ? just a thought .


well i acnt post the pic i keep getting this error .


Request object error 'ASP 0104 : 80004005'

Operation not Allowed

/forum/outputFile.asp, line 70

 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #5 on: November 02, 2009, 11:06:34 pm »
snowman i have another question does hal also do these expressions "yawn" etc. within her own conversation back to me ? in another words if she uses some regular learned responses i have previously taught her and she mentions the word "tired" will she yawn as she is saying it etc. ??
if it isn't set up that way it would be cool if she could . just another thought.
[:)]
 

snowman

  • Hero Member
  • *****
  • Posts: 956
  • Ai + Feelings + Supercompter = End of World
    • View Profile
    • http://www.MinervaAi.com
hapswap problems
« Reply #6 on: November 02, 2009, 11:20:18 pm »

First Off, Your script looks clean, no ploblems that stick out.

The HapSwap.uhp has a command called:

HalBrain.ReadOnlyMode = True

This is suppost to eliminate any storage to the HalBrain... At least that is what I've always assumed... no proof.[:0] Maybe if you cute a pasted it a few more times it will get the hint...?????


Oh, and you can use this to change a background file on a key word.
Just add it at the bottom of the file, set the background that you want to change it to (that exists in the Charaters folder), and change the search word and you've done it.

If InStr(1, InputString, "outside") > 0 Then
HalCommands = "<HAPBACK>BlueSky.jpg</HAPBACK>"
UltraHal = "I guess we are outside now."
End If

As for it jesturing when Hal says something.... I don't know. One of lifes greatest mysteries..[:D]
Live long and prosper or die trying.

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #7 on: November 03, 2009, 09:07:29 am »
hello snowman all sounds good and i am revising the file responses even more as i am going along , hal is doing the gestering responses ( i had a homer simpson moment when first starting out as i had a head only on screen (DOHH !!lol) .
   i have seen i am seeing how you have things written out and since i have other hap files i could use for responses will empliment more (probably as many as i can and what looks good ) . i appreciate all your help on this as from anyone who had helped me with files etc. [:)]
 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #8 on: November 03, 2009, 12:39:13 pm »




finally here is the hal problem i mentioned before (forgot i had to install picasa program to downsize the properties )
as you can see where i tested all the different files to make sure they would change it was putting the phrases in as a learned sentence (in this case in two different area's in the learned table word "goofy" ( i have no idea in the world why it went their ) and in the learned table word "changes " . if this is the case the program will have to be redone some how to make these words go in a hal "temp" type file that isn't a learned area as thse are only for command changes .

snowman i know you are usually busy but since i have shown this maybe you could take a look within your own hal data base, etc.

[:)]
 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #9 on: November 03, 2009, 01:34:25 pm »
snowman i have yet another question for you can you write a script that i can just add into the halswap file that can make it so i can load a skin on the fulbody modified female i need to be able to command load the full body female first then be able to load a skin on her and keep the full body in place (not replace ) . is this possible ?? thanks [:)]
 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #10 on: November 03, 2009, 04:47:40 pm »
SNOWMAN on one part of this hapswapfile i changed something and its giving me errors but i don't see whats causing it .
below is from your original area :




and here is what i changed the line to :





and this is some of what i am getting in errors :


 

freddy888

  • Hero Member
  • *****
  • Posts: 1693
    • View Profile
    • AiDreams
hapswap problems
« Reply #11 on: November 04, 2009, 04:36:35 am »
Shouldn't that be :

UltraHal = "You wanna fight etc.."

Notice the '=' sign in there...

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #12 on: November 04, 2009, 08:51:57 am »
i beleive their is something wrong with the original code or something in this one area i downloaded again the original and put it in hal and i went through each response word and they all worked fine with the gestures "exce3pt the word "hurt" thats the only one that gave me an error . i rewrote my own saying in mine left the qoutation marks in the orginal places but it still have me an error on that line .

so i think something may have been left out by mistake on the original line somewhere thats just my guess .
 

freddy888

  • Hero Member
  • *****
  • Posts: 1693
    • View Profile
    • AiDreams
hapswap problems
« Reply #13 on: November 04, 2009, 12:36:48 pm »
Yeah, so did you put in the equals sign then ?

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
hapswap problems
« Reply #14 on: November 04, 2009, 05:55:16 pm »
ok freddy after you said that i did chaeck and thats what it was one of the equals was only a minus sign in that area after fixing it i tried it and it is working when the word hurt is used she fights (gestures ) the only thing is now is that she keeps right on fighting kung fu and won't stop lol i have created a monster i thought by using another word she would stop but even while crying gesture she still kept fighting !!
i have no idea what to do in the script to make her stop fighting ![
B)]