@Override public void onDeath(Creature self, Creature killer) { if (self.isNpc()) { if (self.getNpcId() == HallAlarmDevice) { for (int i = 0; i < hallADoors.length; i++) openDoor(hallADoors[i]); blockUnblockNpcs(false, blockANpcs); for (NpcInstance n : getNpcs()) if (ArrayUtils.contains(blockANpcs, n.getNpcId())) n.getAI() .notifyEvent( CtrlEvent.EVT_AGGRESSION, getPlayers().get(Rnd.get(getPlayers().size())), 200); } else if (ArrayUtils.contains(blockANpcs, self.getNpcId())) { // ToCheck: find easier way for (NpcInstance n : getNpcs()) if (ArrayUtils.contains(blockANpcs, n.getNpcId()) && !n.isDead()) return; for (int i = 0; i < corridorADoors.length; i++) openDoor(corridorADoors[i]); blockUnblockNpcs(true, blockBNpcs); } else if (self.getNpcId() == DarkChoirPlayer) { for (NpcInstance n : getNpcs()) if (n.getNpcId() == DarkChoirPlayer && !n.isDead()) return; for (int i = 0; i < hallBDoors.length; i++) openDoor(hallBDoors[i]); blockUnblockNpcs(false, blockBNpcs); } else if (ArrayUtils.contains(blockBNpcs, self.getNpcId())) { if (Rnd.chance(10)) ((NpcInstance) self).dropItem(killer.getPlayer(), DewdropItem, 1); // ToCheck: find easier way for (NpcInstance n : getNpcs()) if ((ArrayUtils.contains(blockBNpcs, n.getNpcId()) || ArrayUtils.contains(blockANpcs, n.getNpcId())) && !n.isDead()) return; for (int i = 0; i < corridorBDoors.length; i++) openDoor(corridorBDoors[i]); ThreadPoolManager.getInstance().schedule(new FrintezzaStart(), battleStartDelay); } else if (self.getNpcId() == _weakScarletId) { self.decayMe(); return; } else if (self.getNpcId() == _strongScarletId) { ThreadPoolManager.getInstance().schedule(new Die(1), 10); setReenterTime(System.currentTimeMillis()); } } }