diff options
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/script.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/map/script.c b/src/map/script.c index 60672e5e7..0b4435351 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -4669,7 +4669,10 @@ BUILDIN_FUNC(input) if( postfix == '$' ) set_reg(st,sd,num,name,(void*)sd->npc_str,script_getref(st,2)); else + { + sd->npc_amount = cap_value(sd->npc_amount, 0, INT_MAX); set_reg(st,sd,num,name,(void*)sd->npc_amount,script_getref(st,2)); + } } return 0; } |