@Override
	public boolean invoke(MOB mob, Vector commands, Physical givenTarget, boolean auto, int asLevel)
	{
		if(!CMLib.flags().aliveAwakeMobile(mob,false))
			return false;

		final Ability A=mob.fetchEffect(ID());
		if(A!=null)
		{
			A.unInvoke();
			mob.tell(_("You end your all-out defensive posture."));
			return true;
		}
		if(!mob.isInCombat())
		{
			mob.tell(_("You must be in combat to defend!"));
			return false;
		}

		if((!auto)&&(!(CMLib.flags().isGood(mob))))
		{
			mob.tell(_("You don't feel worthy of a good defence."));
			return false;
		}
		if(!super.invoke(mob,commands,mob,auto,asLevel))
			return false;

		final boolean success=proficiencyCheck(mob,0,auto);

		if(success)
		{
			// it worked, so build a copy of this ability,
			// and add it to the affects list of the
			// affected MOB.  Then tell everyone else
			// what happened.
			final CMMsg msg=CMClass.getMsg(mob,null,this,CMMsg.MSG_CAST_SOMANTIC_SPELL,_("^S<S-NAME> assume(s) an all-out defensive posture.^?"));
			if(mob.location().okMessage(mob,msg))
			{
				mob.location().send(mob,msg);
				fullRound=false;
				beneficialAffect(mob,mob,asLevel,Ability.TICKS_FOREVER);
			}
		}
		else
			return beneficialVisualFizzle(mob,null,_("<S-NAME> attempt(s) to assume an all-out defensive posture, but fail(s)."));


		// return whether it worked
		return success;
	}