summaryrefslogtreecommitdiff
path: root/npc/functions/main.txt
diff options
context:
space:
mode:
Diffstat (limited to 'npc/functions/main.txt')
-rw-r--r--npc/functions/main.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/npc/functions/main.txt b/npc/functions/main.txt
index e1b93fa46..b54401e02 100644
--- a/npc/functions/main.txt
+++ b/npc/functions/main.txt
@@ -330,6 +330,13 @@ function script gf_accid {
return .@value[0];
}
+// Get some char id, even if offline
+// ( Name )
+function script gf_charnameid {
+ .@nb = query_sql("SELECT char_id FROM `char` WHERE name='"+escape_sql(getarg(0))+"' LIMIT 2", .@value);
+ return .@value[0];
+}
+
// Get some char name from char ID, even if offline
// ( Name )
function script gf_charname {