summaryrefslogtreecommitdiff
path: root/src/map/script.c
diff options
context:
space:
mode:
authorInkfish <Inkfish@54d463be-8e91-2dee-dedb-b68131a5f0ec>2009-07-28 04:04:50 +0000
committerInkfish <Inkfish@54d463be-8e91-2dee-dedb-b68131a5f0ec>2009-07-28 04:04:50 +0000
commit5129aec41d33947923a91604647a5936e49ae009 (patch)
tree1b10aa011002f1b475ace9a9136673377e13e285 /src/map/script.c
parenta269c22b8d92b56a6b09bc2fa8375d1803cab909 (diff)
downloadhercules-5129aec41d33947923a91604647a5936e49ae009.tar.gz
hercules-5129aec41d33947923a91604647a5936e49ae009.tar.bz2
hercules-5129aec41d33947923a91604647a5936e49ae009.tar.xz
hercules-5129aec41d33947923a91604647a5936e49ae009.zip
* Some more updates to Quest Log
- Implemented a new saving mechanism. Now they can be saved every 'autosave_time' in case the char-server is not online when you get a quest. - Improved 'changequest' code. - Increase MAX_QUEST_DB to 1200. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13973 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/script.c')
-rw-r--r--src/map/script.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/src/map/script.c b/src/map/script.c
index a2a60c13d..184e9121c 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -13447,21 +13447,14 @@ BUILDIN_FUNC(completequest)
TBL_PC * sd = script_rid2sd(st);
quest_update_status(sd, script_getnum(st, 2), Q_COMPLETE);
- intif_quest_save(sd->status.char_id, &sd->quest_log[sd->avail_quests]);
return 0;
}
BUILDIN_FUNC(changequest)
{
TBL_PC * sd = script_rid2sd(st);
- int q1 = script_getnum(st, 2), q2 = script_getnum(st, 3);
-
- if( quest_check_quest(sd, q1, HAVEQUEST) == Q_ACTIVE && !quest_add(sd, q2) )
- {
- quest_update_status(sd, q1, Q_COMPLETE);
- intif_quest_save(sd->status.char_id, &sd->quest_log[sd->avail_quests]);
- }
+ quest_change(sd, script_getnum(st, 2),script_getnum(st, 3));
return 0;
}
@@ -13473,7 +13466,7 @@ BUILDIN_FUNC(checkquest)
if( script_hasdata(st, 3) )
type = (quest_check_type)script_getnum(st, 3);
- script_pushint(st, quest_check_quest(sd, script_getnum(st, 2), type));
+ script_pushint(st, quest_check(sd, script_getnum(st, 2), type));
return 0;
}