From cccc5bc9256b196b1f4e9ad881838ad32c8b3424 Mon Sep 17 00:00:00 2001 From: malufett Date: Mon, 26 Aug 2013 18:02:40 +0800 Subject: Fixed Bug#7584 -Where HW_SOULDRAIN should work only in single target. Fixed Bug#7670 -Where PA_GOSPEL is not working properly. Fixed Bug#7668 -Bonus 'bLongAtkRate' is not working properly. Fixed Bug#7512 -Bonus 'bCritAtkRate' is not working properly. Fixed Bug#7515 -Fixed MO_EXTREMITYFIST animation. -Fixed RE armor/weapon storage tab positioning. -Fixed HW_MAGICPOWER cast time. -Fixed '/item' '/monster' aegis command where it not working properly in some item names or monsters. -Added NC_DISJOINT cast time hidden modifier. -Updated RE ATK for post damage modifier. Signed-off-by: malufett --- src/map/mob.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) (limited to 'src/map/mob.c') diff --git a/src/map/mob.c b/src/map/mob.c index b181c9b7b..291f04267 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -110,17 +110,24 @@ int mobdb_searchname(const char *str) return 0; } -static int mobdb_searchname_array_sub(struct mob_db* mob, const char *str) +static int mobdb_searchname_array_sub(struct mob_db* mob, const char *str, int flag) { if (mob == mob_dummy) return 1; if(!mob->base_exp && !mob->job_exp && mob->spawn[0].qty < 1) return 1; // Monsters with no base/job exp and no spawn point are, by this criteria, considered "slave mobs" and excluded from search results - if(stristr(mob->jname,str)) + if( !flag ){ + if(stristr(mob->jname,str)) + return 0; + if(stristr(mob->name,str)) + return 0; + return strcmpi(mob->jname,str); + } + if(strcmp(mob->jname,str) == 0) return 0; - if(stristr(mob->name,str)) + if(strcmp(mob->name,str) == 0) return 0; - return strcmpi(mob->jname,str); + return strcmp(mob->sprite,str); } /*========================================== @@ -194,7 +201,7 @@ void mvptomb_destroy(struct mob_data *md) { /*========================================== * Founds up to N matches. Returns number of matches [Skotlex] *------------------------------------------*/ -int mobdb_searchname_array(struct mob_db** data, int size, const char *str) +int mobdb_searchname_array(struct mob_db** data, int size, const char *str, int flag) { int count = 0, i; struct mob_db* mob; @@ -202,7 +209,7 @@ int mobdb_searchname_array(struct mob_db** data, int size, const char *str) mob = mob_db(i); if (mob == mob_dummy || mob_is_clone(i) ) //keep clones out (or you leak player stats) continue; - if (!mobdb_searchname_array_sub(mob, str)) { + if (!mobdb_searchname_array_sub(mob, str, flag)) { if (count < size) data[count] = mob; count++; -- cgit v1.2.3-70-g09d2