summaryrefslogtreecommitdiff
path: root/src/map/script.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-09-27 01:15:54 +0300
committerAndrei Karas <akaras@inbox.ru>2015-10-01 16:53:09 +0300
commite2af86e0d45f9f0bac839120ca350a031246f624 (patch)
tree083f4a428be2e4ce9153afdb4d534c3a598d1feb /src/map/script.h
parentf6574152b049f6c5d7370e600b4c5b07cbcae13c (diff)
downloadhercules-e2af86e0d45f9f0bac839120ca350a031246f624.tar.gz
hercules-e2af86e0d45f9f0bac839120ca350a031246f624.tar.bz2
hercules-e2af86e0d45f9f0bac839120ca350a031246f624.tar.xz
hercules-e2af86e0d45f9f0bac839120ca350a031246f624.zip
Split function set_reg and get_val into functions based on variable types.
Diffstat (limited to 'src/map/script.h')
-rw-r--r--src/map/script.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/map/script.h b/src/map/script.h
index ad8ae82cb..ff660dec8 100644
--- a/src/map/script.h
+++ b/src/map/script.h
@@ -629,6 +629,14 @@ struct script_interface {
void (*detach_rid) (struct script_state* st);
struct script_data* (*push_val)(struct script_stack* stack, enum c_op type, int64 val, struct reg_db *ref);
struct script_data *(*get_val) (struct script_state* st, struct script_data* data);
+ char* (*get_val_ref_str) (struct script_state* st, struct reg_db *n, struct script_data* data);
+ char* (*get_val_scope_str) (struct script_state* st, struct reg_db *n, struct script_data* data);
+ char* (*get_val_npc_str) (struct script_state* st, struct reg_db *n, struct script_data* data);
+ char* (*get_val_instance_str) (struct script_state* st, const char* name, struct script_data* data);
+ int (*get_val_ref_num) (struct script_state* st, struct reg_db *n, struct script_data* data);
+ int (*get_val_scope_num) (struct script_state* st, struct reg_db *n, struct script_data* data);
+ int (*get_val_npc_num) (struct script_state* st, struct reg_db *n, struct script_data* data);
+ int (*get_val_instance_num) (struct script_state* st, const char* name, struct script_data* data);
void* (*get_val2) (struct script_state* st, int64 uid, struct reg_db *ref);
struct script_data* (*push_str) (struct script_stack* stack, enum c_op type, char* str);
struct script_data* (*push_copy) (struct script_stack* stack, int pos);
@@ -696,6 +704,14 @@ struct script_interface {
const char* (*print_line) (StringBuf *buf, const char *p, const char *mark, int line);
void (*errorwarning_sub) (StringBuf *buf, const char *src, const char *file, int start_line, const char *error_msg, const char *error_pos);
int (*set_reg) (struct script_state *st, TBL_PC *sd, int64 num, const char *name, const void *value, struct reg_db *ref);
+ void (*set_reg_ref_str) (struct script_state* st, struct reg_db *n, int64 num, const char* name, const char *str);
+ void (*set_reg_scope_str) (struct script_state* st, struct reg_db *n, int64 num, const char* name, const char *str);
+ void (*set_reg_npc_str) (struct script_state* st, struct reg_db *n, int64 num, const char* name, const char *str);
+ void (*set_reg_instance_str) (struct script_state* st, int64 num, const char* name, const char *str);
+ void (*set_reg_ref_num) (struct script_state* st, struct reg_db *n, int64 num, const char* name, int val);
+ void (*set_reg_scope_num) (struct script_state* st, struct reg_db *n, int64 num, const char* name, int val);
+ void (*set_reg_npc_num) (struct script_state* st, struct reg_db *n, int64 num, const char* name, int val);
+ void (*set_reg_instance_num) (struct script_state* st, int64 num, const char* name, int val);
void (*stack_expand) (struct script_stack *stack);
struct script_data* (*push_retinfo) (struct script_stack *stack, struct script_retinfo *ri, struct reg_db *ref);
void (*op_3) (struct script_state *st, int op);