@Override public void executeMsg(Environmental host, CMMsg msg) { super.executeMsg(host, msg); if ((affected instanceof Item) && (text().length() > 0)) { final Item I = (Item) affected; if ((msg.sourceMinor() == CMMsg.TYP_SPEAK) && (msg.target() == I) && ((msg.source() == I.owner()) || (I.owner() instanceof Room)) && (msg.sourceMessage() != null) && (CMLib.english() .containsString( CMStrings.getSayFromMessage(msg.sourceMessage()).toUpperCase(), "REFUGE"))) { final Room newRoom = this.getRefuge(I); if ((newRoom != null) && (newRoom != msg.source().location())) { final Set<MOB> h = properTargets(msg.source(), null, false); if (h == null) return; final Room thisRoom = msg.source().location(); final Ability thisA = this; msg.addTrailerRunnable( new Runnable() { @Override public void run() { for (final Object element : h) { final MOB follower = (MOB) element; final CMMsg enterMsg = CMClass.getMsg( follower, newRoom, thisA, CMMsg.MSG_ENTER, null, CMMsg.MSG_ENTER, null, CMMsg.MSG_ENTER, L( "<S-NAME> appears in a puff of smoke.@x1", CMLib.protocol().msp("appear.wav", 10))); final CMMsg leaveMsg = CMClass.getMsg( follower, thisRoom, thisA, CMMsg.MSG_LEAVE | CMMsg.MASK_MAGIC, L("<S-NAME> disappear(s) in a puff of smoke.")); if (thisRoom.okMessage(follower, leaveMsg) && newRoom.okMessage(follower, enterMsg)) { if (follower.isInCombat()) { CMLib.commands().postFlee(follower, ("NOWHERE")); follower.makePeace(); } thisRoom.send(follower, leaveMsg); newRoom.bringMobHere(follower, false); newRoom.send(follower, enterMsg); follower.tell(L("\n\r\n\r")); CMLib.commands().postLook(follower, true); } } } }); unInvoke(); } } } }