Tuesday, June 28, 2011

Fix for Actorbot/METAbolt Custom Greeting

There is a bug in the Pandorabot's greeter script which prevents the owner from configuring the default greeting for Actorbot and METAbolt Pandorabots. Here is the problem and a workaround.

The default Pandorabot greeting is specified by four strings labelled GREET_1, GREET_2, GREET_3, and GREET_4. The default greeting for a standalone Pandorabot uses GREET_1 and GREET_2 as follows:

"Hello <name of avatar>! Chat with me in local chat. Visit the Pandorabots Blog at http://pandorabot.blogspot.com/"

If the Pandorabot is running as an Actorbot then the following is added  to the default greeting (GREET_3):

"IM me with the message 'Help' for commands."

If the Pandorabot is running as an Actorbot or with METAbolt then the following is added to the default greeting (GREET_4):

"Say 'menu' in local chat for dialog menu of commands."

Should you wish to change the default greeting then each of these strings can be specified by editing the Greeter_Config notecard. Unfortunately, a bug in the Greeter script prevents the GREET_4 string from being specified in the Greeter_Config notecard. Fortunately, there is an easy workaround and a fixed Greeter script will be in the next update.

The workaround for specifying a custom GREET_4 string is to edit the Greeter script itself rather than the Greeter_Config notecard. Near the beginning of the Greeter script are the following lines:

// The greeting will be 'GREET_1 <name of avatar>! GREET_2'
// If running as an Actorbot, greeting will also include 'GREET_3'
// If running as an Actorbot or METAbolt, greeting will also include 'GREET_4'
string GREET_1 = "Hello";
string GREET_2 = "Chat with me in local chat. Visit the Pandorabots Blog at http://pandorabot.blogspot.com/";
string GREET_3 = "IM me with the message 'Help' for commands.";
string GREET_4 = "Say 'menu' in local chat for dialog menu of commands.";

Simple change the string "Say 'menu' in local chat for dialog menu of commands." to whatever you like. The same can be done for the other strings but only GREET_4 needs to be changed here and not in the configuration notecard.

Should you prefer, I can send you a pre-release copy of the fixed Greeter script which will allow you to make all greeter configuration changes to the Greeter_Config notecard rather than editing the script itself. IM Missy Restless with your request.

No comments:

Post a Comment