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.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map/script.c b/src/map/script.c
index a5e29026d..da7891924 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -5061,13 +5061,13 @@ int buildin_agitcheck(struct script_state *st)
struct map_session_data *sd;
int cond;
- sd=script_rid2sd(st);
cond=conv_num(st,& (st->stack->stack_data[st->start+2]));
if(cond == 0) {
if (agit_flag==1) push_val(st->stack,C_INT,1);
if (agit_flag==0) push_val(st->stack,C_INT,0);
} else {
+ sd=script_rid2sd(st);
if (agit_flag==1) pc_setreg(sd,add_str("@agit_flag"),1);
if (agit_flag==0) pc_setreg(sd,add_str("@agit_flag"),0);
}