Permalink
Browse files

Integrate 'gmguy' feature in playerbot code

Enables users to auto-complete selective quests, controlled by server admin
  • Loading branch information...
1 parent ceca747 commit db85b2b6e9c5ad95a34e8b10af5cadeb4c17d043 @blueboy committed Sep 27, 2012
View
@@ -16,7 +16,6 @@ Commands:
/s .bot add BOTNAME (add character to world)
/s .bot remove BOTNAME
-/s .bot co|combatorder BOTNAME COMBATORDER [TARGET]
/invite BOTNAME (bot will auto accept invite)
For a full list of commands, use '/t BOTNAME help' or various subcommands e.g. '/t BOTNAME help auction remove'.
@@ -73,7 +72,11 @@ Note that these commands work both in whisper and in party chat (assuming the bo
/t BOTNAME quest < end | e > (Turns in a completed quest)
/t BOTNAME quest < report | r > (bot reports all items, creatures or gameobjects needed to finish quests)
/t BOTNAME quest fetch (bot will automatically check for and accept all acceptable quests from target questgiver)
+/t BOTNAME quest complete [QUESTLINK].. (player/bots can auto-complete selective quests)
/t BOTNAME orders (Shows bot's combat orders)
+/t BOTANME orders combat < TANK | HEAL > | < ASSIST | PROTECT > [TARGET] (Set bot combat orders. [TARGET] is a party member)
+/t BOTNAME orders delay <0-10> (Activates a delay before I start fighting.)
+/t BOTNAME orders resume (Resume combat orders to what they were before logout.)
/t BOTNAME pet abandon (abandon current active hunter pet)
/t BOTNAME pet tame TARGET (tame selected creature, if bot has 'tame beast' spell in spellbook)
/t BOTNAME pet spells (Shows spells known to bot's pet. Autocast spells will be shown in green)
@@ -108,10 +111,11 @@ Note that these commands work both in whisper and in party chat (assuming the bo
/t BOTNAME skill learn (lists [TRAINING LINK] available class, weapon & profession (Primary or Secondary) skills & spells, from selected trainer)
/t BOTNAME skill learn [TRAINING LINK] (learn selected skill or spell, from selected trainer)
/t BOTNAME skill unlearn [PROFESSION LINK] (unlearn selected primary profession skill & all associated spells)
-/t BOTNAME skill fetch (bot will automatically check for and learn all available skills/spells from the targeted trainer)
/t BOTNAME help (lists all the commands above and how they work. Except for the ".bot command" ones.)
/t BOTNAME gm check talent spec (Does a validity check on all talentspecs in the database, only works for GMs or higher)
-/t BOTNAME resumeorders (causes bot or party to restore previous combat orders)
+/t BOTNAME gm target < loot | combat > (list current bot lootable or combat targets)
+/t BOTNAME gm quest < add | del > [QUESTLINK].. (Add or remove selective quests to the database, that can be auto-completed)
+/t BOTNAME gm chat (Outputs all commands the bot receives - including those it feels it can't obey)
Shortcuts:
c = cast
@@ -290,7 +294,7 @@ When updating the sql file(s), keep in mind the following:
For clean install, just apply this sql
* src/game/playerbot/revision_sql.h
-#define REVISION_DB_PLAYERBOTAI "required_6_playerbotai_combatorders"
+#define REVISION_DB_PLAYERBOTAI "required_7_playerbotai_quest_autocomplete"
NOTE: This string should be an exact copy of your SQL file's second field name in the `playerbotai_db_version` table.
BotGuy NPC Menu System
@@ -306,6 +310,39 @@ Install (Server administrators only)
=======
Please apply 'mangos_botguy.sql' (in sql/playerbotai) once to the world database to update the 'gossip_menu_option' table.
+GMGuy Quest Management System
+=============================
+
+There are various reasons why you would wish to use this feature.
+
+ o - a problematic quest should break the quest chain, thus preventing the user from progressing in the game.
+
+ o - as a debug tool to quickly progress in the game, for test purposes.
+
+Whatever the reason, this will enable all users to auto-completed selective quests. Only server admin can control which
+quests can be auto-completed. These are stored in the character database (playerbot_quest_data - table) that can be manage
+remotely, while the server is online. Please note that you need to be able to select the quest hlink [HLINK], so you will still
+need to follow the quest chain to complete a particular quest. This is not designed to be a cheat system in anyway.
+
+For admin (only)
+
+Syntax: [Quest Hlink] can be selected ([SHIFT KEY] & Left click with Mouse) from the player/bot quest log.
+
+ o - gm quest add [Quest Hlink]..
+ o - gm quest del [Quest Hlink]..
+
+Note: [Quest Hlink].. signifies multiple links
+
+For all users
+
+All quest objectives will be completed automatically, allowing the player/bot to simply turn a particular quest to the
+appropriate quest end point (collect reward). Thus enabling player/bot to continue with the next quest in the chain.
+
+Syntax:
+
+ o - quest complete [Quest Hlink]..
+
+
---------------------------------------------------------
ToDo
@@ -12,7 +12,7 @@
DROP TABLE IF EXISTS `playerbotai_db_version`;
CREATE TABLE `playerbotai_db_version` (
`version` varchar(120) default NULL,
- `required_6_playerbotai_combatorders` bit(1) default NULL
+ `required_7_playerbotai_quest_autocomplete` bit(1) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Used DB version notes';
--
@@ -206,3 +206,12 @@ CREATE TABLE `playerbot_saved_data` (
`autoequip` tinyint(1) NOT NULL DEFAULT '0',
PRIMARY KEY (`guid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Persistent Playerbot settings per alt';
+
+-- ----------------------------
+-- Table structure for `playerbot_quest_data`
+-- ----------------------------
+DROP TABLE IF EXISTS `playerbot_quest_data`;
+CREATE TABLE `playerbot_quest_data` (
+ `autocomplete` mediumint(8) unsigned NOT NULL,
+ PRIMARY KEY (`autocomplete`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
@@ -0,0 +1,25 @@
+ALTER TABLE playerbotai_db_version CHANGE COLUMN required_6_playerbotai_combatorders required_7_playerbotai_quest_autocomplete bit;
+
+-- MySQL dump 10.13 Distrib 5.5.25, for Linux (i686)
+--
+-- Host: localhost Database: characters
+-- ------------------------------------------------------
+-- Server version 5.5.25-log
+-- Date: 2012-09-26 20:59:31
+
+--
+-- Table structure for table `playerbot_quest_data`
+--
+
+DROP TABLE IF EXISTS `playerbot_quest_data`;
+CREATE TABLE `playerbot_quest_data` (
+ `autocomplete` mediumint(8) unsigned NOT NULL,
+ PRIMARY KEY (`autocomplete`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+--
+-- Dumping data for table `playerbot_quest_data`
+--
+
+LOCK TABLES `playerbot_quest_data` WRITE;
+UNLOCK TABLES;
View
@@ -271,7 +271,9 @@ void WorldSession::HandleMessagechatOpcode(WorldPacket& recv_data)
for(GroupReference* itr = group->GetFirstMember(); itr != NULL; itr=itr->next())
{
Player* player = itr->getSource();
- if (player && (msg.find("help",0) != -1))
+ if (player && ((msg.find("help",0) != std::string::npos)
+ || (msg.find("gm",0) != std::string::npos)
+ || (msg.find("complete",0) != std::string::npos)))
{
player->GetPlayerbotAI()->HandleCommand(msg, *GetPlayer());
GetPlayer()->m_speakTime = 0;
Oops, something went wrong.

0 comments on commit db85b2b

Please sign in to comment.