- Fixed compilation error/warning on script command setbattleflag.

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@6323 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
skotlex 2006-04-27 18:27:43 +00:00
parent 234ac1fddc
commit 38a15cc4e1

View File

@ -6664,7 +6664,7 @@ int buildin_setmapflag(struct script_state *st)
{
int m,i;
char *str;
char *val;
char *val=NULL;
str=conv_str(st,& (st->stack->stack_data[st->start+2]));
i=conv_num(st,& (st->stack->stack_data[st->start+3]));
@ -6786,10 +6786,10 @@ int buildin_setmapflag(struct script_state *st)
map[m].flag.nocommand=1;
break;
case MF_JEXP:
map[m].jexp = (atoi(val) < 0) ? 100 : atoi(val);
map[m].jexp = (!val || atoi(val) < 0) ? 100 : atoi(val);
break;
case MF_BEXP:
map[m].bexp = (atoi(val) < 0) ? 100 : atoi(val);
map[m].bexp = (!val || atoi(val) < 0) ? 100 : atoi(val);
break;
}
}