From 0a18932056e2a72f41cdd14c831344ad80cfb35b Mon Sep 17 00:00:00 2001 From: Ira Rice Date: Thu, 15 Jan 2009 19:48:00 -0700 Subject: Added emote database, which is loosely based off of the NPC database. Also changed all emotes to be animated sprites now, and to load from emotes.xml. This gives us a bit more flexibility to not only add more emotes in the future, but allowing them to be animated as well. NOTE: This commit, unlike the previous emote commits, breaks emotes if you don't have the xml file. This will be available on Aethyra soon, but is not rolled into an update at the moment. Signed-off-by: Ira Rice --- src/main.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index 61b90b12..a1109092 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -74,6 +74,7 @@ #include "net/network.h" #include "resources/colordb.h" +#include "resources/emotedb.h" #include "resources/image.h" #include "resources/itemdb.h" #include "resources/monsterdb.h" @@ -402,7 +403,7 @@ void init_engine(const Options &options) // Initialize the item shortcuts. itemShortcut = new ItemShortcut(); - + // Initialize the emote shortcuts. emoteShortcut = new EmoteShortcut(); @@ -437,7 +438,6 @@ void exit_engine() { // Before config.write() since it writes the shortcuts to the config delete itemShortcut; - delete emoteShortcut; config.write(); @@ -453,6 +453,7 @@ void exit_engine() // Unload XML databases ColorDB::unload(); + EmoteDB::unload(); ItemDB::unload(); MonsterDB::unload(); NPCDB::unload(); @@ -903,6 +904,8 @@ int main(int argc, char *argv[]) ItemDB::load(); MonsterDB::load(); NPCDB::load(); + EmoteDB::load(); + state = CHAR_CONNECT_STATE; break; -- cgit v1.2.3-70-g09d2