当前位置: 首页>>代码示例>>C#>>正文


C# Server.GetBoolean方法代码示例

本文整理汇总了C#中Server.Server.GetBoolean方法的典型用法代码示例。如果您正苦于以下问题:C# Server.GetBoolean方法的具体用法?C# Server.GetBoolean怎么用?C# Server.GetBoolean使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Server.Server的用法示例。


在下文中一共展示了Server.GetBoolean方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Animate_OnCommand

 public static void Animate_OnCommand( Server.Commands.CommandEventArgs e )
 {
     if ( e.Length == 6 )
     {
         e.Mobile.Animate( e.GetInt32( 0 ), e.GetInt32( 1 ), e.GetInt32( 2 ), e.GetBoolean( 3 ), e.GetBoolean( 4 ), e.GetInt32( 5 ) );
     }
     else
     {
         e.Mobile.SendAsciiMessage( "Format: Animate <action> <frameCount> <repeatCount> <forward> <repeat> <delay>" );
     }
 }
开发者ID:FreeReign,项目名称:Rebirth-Repack,代码行数:11,代码来源:Handlers.cs

示例2: Randomize_OnCommand

		public static void Randomize_OnCommand( Server.Commands.CommandEventArgs args )
		{
			Mobile m = args.Mobile;

			if( args.Length != 4 )
			{
				m.SendMessage( "Format: Randomize <starting itemID> <ending itemID> <Z level> <bool includeNonFlooring>" );
				return;
			}

			int start = args.GetInt32( 0 );
			int end = args.GetInt32( 1 );
			int z = args.GetInt32( 2 );
			bool walls = args.GetBoolean( 3 );

			object[] state = new object[4] { start, end, z, walls };

			BoundingBoxPicker.Begin( m, new BoundingBoxCallback( BoxPickerCallback ), state );
		}
开发者ID:greeduomacro,项目名称:hubroot,代码行数:19,代码来源:RandomizeCommand.cs

示例3: Sound_OnCommand

 public static void Sound_OnCommand( Server.Commands.CommandEventArgs e )
 {
     if ( e.Length == 1 )
         PlaySound( e.Mobile, e.GetInt32( 0 ), true );
     else if ( e.Length == 2 )
         PlaySound( e.Mobile, e.GetInt32( 0 ), e.GetBoolean( 1 ) );
     else
         e.Mobile.SendAsciiMessage( "Format: Sound <index> [toAll]" );
 }
开发者ID:FreeReign,项目名称:Rebirth-Repack,代码行数:9,代码来源:Handlers.cs

示例4: SetGuarded_OnCommand

        private static void SetGuarded_OnCommand(Server.Commands.CommandEventArgs e)
        {
            Mobile from = e.Mobile;

            if (e.Length == 1)
            {
                GuardedRegion reg = from.Region as GuardedRegion;

                if (reg == null)
                {
                    from.SendAsciiMessage("You are not in a guardable region.");
                }
                else
                {
                    reg.Disabled = !e.GetBoolean(0);
                    from.SendAsciiMessage("After your changes:");
                    reg.TellGuardStatus(from);
                }
            }
            else
            {
                from.SendAsciiMessage("Format: SetGuarded <true|false>");
            }
        }
开发者ID:FreeReign,项目名称:Rebirth-Repack,代码行数:24,代码来源:GuardedRegion.cs


注:本文中的Server.Server.GetBoolean方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。