summaryrefslogtreecommitdiff
path: root/src/char/int_quest.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-11-09 21:09:03 +0300
committerAndrei Karas <akaras@inbox.ru>2014-11-15 11:47:30 +0300
commitc60c9292886f436eb12d4042a05af1e462705e3d (patch)
treed6a5cd0f78d9c845e966e18ecfb386e0b31515b2 /src/char/int_quest.c
parent63075b84ecf52e329ee524e1e90878469c388f9d (diff)
downloadhercules-c60c9292886f436eb12d4042a05af1e462705e3d.tar.gz
hercules-c60c9292886f436eb12d4042a05af1e462705e3d.tar.bz2
hercules-c60c9292886f436eb12d4042a05af1e462705e3d.tar.xz
hercules-c60c9292886f436eb12d4042a05af1e462705e3d.zip
Move global variable into interface in inter.c
Diffstat (limited to 'src/char/int_quest.c')
-rw-r--r--src/char/int_quest.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/char/int_quest.c b/src/char/int_quest.c
index 978ee8f37..a5721c430 100644
--- a/src/char/int_quest.c
+++ b/src/char/int_quest.c
@@ -44,7 +44,7 @@ struct quest *mapif_quests_fromsql(int char_id, int *count)
if (!count)
return NULL;
- stmt = SQL->StmtMalloc(sql_handle);
+ stmt = SQL->StmtMalloc(inter->sql_handle);
if (stmt == NULL) {
SqlStmt_ShowDebug(stmt);
*count = 0;
@@ -112,8 +112,8 @@ struct quest *mapif_quests_fromsql(int char_id, int *count)
*/
bool mapif_quest_delete(int char_id, int quest_id)
{
- if (SQL_ERROR == SQL->Query(sql_handle, "DELETE FROM `%s` WHERE `quest_id` = '%d' AND `char_id` = '%d'", quest_db, quest_id, char_id)) {
- Sql_ShowDebug(sql_handle);
+ if (SQL_ERROR == SQL->Query(inter->sql_handle, "DELETE FROM `%s` WHERE `quest_id` = '%d' AND `char_id` = '%d'", quest_db, quest_id, char_id)) {
+ Sql_ShowDebug(inter->sql_handle);
return false;
}
@@ -142,8 +142,8 @@ bool mapif_quest_add(int char_id, struct quest qd)
StrBuf->Printf(&buf, ", '%d'", qd.count[i]);
}
StrBuf->AppendStr(&buf, ")");
- if (SQL_ERROR == SQL->Query(sql_handle, StrBuf->Value(&buf))) {
- Sql_ShowDebug(sql_handle);
+ if (SQL_ERROR == SQL->Query(inter->sql_handle, StrBuf->Value(&buf))) {
+ Sql_ShowDebug(inter->sql_handle);
StrBuf->Destroy(&buf);
return false;
}
@@ -171,8 +171,8 @@ bool mapif_quest_update(int char_id, struct quest qd)
}
StrBuf->Printf(&buf, " WHERE `quest_id` = '%d' AND `char_id` = '%d'", qd.quest_id, char_id);
- if (SQL_ERROR == SQL->Query(sql_handle, StrBuf->Value(&buf))) {
- Sql_ShowDebug(sql_handle);
+ if (SQL_ERROR == SQL->Query(inter->sql_handle, StrBuf->Value(&buf))) {
+ Sql_ShowDebug(inter->sql_handle);
StrBuf->Destroy(&buf);
return false;
}