summaryrefslogtreecommitdiff
path: root/src/map/pc.c
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.c
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.c')
-rw-r--r--src/map/pc.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 602b67a26..d0f5b0635 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -1136,7 +1136,12 @@ bool pc_authok(struct map_session_data *sd, int login_id2, time_t expiration_tim
for( i = 0; i < 3; i++ )
sd->hate_mob[i] = -1;
- //warp player
+ sd->quest_log = NULL;
+ sd->num_quests = 0;
+ sd->avail_quests = 0;
+ sd->save_quest = false;
+
+ //warp player
if ((i=pc->setpos(sd,sd->status.last_point.map, sd->status.last_point.x, sd->status.last_point.y, CLR_OUTSIGHT)) != 0) {
ShowError ("Last_point_map %s - id %d not found (error code %d)\n", mapindex_id2name(sd->status.last_point.map), sd->status.last_point.map, i);