summaryrefslogtreecommitdiff
path: root/src/map/pc.h
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2013-11-27 03:21:45 +0100
committerHaru <haru@dotalux.com>2013-12-03 16:28:08 +0100
commit6f55c00e72ca6db130a84fe92218f73a777428f4 (patch)
treee3f25d1ad5b3dbb06371941fc9fd8cb66a5411a9 /src/map/pc.h
parent470ab15023f09dc823e8ce8ac818e0bbe8a95aef (diff)
downloadhercules-6f55c00e72ca6db130a84fe92218f73a777428f4.tar.gz
hercules-6f55c00e72ca6db130a84fe92218f73a777428f4.tar.bz2
hercules-6f55c00e72ca6db130a84fe92218f73a777428f4.tar.xz
hercules-6f55c00e72ca6db130a84fe92218f73a777428f4.zip
Questlog fixes
- Improved memory usage of the quest log system. (saves up to 75kB per online character). Fixes issue #133. - Fixed various issues with quest entries disappearing from characters without an apparent reason, or monster kill counters getting stuck - the issues were caused by a de-synchronization between the two parallel questlog arrays in map_session_data. - Added some code documentation. - Thanks to Ind. Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/map/pc.h')
-rw-r--r--src/map/pc.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/map/pc.h b/src/map/pc.h
index 2c802a896..5f81346d4 100644
--- a/src/map/pc.h
+++ b/src/map/pc.h
@@ -438,12 +438,11 @@ struct map_session_data {
bool changed; // if true, should sync with charserver on next mailbox request
} mail;
- //Quest log system [Kevin] [Inkfish]
- int num_quests;
- int avail_quests;
- int quest_index[MAX_QUEST_DB];
- struct quest quest_log[MAX_QUEST_DB];
- bool save_quest;
+ // Quest log system
+ int num_quests; ///< Number of entries in quest_log
+ int avail_quests; ///< Number of Q_ACTIVE and Q_INACTIVE entries in quest log (index of the first Q_COMPLETE entry)
+ struct quest *quest_log; ///< Quest log entries (note: Q_COMPLETE quests follow the first <avail_quests>th enties
+ bool save_quest; ///< Whether the quest_log entries were modified and are waitin to be saved
// temporary debug [flaviojs]
const char* debug_file;