コード例 #1
0
 public void NewNetStateTest()
 {
     NetState newNetState = null; // TODO: 初始化为适当的值
     BaseCharacter character = null; // TODO: 初始化为适当的值
     UpdatingNetStateEventArgs target = new UpdatingNetStateEventArgs( newNetState, character ); // TODO: 初始化为适当的值
     NetState actual;
     actual = target.NewNetState;
     Assert.Inconclusive( "验证此测试方法的正确性。" );
 }
コード例 #2
0
 public void IsCancelTest()
 {
     NetState newNetState = null; // TODO: 初始化为适当的值
     BaseCharacter character = null; // TODO: 初始化为适当的值
     UpdatingNetStateEventArgs target = new UpdatingNetStateEventArgs( newNetState, character ); // TODO: 初始化为适当的值
     bool expected = false; // TODO: 初始化为适当的值
     bool actual;
     target.IsCancel = expected;
     actual = target.IsCancel;
     Assert.AreEqual( expected, actual );
     Assert.Inconclusive( "验证此测试方法的正确性。" );
 }
コード例 #3
0
        /// <summary>
        ///
        /// </summary>
        internal bool OnUpdatingNetState(NetState netState, BaseCharacter creature)
        {
            EventHandler <UpdatingNetStateEventArgs> tempBeforeEventArgs = m_EventUpdatingNetState;

            if (tempBeforeEventArgs != null)
            {
                UpdatingNetStateEventArgs eventArgs = new UpdatingNetStateEventArgs(netState, creature);
                tempBeforeEventArgs(this, eventArgs);

                return(eventArgs.IsCancel);
            }

            return(false);
        }
コード例 #4
0
 public void UpdatingNetStateEventArgsConstructorTest()
 {
     NetState newNetState = null; // TODO: 初始化为适当的值
     BaseCharacter character = null; // TODO: 初始化为适当的值
     UpdatingNetStateEventArgs target = new UpdatingNetStateEventArgs( newNetState, character );
     Assert.Inconclusive( "TODO: 实现用来验证目标的代码" );
 }
コード例 #5
0
        /// <summary>
        /// 
        /// </summary>
        internal bool OnUpdatingNetState( NetState netState, BaseCharacter creature )
        {
            EventHandler<UpdatingNetStateEventArgs> tempBeforeEventArgs = m_EventUpdatingNetState;
            if ( tempBeforeEventArgs != null )
            {
                UpdatingNetStateEventArgs eventArgs = new UpdatingNetStateEventArgs( netState, creature );
                tempBeforeEventArgs( this, eventArgs );

                return eventArgs.IsCancel;
            }

            return false;
        }