From 9a83b5ad626f8bfd4011277173e8bf385e4971fe Mon Sep 17 00:00:00 2001 From: skotlex Date: Fri, 19 Oct 2007 20:31:57 +0000 Subject: - Added bonusautoscript and bonusautoscript2. These are used to attach a script to a player which gets executed on attack (or when attacked). Required for several of the more recent items. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11519 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/status.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/map/status.c') diff --git a/src/map/status.c b/src/map/status.c index 7148005c9..a8e360469 100644 --- a/src/map/status.c +++ b/src/map/status.c @@ -1642,7 +1642,7 @@ int status_calc_pc(struct map_session_data* sd,int first) sd->def_rate = sd->def2_rate = sd->mdef_rate = sd->mdef2_rate = 100; sd->regen.state.block = 0; - // zeroed arays, order follows the order in map.h. + // zeroed arrays, order follows the order in map.h. // add new arrays to the end of zeroed area in map.h (see comments) and size here. [zzo] memset (sd->param_bonus, 0, sizeof(sd->param_bonus) + sizeof(sd->param_equip) @@ -1715,7 +1715,10 @@ int status_calc_pc(struct map_session_data* sd,int first) + sizeof(sd->add_drop) + sizeof(sd->itemhealrate) ); - + // clear autoscripts... + pc_autoscript_clear(sd->autoscript, ARRAYLENGTH(sd->autoscript)); + pc_autoscript_clear(sd->autoscript2, ARRAYLENGTH(sd->autoscript2)); + // vars zeroing. ints, shorts, chars. in that order. memset (&sd->arrow_atk, 0,sizeof(sd->arrow_atk) + sizeof(sd->arrow_ele) -- cgit v1.2.3-70-g09d2