USING MERLIN IN VB APPLICATION OR IN HELP FILE 1.0
Submitted By:
suddha86
Rating:





(
Rate It)
Attribute VB_Name = "Module1"
OPTION Explicit
Public my_agent AS AgentObjects.Agent
Public my_chragent AS AgentObjects.IAgentCtlCharacter
Public SUB loadagent()
Set my_agent = New AgentObjects.Agent
my_agent.Connected = True
my_agent.Characters.Load CharacterID:="Merlin", loadkey:="Merlin.acs"
Set my_chragent = my_agent.Characters(CharacterID:="Merlin")
my_chragent.Height = 400
my_chragent.WIDTH = 400
my_chragent.Balloon.FontSize = 18
my_chragent.Balloon.FontName = "MICRON56"
'If my_chragent.Speak("BYE") Then
'unloadagent
'End If
END SUB
Public SUB introagent()
With my_chragent
.Show
.MoveTo x:=100, y:=500
.MoveTo x:=500, y:=100
.MoveTo x:=100, y:=500
.PLAY animation:="Greet"
.PLAY animation:="PLEASED"
.Speak ("Hello, My Name is Merlin,i am here because i am invited by SUMAN")
.PLAY animation:="Restpose"
.PLAY animation:="ANNOUNCE"
.PLAY animation:="SUGGEST"
.Speak ("Here is some MAGIC **********")
.PLAY animation:="DOMAGIC1"
.PLAY animation:="DOMAGIC2"
.PLAY animation:="WRITE"
.PLAY animation:="Read"
.PLAY animation:="hide"
.Speak ("U CAN USE ME IN ANY HELP FILE")
.Speak ("PLEASE RATE MY CREATOR BY RATIMG HIM")
.Speak ("AFTER SOME DAY I WILL APPEAR WITH A DIFFERENT LOOK")
.Speak ("UNTILL GOODBYE")
.Hide
'unloadagent
'If .Speak("BYE") Then
'unloadagent
'End If
END With
' If my_chragent.Speak("BYE") Then
'unloadagent
'Exit Sub
'End If
END SUB
Public SUB unloadagent()
my_agent.Characters.Unload "Merlin"
Set my_agent = Nothing
Set my_chragent = Nothing
END SUB