summaryrefslogtreecommitdiff
path: root/src/map/mob.c
diff options
context:
space:
mode:
authorglighta <glighta@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-11-12 01:54:56 +0000
committerglighta <glighta@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-11-12 01:54:56 +0000
commit94898ebfcf8ccdae5b064fa27f843136c19e2a65 (patch)
tree144b6104b30e2df0bcaa77b3ef096af206d569f7 /src/map/mob.c
parent0f715fc0dbaa5c2327a951d107e971f3d7ebd216 (diff)
downloadhercules-94898ebfcf8ccdae5b064fa27f843136c19e2a65.tar.gz
hercules-94898ebfcf8ccdae5b064fa27f843136c19e2a65.tar.bz2
hercules-94898ebfcf8ccdae5b064fa27f843136c19e2a65.tar.xz
hercules-94898ebfcf8ccdae5b064fa27f843136c19e2a65.zip
-Upd mob_count to read a 10 modib list to chk if present or not
-Add UNLIMITED_HUMMING implementation, now increase sp requirement and make cast unbreakable -Upd Group dance overlaping A and B, previous chk wasn't ending other properly (if fail was skipping other) -Upd OdinPower effect -Fix Cursed-Circle, shoudn't be able to cast near Emp,Stones bugreport:6457 -Fix Cursed-Circle wasn't remove when caster was being warped -Small docs upd git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16918 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/mob.c')
-rw-r--r--src/map/mob.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/map/mob.c b/src/map/mob.c
index 6c221e662..56be06b2d 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -881,9 +881,15 @@ int mob_setdelayspawn(struct mob_data *md)
return 0;
}
-static int mob_count_sub(struct block_list *bl,va_list ap)
-{
- return 1;
+int mob_count_sub(struct block_list *bl, va_list ap) {
+ int mobid[10], i;
+ ARR_FIND(0, 10, i, (mobid[i] = va_arg(ap, int)) == 0); //fetch till 0
+ if (mobid[0]) { //if there one let's check it otherwise go backward
+ TBL_MOB *md = BL_CAST(BL_MOB, bl);
+ ARR_FIND(0, 10, i, md->class_ == mobid[i]);
+ return (i < 10) ? 1 : 0;
+ }
+ return 1; //backward compatibility
}
/*==========================================