diff options
author | Dastgir <dastgirp@gmail.com> | 2018-10-01 23:52:39 +0530 |
---|---|---|
committer | Dastgir <dastgirp@gmail.com> | 2018-10-13 16:40:01 +0530 |
commit | a3187aaf7916354efb78ca41f2c9e916e29d61db (patch) | |
tree | c6fecf708d52750e017ebdf070f320dea3ff5b54 /src/map/achievement.c | |
parent | 852c13305f67948531bd0277eb1922dbd02b1f26 (diff) | |
download | hercules-a3187aaf7916354efb78ca41f2c9e916e29d61db.tar.gz hercules-a3187aaf7916354efb78ca41f2c9e916e29d61db.tar.bz2 hercules-a3187aaf7916354efb78ca41f2c9e916e29d61db.tar.xz hercules-a3187aaf7916354efb78ca41f2c9e916e29d61db.zip |
Fixed Assertion Error when refine is failed.
Fixes #2217
Diffstat (limited to 'src/map/achievement.c')
-rw-r--r-- | src/map/achievement.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/map/achievement.c b/src/map/achievement.c index 1fb513ea0..ef70da500 100644 --- a/src/map/achievement.c +++ b/src/map/achievement.c @@ -772,6 +772,10 @@ static void achievement_validate_refine(struct map_session_data *sd, unsigned in criteria.goal = sd->status.inventory[idx].refine; + // achievement should not trigger if refine is 0 + if (criteria.goal == 0) + return; + /* Universal */ achievement->validate_type(sd, success ? ACH_EQUIP_REFINE_SUCCESS : ACH_EQUIP_REFINE_FAILURE, |