summaryrefslogtreecommitdiff
path: root/src/map/script.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/script.c')
-rw-r--r--src/map/script.c26
1 files changed, 2 insertions, 24 deletions
diff --git a/src/map/script.c b/src/map/script.c
index c06a69a60..d9f2bc2e0 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -13543,7 +13543,6 @@ BUILDIN_FUNC(setd)
return 0;
}
-#ifndef TXT_ONLY
int buildin_query_sql_sub(struct script_state* st, Sql* handle)
{
int i, j;
@@ -13643,22 +13642,14 @@ int buildin_query_sql_sub(struct script_state* st, Sql* handle)
script_pushint(st, i);
return 0;
}
-#endif
BUILDIN_FUNC(query_sql)
{
-#ifndef TXT_ONLY
return buildin_query_sql_sub(st, mmysql_handle);
-#else
- //for TXT version, we always return -1
- script_pushint(st,-1);
- return 0;
-#endif
}
BUILDIN_FUNC(query_logsql)
{
-#ifndef TXT_ONLY
if( !log_config.sql_logs )
{// logmysql_handle == NULL
ShowWarning("buildin_query_logsql: SQL logs are disabled, query '%s' will not be executed.\n", script_getstr(st,2));
@@ -13667,11 +13658,6 @@ BUILDIN_FUNC(query_logsql)
}
return buildin_query_sql_sub(st, logmysql_handle);
-#else
- //for TXT version, we always return -1
- script_pushint(st,-1);
- return 0;
-#endif
}
//Allows escaping of a given string.
@@ -13684,11 +13670,7 @@ BUILDIN_FUNC(escape_sql)
str = script_getstr(st,2);
len = strlen(str);
esc_str = (char*)aMallocA(len*2+1);
-#if defined(TXT_ONLY)
- jstrescapecpy(esc_str, str);
-#else
Sql_EscapeStringLen(mmysql_handle, esc_str, str, len);
-#endif
script_pushstr(st, esc_str);
return 0;
}
@@ -14709,9 +14691,8 @@ BUILDIN_FUNC(openmail)
if( sd == NULL )
return 0;
-#ifndef TXT_ONLY
mail_openmail(sd);
-#endif
+
return 0;
}
@@ -14723,9 +14704,8 @@ BUILDIN_FUNC(openauction)
if( sd == NULL )
return 0;
-#ifndef TXT_ONLY
clif_Auction_openwindow(sd);
-#endif
+
return 0;
}
@@ -14778,7 +14758,6 @@ BUILDIN_FUNC(setcell)
*------------------------------------------*/
BUILDIN_FUNC(mercenary_create)
{
-#ifndef TXT_ONLY
struct map_session_data *sd;
int class_, contract_time;
@@ -14792,7 +14771,6 @@ BUILDIN_FUNC(mercenary_create)
contract_time = script_getnum(st,3);
merc_create(sd, class_, contract_time);
-#endif
return 0;
}