|
@@ -25812,6 +25812,26 @@ BUILDIN_FUNC(randomoptgroup)
|
|
|
return SCRIPT_CMD_SUCCESS;
|
|
|
}
|
|
|
|
|
|
+BUILDIN_FUNC( open_quest_ui ){
|
|
|
+ struct map_session_data* sd;
|
|
|
+
|
|
|
+ if (!script_charid2sd(3, sd))
|
|
|
+ return SCRIPT_CMD_FAILURE;
|
|
|
+
|
|
|
+ int quest_id = script_hasdata(st, 2) ? script_getnum(st, 2) : 0;
|
|
|
+
|
|
|
+ if( quest_id != 0 ){
|
|
|
+ int i;
|
|
|
+ ARR_FIND(0, sd->avail_quests, i, sd->quest_log[i].quest_id == quest_id);
|
|
|
+ if (i == sd->avail_quests)
|
|
|
+ ShowWarning("buildin_open_quest_ui: Character %d doesn't have quest %d.\n", sd->status.char_id, quest_id);
|
|
|
+ }
|
|
|
+
|
|
|
+ clif_ui_open( sd, OUT_UI_QUEST, quest_id );
|
|
|
+
|
|
|
+ return SCRIPT_CMD_SUCCESS;
|
|
|
+}
|
|
|
+
|
|
|
#include "../custom/script.inc"
|
|
|
|
|
|
// declarations that were supposed to be exported from npc_chat.cpp
|
|
@@ -26524,6 +26544,7 @@ struct script_function buildin_func[] = {
|
|
|
BUILDIN_DEF(laphine_synthesis, ""),
|
|
|
BUILDIN_DEF(laphine_upgrade, ""),
|
|
|
BUILDIN_DEF(randomoptgroup,"i"),
|
|
|
+ BUILDIN_DEF(open_quest_ui, "??"),
|
|
|
#include "../custom/script_def.inc"
|
|
|
|
|
|
{NULL,NULL,NULL},
|