Hunt Helper Bot for ActiveWorlds

See the full article about the bot here.

Ini file generator for the latest hunt bots


Version 4.2.9  (3/28/2007)
    - Last free release for 3.6

Version 4.2.4  (12/21/2003)
    - fixed database reloading when a world is removed from the list
    - added different ini file reading feature (won't work if the default ini file has the autostart enabled!)
    - added several CT functions

Version 4.2.1  (12/13/2003)
    - Major cleanup in the code, improved bot tabs.
    - Simplified world parameter definitions.
    - File path fixes for all internal workfiles.

Version 4.1.7  (11/25/2003)
    - Added tourist password identification option.

Version 4.1.6 (11/16/2003)
    - Fixed Quiz designator in the action field. The bot expected at least 5 characters there. Sorry.

Version 4.1.5  (11/12/2003)
    - Fixed Messages savings to the INI file, enabled a readonly control to modified (Thanks Emmanuel)

 Version  4.1.4 (11/12/2003)
    - fixed multibot start
    - added INI-only features
Usage in different universe: Add those lines to the ini file (case sensitive!) and put there your auth server URL and port:
[Universe]
Host=
Port=
special INI only variables
[Control]
DebugLog=         Disabled/Enabled
ClickTest=        Disabled/Enabled
MAXBOTATONCE=     1-x (default is 1). If the number is greater than 1, it is not guaranteed that the bot sequence numbers will be sequential!
                                (I found no speed increase on the local net but could be faster on a WAN)

 Version  4.1.3 (11/11/2003)
    - added ignore object selection - effectively enabling the bot to run in a world where the build can not be disabled.
    - changed bot log file name to: WorldName_BotSeqNumber_BotName.txt
    - Added tourist password feature.  This feature enables the tourist identity maintained during the hunt.
When a tourist arrives to the hunt site, the bot asks him/her for his password, if the tourist is a new visitor, it can get the password from the bot by whispering: password to the bot. If someone took the tourist name, he/she can reclaim it by whispering to the bot his/her old name and password like:
"Andras2":8z8JkVWW.

 Version 4.1.2  (11/09/2003)
    - Fixed special objects shuffling.

Version 4.1.1 (11/06/2003):
 -   Fixed Quiz message/Ini file recording bug

Version 4.1.0 (11/04/2003):
-   Added individual hunt objects for each world (Each world can have more than one instance of the bot is running if your area is scattered around and you don't want to cover all the world with bot!)
-   How can you hide the scores from the hunters if you are running in a world where they can select the objects (and examine the action field where the scores set):
       Hide the objects inworld and add the score=xxx to the action field where xxx is the numeric score value.
       Run YASBB  Survey with DeleteWhileSurvey, ObjectNumForDelete, CleanAction, DeleteOnly, UseQuery5 checkboxes selected (the rest is NOT selected on the same tab) with "Action contains" field content=score ("Description contains" field is empty) . Save the resulting file to your huntbot folder under huntobjscores.txt. This action will effectively clear all the action fields for those objects.
       When you run the huntbot, select the "ReadScores" checkbox. The bot will read the huntobjscores.txt file first, so all objects will be marked within the bot with those special values.
-    Adding special scoring feature where some objects can have a score value assigned which value will randomly move between objects effectively disabling the hunters to share the location info of a high value object. Add the world random to the action line too, so the special object's action will look like:
score=500 random



Version 4.02 (10/23/2003):
-   Fixed bug when program raises GPF accessing the Votes button (caused by missing nominee in the object's action field). Thanks Emmanuel!

Version 4.0.1
(10/22/2003):
-   Added different world size features. Each world now individually configurable for the hunt.

Version 3.7.1 (10/21/2003):
-   Added multiple world feature. One can list the worlds in the world edit box separated with comma. The bot will the log into each world but to the same center location and the same covered area size. One should take caution to not to specify too much worlds, since the program can handle maximum 255 robots. All the scores are cumulated independently which world the player collected them.

Version 3.6.1 (9/16/2003):
-   Added voting feature with no categories

Version 3.5.5 (3/16/2003):
-   Fixed HTML generating bug, added cheaters' removal feature to the html code.

Version 3.5.3 (3/5/2003):
-  Fixed disappearing error message when the bot's login unsuccessful (like illegal character in name).
 
Version 3.5.2 (1/4/2003):
 
- Fixed small bug in response rule checking
 - added option to enable chat window response parsing.


Version 3.5.1 (1/4/2003):
(Thanks for the idea to Cyberwitch and Weeboo)
- Added new feature to conduct a trivia quiz when the user clicks on a particular object. The bot asks a question from the user and waits for 30 seconds (or modified by the "Resp.Time" field) for the answer. It carves up the answer from that particular user from the whisper or the chat window into words (separators are space and comma). It then comares by the rules in the answer field is given and adds the given score points to the user's score if he/she passes the criteria.

 Version 3.4.15 (11/28/2002): 
- Fixed GPF errors when the program closed with no bots running.
- Fixed autorestart for various disconnection causes.

Version 3.4.14 (11/28/2002): 
- Fixed several hunting features broken when introducing the voting feature.

Version 3.4.12 (10/22/2002):
  - Added voting features to the bot.
    - The objects supervised should have the category (as number) in the description field and the nominee in create sign="xxx" format in the action field.
  - Changed user tracking to cit# AND names

Version 3.4.3 (5/24/2002):
  - Fixed a bug when the program did not exit while the world query is ongoing.

Version 3.4.2 (5/2/2002):
  - Added several new features like Scoring, improved/simplified enumerations for large worlds, etc.

Version 3.2.1 (4/16/2001):
 - replaced query with enumeration - runs only on world server build 20  or above!
 - increased robot's covering range to 400x400 meter
 - Added scoring window
 - Added database saving so restarting the bot doesn't require another query

Version 2.1.1 (2/13/2000):
 - FaceLifted the user interface
 - Added easy configuration options to add objects to the huntable object list
    - click inside the "Object list" box.
        - press the Insert key to add new object
        - press the Delete key to remove the highlighted object
        - press the Enter key to modify the highlighted object.
 - Added easy modification features to the message the robot whispers to the players
Those functions above are accessible before you start the robot only.
 - Added a sorted score listing button.
 - Reduced the required robot numbers by one!

Note: Due to AWSDK strict query restrictions, the robot center position has to be a multiple of 8 in both direction, otherwise some areas will not be covered!
 
 

Version 2.0.1 (2/7/2000):
- changed "gift" message to object.
 

The program's objective is to help the "Egghunt-like" contests for ActiveWorlds. It logs each click on any predefined object type within it's range and keeps tallying the results for each participitant.
This is a Robot - based on the AW SDK Build 15.
Usage and distribution of this program is free but reverse engineering is not allowed :)


First time users has to fill the bot credentials, set the game control checkboxes


The world(s) in where the hunt will run. Specify the hunted objects with selecting the Object names list and hit the INSERT key to add another object. Those names has to be exactly the same as it appears within the world. Specify the size of the hunted area and the center of it too.
If you do a different game than Gift/Present hunt, modify the bot's messages:


If you use password for tourist identification, you can modify the related messages too.

Start the bot and do a query on the hunted area. It has to display how many target objects found total and you can check by each bot's tab each bot's objects it covers.:


You can set now up all the needed settings for the hunt:


The bot can log several actions, all the char and it's own whisper. It is up to the user if he/she needs it. In the Game Control, you have to check AutoStart and StartStop MSG, so when the bot disconnected from the world, it can restart automatically. To avoud the World query at hunt time, select the AutoLoad feature in the QueryControl. The bot saves all target objects' location, so it is faster to reload it from the disk then reading it from the world. You have to set the Ignore new objects and Ignore Selection if you can't disable the build and object selection for the game's duration.

When you are ready to start the hunt, just click on the StartHunt button. During the game, you can interrogate the current status of the winners by clicking on the Scores button.

You can resort the list by clicking on the appropriate header. Hitting Refresh will refresh the list, it is not a real time list due to the frequent changes. Click on SaveIt when you want to save the current status (and of course at the end of the game) !
The HTML button will create a html formatted table from the winner's list:

It is very important to fill the Winner(from) and Until lines, to properly select the palyers in the list.

This is the exaple html table the bot makes:


1
Andras
16
56
69
P20 world for 1 year
2
"Prince Martin"
0
0
3
1 year citizenship
3
"Andras4"
0
0
0
1 year citizenship


This section is somewhat obsolete but I don't have time to finish this tutorial :(

The robot has the following parameters:
Citizen Number - is the AW citizen number for the bot's owner.
Priviledge Password - is the owner's priviledge password (needed for the bot to be able to log into the Universe)
World  - is the world where the bot will be used (the world rights options have to have citizen's number in the "Bots" line.)
Bot Name - is the name each bot is named during operation. You can only use alphanumeric characters.
Bot Avatar Number - is the sequence number of the desired avatar within the target world avatar list. The list starts with 0.
Center Coordinate - Set it for the hunt center.
Covered Area - is the size of the area centered around the Center Coordinate for the hunt. The larger the area the more bots are needed to cover it. Check your "bot limit" with AWCOM if it exceeds 3.

The robot starts with a default INI file (huntbot.ini in the same directory where the robot started). All values you enter onto the parameters above will be registered in the INI file, so next time you start it there will be no need to reenter them again.

The robot creates a click.log file which holds the objects informations already clicked by a certain player. It allways appends any new object found into that file. If you want to reset the tally counter - simply delete the click.log file before you start the robot.

The program supports up to 100 different kind of objects for the hunt.
You have to edit the huntbot.ini file for the desired object names for the game.
The names are under the [HuntObjects] section.
The syntax is:
ObjNamexx=yourobjectfilename
   where xx    - is the sequence number from 00 to 99 (leading zero needed!)
   yourobjectfilename  - is the filename as it appears in the AW Object Editing box (like ground.rwx)
E.g.:
ObjName00=gift1.rwx
ObjName01=egg2.rwx
.
.
.
ObjName17=castle.cob
ObjName18=bmw1.cob
... etc.
The names don't have to be in alphanumerical order but the object names can't finish with white space.

The Hunt Helper Bot supports remote control from a separate PC through the AW Browser. To use the remote control feature, the person has to be on the
"Authorised PS list" of the bot; has to be a PS on the world rights list and has to be wearing one of the 5 special avatars. It is strongly recommended that you add your
name to the list in the INI file under the [AuthorizedPS] section.
Syntax is PS1=yourname.
Authorized persons have additional commands they can use to remotely operate the Hunt Helper Bots. To find out what they are just whisper HELP to the bot.
 

Windows version fixes (not released)
4.2.5
    - Fixed click.log reload when it have crazy empty lines from the description field
4.2.6
    - added reset score command
4.2.8
    - added score limitation
5.0.1
    - fully modified for voting AGAIN
5.0.3
    - fixed welcome session message
5.0.4
    - added MySQL password handling
    - decreased HASH size due to huge memory usage (3500 visitors minimum 370 MBytes memory :( )
    - added wild char for objects:  gift*.rwx  and gift*  format only
    - modified MySQL handling, so no all requests are loaded,
    - refined sequential query for huge amount of bots set # of parallel bots to 8 versus 4
5.0.5
    - added world specific propload feature. If one provides a propdump with the object numbers (YASBB query with ObjNumberForDelete)
      then the bot will read the file instead of querying the world.
    - changed logging method for continuous main log write to the logfile.
5.0.6      - Last Windows version
    - changed ini file boolean values to make it compatible with the linux version.




Change history for the Linux version of the bot (not released).

5.0.7   
    - Added sign modification feature for the results announcment.
        there are the examples of the prize boards.
        The bot will fill the values if they are created properly:
                The description field should end with a newline (Ctrl Enter)
            - the bot will fill the rest with the name/cit and score values.
            The action line should have a";winner=x" string without quotes where the x is the position (as many prizes we have :),
                   so this is how the bot recognizes it.
            If the Action line has a visible off then the bot will change it to visible on, when it fills the sign.
5.0.8
    - Fully redesigned the HTML output feature for the Linux version.
    The program now creates all the HTML files for each worlds and the hunt itself.
    The program will generate comma delimited csv files from the scores.
    - Added ProgramID field to the ini file and the SQL database, so the backup bot can use the same database for the
    click logging and they can be identified by the ID.
5.3
    - fixed quiz reading
    - added world rating (still adding :)
5.4
    - modified world rating messages
5.5
    - fixed Voting reload after the restart
    - modified voting object format:
       Category exists: Action field only: ;category=number description;nominee=string;     
       No Category:  ;nominee=string;
       Cancel vote in category object:  ;category=number;nominee=cancel vote;
    - fixed setwelcomemsg command
    - changed AuthorizedPS to Citname#citnum format (and use only citnum!)
    - refined voting listings
    - added bot citnum/privpass to each world (if not specified, the global one used!)
    - votetop: command has a parameter: MaxPosition within each category
        if 0 or negative is specified, then it will only save the full state to the file
        otherwise it keeps the last MaxPosition value until change
    - consolidate different vote signs if they have identical category and nominee

5.6 (7/4/2005)
    - added makehtml: command to invoke the SQL process. Could be time consuming!
    - added Vote state sign management (refresh manually by showwinnersign: command)
    - added autoupdate: where the Vote state sign is refreshed in every second if they changed

            WinnerSign object format:
            model - should be in the target/voting object list
            action field - create sign color=xxx bcolor=yyy;winner=positionnumber;c=categorynumber;
            description field - overwritten with the current nominees at that position.

5.7 (7/11/2005)
    - modified voting object format AGAIN:
       Category exists: Action field only: ;vote c=categorynumber [categorydescription];n=nomineestring;     
       No Category:  ;vote n=nomineestring;
       Cancel vote in category object:  ;vote c=number;n=cancel vote;

5.8 (12/13/2005)


5.9 (12/20/2006)

  • new clickable object type: xscore=xx that object can be clicked several times and the score value is added on every click (useful only for negative scores!)
  • added statistical values to the HTML generation
  • fixed inconsistency between the actual scores and the calculated scores
  • Inifile handling now can be done through MySQL
  • This feature allows you to collect all necessary info through a web site and automatically get the needed parameters for the bot.
  • Speed-up of the html generating!!
  • Hunt INI file generator for the Linux/console huntbot


    Version 2.1.1
        - Added changes so the program can generate the different Quiz categories too.

    Version 2.0.1 initial release
        - this program creates the necessary ini file for the huntbot version 5.x




    INI File variables:

    [IniConfig]The only configuration section needed if the values come from the MySQL table
    SqlConfiguration=1Specifies if the configuration should be read from a database
    SqlConfigurationServer=localhost
    SqlConfigurationUser=mysqluser
    SqlConfigurationPassword=secret
    SqlConfigurationDatabase=IniconfigDatabase containing the config
    SqlConfigurationDatabaseDBPrefix=myhunt_table name will be myhunt_config. columns:isection,ikey,ivalue


    The rest of the configuration values. They can be in the ini file or in the database specified above
    [Universe] Self explanatory
    Host=auth.activeworlds.com
    Port=5670


    [Control]
    DebugLog=0 Do not use - sw test only
    MAXBOTATONCE=1 Number of bots started at once. There is no advantage to have more than one
    ProgramID=1 In case of backup bot, use a different ID, so you can separate them from the database


    [World]
    ChatLog=1 Log all chat into the main logfile
    WhisperLog=1 Log all whispers to/from the bot to the logfile
    ClickLog=1 Log all clicks onto each bot's logfile - obsolete
    AvatarLog=1 If set, the bot logs all avatar entry/exit into an individual file
    RecordMovement=1 Do you want to record all avatar change into the database? (requires very fast server machine to run on ot!)
    NoAvSave=0 If set, the click.log file will not have the visitor l;ist included in case of the program termination
    EnableRating=1 Can the visitors rate the worlds they are hunting in?


    VotingOnly=1 Does the bot acts as a Voting helper or a regular hunthelper
    LastClick=1 During the vote process - do you want to register the voter's last click as a valid one or he can not change his mind
    NoCategory=0 If you are holding a single poll, no category is required in the voting objects
    MaxPos=3 Default listing value for the votetop: command - how many nominees listed maximum within a category
    AutoSignUpdate=1
    Automatically update the Vote result signs when they change


    QuizEnable=0 Do you have Quiz questions specified for a hunt. Quiz triggered by the "quiz" keyword in the action field
    QuizTime=30 How long the bot waits for an answer after it asked a Quiz question
    QuizChatResp=0 If set, the answer accepted even from the chat window (whisper only is preferred)


    TouristPlay=1 Can tourists hunt too?
    AutoStart=1 Automatically start the bot after the program start. Have to be enabled!
    AutoLoad=0 Do you want the already queried object simply reload when the bot start instead of requerying the worlds
    AutoHunt=0 Does the bot automatically enable the hunt after a restart (It can save some time if the bot crashes and you restart it)
    StartStop=1 Does the bot announce the hunt start/stop? (disable if it is a backup bot)
    IgnoreBuild=1 Do you want the bot to register newly built hunt objects
    IgnoreSelection=1 Does the bot treat object selection as a cheat
    TouristsUsePassword=1 If tourists hunt, they should use password for identification
    BotEnabled=1 If set, the bot registers all other bots (useful if you control the bot through another bot)


    WelcomeMsg=1 Do you want the bot to greet all visitors (turn of if it is a backup bot)
    NoTallyAnnounced=0 Do you want the bot to announce the current tally after click (turn of if it is a backup bot)
    CheatWarning=0 Does the bot issue a "Don't cheat" warning if an object selected?
    NoCheaters=0 Disable the cheaters from the final scoring
    ShuffleRegularly=0 If enabled, the bot will shuffle the specialy designated scores within the objects - useful for a few high point objects
    EnableResetScore=0 If enabled, the users can reset their score (why would anyone do it?)

    ScoreLimit=1000 General Score limitation if it is not specified within the world
    LimitScore=0 Do you want to limit the scores assigned to the objects globally?
    MySQL_Only=0 Does the bot performs only HTML page generations without hunt?
    Scores_Only=0 If enabled, the HTML generation skips the "csv" files creation which holds all the clicks.
    HtmlTitle=Scores 2005 What do you want to add to the HTML page title?
    HtmlChartName=Easter2005_ If you have visitor charts to embed to the HTML pages - what are their prefixes
    NoChartGraphic=1 Do you want to include charts created by an external application to your HTML page?

    ConvertOldVote=0 Development use only Do not change!
    HashVerbose=0 Development use only Do not change!
    UseQuery=1 Development use only Do not change!
    Sequential=1 Development use only Do not change!
    LogAvatarEntry=1 Obsolete - not used
    RenumerateObjects=0 Obsolete - not used
    VerifyCitnum=0 Obsolete


    [AuthorizedPS]
    PS1=EggHider#271917 Usually created by the bot owner: Who is allowed to control the bot? By default the bot owner has this right!


    [MySQL]
    UsePasswordServer=0 Set it if you want to use a common password server
    PasswordServerURL=localhost The MySQL server's parameters. The bot can use MySQL to record all activities in addition to it's logfiles
    PasswordServerPort=3306
    PasswordServerDatabase=PWDB
    PasswordServerUser=Huntbot
    PasswordServerPassword=yyyy
    UseClickServer=1 Set it if you want to use a MySQL database to store all hunt related events.
    ClickServerURL=localhost
    ClickServerPort=3306
    ClickServerDatabase=HuntDB
    ClickServerUser=Huntbot
    ClickServerPassword=zzzzz
    UseWorldServer=1If you want the bot get the world parameters from a database
    WorldServerDatabase=AWChristmas2006The database which contains all individual World parameters
    WorldServerPassword=secret2
    WorldServerPort=3306
    WorldServerURL=localhost
    WorldServerUser=HuntBotThe user who has authority to read the table


    [Owner]
    UserCitizenNumber=106479 Global bot ownership - can be overridden within each world
    UserPriviledgePassword=aaaa


    [Messages] You can customize those messages. %s stands for a string while %d stands for a number

    WelcomeMsgText=Welcome to the popularity vote! Whisper HELP to me for further information.
    ScoreObjectMsg=You voted for %d unique category so far. Your voting number is %d.
    NewObjectFoundMsg=You voted for %d unique category so far. Your voting number is %d.
    TouristBadPasswordMsg=Password doesn't match. Please try again!
    TouristNoSuchUserMsg=No such user in the database. Please try again!
    TouristInworldUserMsg=This user is inworld!. You can't share the password with him.
    TouristNewPasswordMsg=Your password is: %s . Please write it down, you'll need it everytime you log in.
    TouristPasswordFailedMsg=Sorry - you have to use a correct password to participate.
    TouristPasswordSuccessMsg=Password accepted.Thank you!
    TouristPasswordExistMsg=You already have a password. You can not take over another account while this account has a password.


    [RulesMessages] Those are the lines told to the hunter when they whisper help:
    RulesMsg0=The objective of the hunt is to find the most of the hidden gifts within this world.
    RulesMsg1=Those gifts are hidden throught the whole world all over the place.
    RulesMsg2=If you find a gift just click on it and I'll tally your findings. Each gift counts only once.
    RulesMsg3=To participitate in the Hunt you have to use the same name during the whole duration of the hunt.
    RulesMsg4=You can control the Robot with the following commands whispered to him:
    RulesMsg5=Quiet Turns the Robot's announcement off.
    RulesMsg6=Verbose Turns the Robot's announcement back on.
    RulesMsg7=Score Tells your current tallied number.
    RulesMsg8=Please rate your hunting experience in each world by whispering to the bot: rate:x where x is between 1 and 9 (9 is the best)


    [Tourist1Messages] Self explanatory messages
    TouristFirstMsg0=If you participated under a different name then please log in using that name.
    TouristFirstMsg1=If your old name is taken, please whisper your old name:password (both are case sensitive!)
    TouristFirstMsg2=If you are new, ask me for a password by whispering: password.
    [TouristExMessages]
    TouristExistMsg0=This name has a password for participating.
    TouristExistMsg1=Please whisper your password to me or log in under another visitor name.


    [World1] Multiple worlds template. Each world has it's own section. The numbers should be consecutive.
    UserWorldEdit=Rhapsody The world name itself
    BotNameEdit=VotingBot The center bot's name within that world
    BotZoneNameEdit=VotingBot The rest of the bots name (it will be suffixed with a sequence number)
    BotElevationEdit=6 The height of the bot in dekameters
    TypeEdit=251 The avatar for the bots
    CenterNSEdit=0 The center coordinate of the world (in dekameters)
    CenterNSRadio=0 0 = North, 1 = South
    CenterWEEdit=0
    CenterWERadio=0 0 = West, 1 = East
    WorldType=0 The size covered by the bots:

    0 - P20 1 bot

    1 - P60 9 bots

    2 - P100 25 bots

    3 - P140 49 bots

    4 - P180 81 bots

    5 - P220 121 bots

    6 - P260 169 bots (this is the maximum this program allows)

    7 - P40 4 bots

    The program is preconfigured to maximum of 300 bots total, so don't exceed it!!
    UseProp=1 If you have the propdump of the world (with the object number! - created by YASBB)
    PropPath=rhapsodyprop.txt the bot will read the propfile instead of querying the world.
    Enabled=1 You can disable a world in the list (e.g. the world is disqualified for the hunt)
    LimitScore=0 Do you want to limit the scores on the hunt objects within this world?
    ScoreLimit=20 Set the maximum score value to rounded down
    Owner=271917 If this world needs a differen bot owner, specify here otherwise set it to 0 or omit this line
    PrivPass=xxxxxxxxxx


    [World1HuntObjects] The bot will handle only those objects specified below as a hunt/voting object
    ObjName00=sign3.rwx Up to 100 different object within each world can be a hunt target.
    ObjName01=egg*.rwx You can use wildchars in this manner only
    ObjName02=egg* You can use wildchars in this manner only


    [QuizMessages] if you have Quiz enabled in the hunt (they are global for the whole hunt!) This is category 0

    specify the questions, answers and it's value here

    up to 1000 questions can be specified.
    Question000=Do you like the HuntBot?
    Answer000=Yes
    Value000=50


    [QuizMessages1] Category 1 (up to 63)
    Question000=Do you like Ice cream? first question within this category