summaryrefslogtreecommitdiff
path: root/src/map/script-call-internal.hpp
diff options
context:
space:
mode:
authormekolat <mekolat@users.noreply.github.com>2016-04-19 09:41:31 -0400
committermekolat <mekolat@users.noreply.github.com>2016-04-19 09:41:31 -0400
commit1ba24673e7064e39406e6faf11d790c2dcc2ac00 (patch)
tree7e2645f6fdec1dcc63ae56366371246f62865dcd /src/map/script-call-internal.hpp
parentc3e06ffe6437d27a2a7c6ddb2dc487ff2f007adf (diff)
parentc786a93e91adaf68780a5fd7585f51d0528f92ed (diff)
downloadtmwa-1ba24673e7064e39406e6faf11d790c2dcc2ac00.tar.gz
tmwa-1ba24673e7064e39406e6faf11d790c2dcc2ac00.tar.bz2
tmwa-1ba24673e7064e39406e6faf11d790c2dcc2ac00.tar.xz
tmwa-1ba24673e7064e39406e6faf11d790c2dcc2ac00.zip
Merge self-fork from mekolat/magic-v3
Magic v3
Diffstat (limited to 'src/map/script-call-internal.hpp')
-rw-r--r--src/map/script-call-internal.hpp18
1 files changed, 14 insertions, 4 deletions
diff --git a/src/map/script-call-internal.hpp b/src/map/script-call-internal.hpp
index a887eb8..da6c082 100644
--- a/src/map/script-call-internal.hpp
+++ b/src/map/script-call-internal.hpp
@@ -25,6 +25,8 @@
#include "../mmo/ids.hpp"
+#include "../strings/rstring.hpp"
+#include "../generic/db.hpp"
#include "script-persist.hpp"
@@ -55,6 +57,13 @@ public:
ScriptPointer scriptp, new_scriptp;
int defsp, new_defsp, freeloop;
int is_true = 0;
+
+ // register keys are ints (interned)
+ // Not anymore! Well, sort of.
+ DMap<SIR, int> regm;
+ // can't be DMap because we want predictable .c_str()s
+ // TODO this can change now
+ Map<SIR, RString> regstrm;
};
void run_func(ScriptState *st);
@@ -70,13 +79,14 @@ enum class ScriptEndState
};
dumb_ptr<map_session_data> script_rid2sd(ScriptState *st);
-void get_val(dumb_ptr<map_session_data> sd, struct script_data *data);
+void get_val(dumb_ptr<block_list> sd, struct script_data *data);
__attribute__((deprecated))
void get_val(ScriptState *st, struct script_data *data);
struct script_data get_val2(ScriptState *st, SIR reg);
-void set_reg(dumb_ptr<map_session_data> sd, VariableCode type, SIR reg, struct script_data vd);
-void set_reg(dumb_ptr<map_session_data> sd, VariableCode type, SIR reg, int id);
-void set_reg(dumb_ptr<map_session_data> sd, VariableCode type, SIR reg, RString zd);
+void set_scope_reg(ScriptState *, SIR, struct script_data *);
+void set_reg(dumb_ptr<block_list> sd, VariableCode type, SIR reg, struct script_data vd);
+void set_reg(dumb_ptr<block_list> sd, VariableCode type, SIR reg, int id);
+void set_reg(dumb_ptr<block_list> sd, VariableCode type, SIR reg, RString zd);
__attribute__((warn_unused_result))
RString conv_str(ScriptState *st, struct script_data *data);
__attribute__((warn_unused_result))