Example #1
0
        public static void RemoveEffect( Mobile m )
        {
            if ( !m_SleptTable.ContainsKey( m ) )
                return;

            SleepContext context = m_SleptTable[m];

            context.Timer.Stop();

            foreach ( AttributeMod mod in context.Mods )
            {
                m.RemoveAttributeMod( mod );
            }

            m_SleptTable.Remove( m );

            BuffInfo.RemoveBuff( m, BuffIcon.Sleep );
            m.ForcedWalk = false;
        }
Example #2
0
 private static void RemoveMods( Mobile m, List<AttributeMod> mods )
 {
     for ( int i = 0; i < mods.Count; i++ )
         m.RemoveAttributeMod( mods[i] );
 }
Example #3
0
        private static void RemoveMods( Mobile m, List<object> mods )
        {
            for ( int i = 0; i < mods.Count; i++ )
            {
                object mod = mods[i];

                if ( mod is AttributeMod )
                    m.RemoveAttributeMod( (AttributeMod) mod );
                else if ( mod is ResistanceMod )
                    m.RemoveResistanceMod( (ResistanceMod) mod );
            }
        }