示例#1
0
        public void Talk(Ferret to)
        {
            if (m_CanTalk)
            {
                Say(m_Vocabulary[Utility.Random(m_Vocabulary.Length)]);

                if (to != null && Utility.RandomBool())
                {
                    Timer.DelayCall(TimeSpan.FromSeconds(Utility.RandomMinMax(5, 8)), new TimerCallback(delegate() { to.Talk(); }));
                }

                m_CanTalk = false;

                Timer.DelayCall(TimeSpan.FromSeconds(Utility.RandomMinMax(20, 30)), new TimerCallback(delegate() { m_CanTalk = true; }));
            }
        }
示例#2
0
		public void Talk( Ferret to )
		{		
			if ( m_CanTalk )
			{
				if ( to != null )
					QuestSystem.FocusTo( this, to );
					
				Say( m_Vocabulary[ Utility.Random( m_Vocabulary.Length ) ] );
			
				if ( to != null && Utility.RandomBool() )
					Timer.DelayCall( TimeSpan.FromSeconds( Utility.RandomMinMax( 5, 8 ) ), new TimerCallback( delegate() { to.Talk(); } ) );
			
				m_CanTalk = false;
				
				Timer.DelayCall( TimeSpan.FromSeconds( Utility.RandomMinMax( 20, 30 ) ), new TimerCallback( delegate() { m_CanTalk = true; } ) );
			}
		}
示例#3
0
文件: Ferret.cs 项目: silky/ModernUO
        public void Talk(Ferret to)
        {
            if (m_CanTalk)
            {
                if (to != null)
                    QuestSystem.FocusTo(this, to);

                Say(m_Vocabulary.RandomElement());

                if (to != null && Utility.RandomBool())
                    Timer.DelayCall(TimeSpan.FromSeconds(Utility.RandomMinMax(5, 8)), to.Talk);

                m_CanTalk = false;

                Timer.DelayCall(TimeSpan.FromSeconds(Utility.RandomMinMax(20, 30)), ResetCanTalk);
            }
        }
示例#4
0
        public void Talk(Ferret to)
        {
            if (m_CanTalk)
            {
                if (to != null)
                {
                    QuestSystem.FocusTo(this, to);
                }

                Say(m_Vocabulary[Utility.Random(m_Vocabulary.Length)]);

                if (to != null && Utility.RandomBool())
                {
                    Timer.DelayCall(TimeSpan.FromSeconds(Utility.RandomMinMax(5, 8)), delegate { to.Talk(); });
                }

                m_CanTalk = false;

                Timer.DelayCall(TimeSpan.FromSeconds(Utility.RandomMinMax(20, 30)), delegate { this.m_CanTalk = true; });
            }
        }