AddCommand() private method

private AddCommand ( string command, CommandHandler handler, bool isConsoleSafe ) : void
command string
handler CommandHandler
isConsoleSafe bool
return void
Example #1
0
 internal DrawCommands( World _world, Commands commands ) {
     world = _world;
     commands.AddCommand( "cuboid", Cuboid, true );
     commands.AddCommand( "cub", Cuboid, true );
     commands.AddCommand( "ellipsoid", Ellipsoid, true );
     commands.AddCommand( "ell", Ellipsoid, true );
     commands.AddCommand( "mark", Mark, true );
     commands.AddCommand( "undo", UndoDraw, true );
     commands.AddCommand( "cancel", CancelDraw, true );
 }
Example #2
0
 // Register help commands
 internal InfoCommands( World _world, Commands commands ){
     world = _world;
     commands.AddCommand( "help", Help, true );
     commands.AddCommand( "info", Info, true );
     commands.AddCommand( "baninfo", BanInfo, true );
     commands.AddCommand( "class", ClassInfo, true );
     commands.AddCommand( "rules", Rules, true );
     
     commands.AddCommand( "where", Compass, false );
     commands.AddCommand( "compass", Compass, false );
 }
Example #3
0
 // Register help commands
 internal BlockCommands( World _world, Commands commands ) {
     world = _world;
     commands.AddCommand( "grass", Grass, false );
     commands.AddCommand( "water", Water, false );
     commands.AddCommand( "lava", Lava, false );
     commands.AddCommand( "solid", Solid, false );
     commands.AddCommand( "s", Solid, false );
     commands.AddCommand( "paint", Paint, false );
     //CommandUtils.AddCommand( "sand", Sand ); // TODO: after sand sim is done
 }
Example #4
0
        internal MapCommands( World _world, Commands commands ) {
            world = _world;

            commands.AddCommand( "load", Load, true );
            commands.AddCommand( "save", Save, true );

            commands.AddCommand( "lock", Lock, true );
            commands.AddCommand( "unlock", Unlock, true );

            commands.AddCommand( "gen", Generate, true );
            commands.AddCommand( "genh", GenerateHollow, true );

            commands.AddCommand( "zone", DoZone, false );
        }
Example #5
0
        // Register standard commands.
        internal StandardCommands( World _world, Commands commands ){
            world = _world; 
            commands.AddCommand( "k", Kick, true );
            commands.AddCommand( "kick", Kick, true );

            commands.AddCommand( "ban", Ban, true );
            commands.AddCommand( "banip", BanIP, true );
            commands.AddCommand( "banall", BanAll, true );
            commands.AddCommand( "unban", Unban, true );
            commands.AddCommand( "unbanip", UnbanIP, true );
            commands.AddCommand( "unbanall", UnbanAll, true );

            commands.AddCommand( "user", ChangeClass, true );

            commands.AddCommand( "tp", TP, false );
            commands.AddCommand( "bring", Bring, false );
            commands.AddCommand( "freeze", Freeze, false );
            commands.AddCommand( "unfreeze", Unfreeze, false );
            commands.AddCommand( "setspawn", SetSpawn, false );

            commands.AddCommand( "hide", Hide, false );
            commands.AddCommand( "unhide", Unhide, false );

            commands.AddCommand( "say", Say, true );

            commands.AddCommand( "roll", Roll, true );

            commands.AddCommand( "d", Dummy, false );
            commands.AddCommand( "dummy", Dummy, false );
            commands.AddCommand( "dt", DummyTrail, false );

            commands.AddCommand( "nick", Nick, true );

            commands.AddCommand( "me", Me, true );

            //commands.AddCommand( "reloadconfig", ReloadConfig, true );
        }
Example #6
0
        // Register standard commands.
        internal StandardCommands(World _world, Commands commands)
        {
            world = _world;
            commands.AddCommand("k", Kick, true);
            commands.AddCommand("kick", Kick, true);

            commands.AddCommand("ban", Ban, true);
            commands.AddCommand("banip", BanIP, true);
            commands.AddCommand("banall", BanAll, true);
            commands.AddCommand("unban", Unban, true);
            commands.AddCommand("unbanip", UnbanIP, true);
            commands.AddCommand("unbanall", UnbanAll, true);

            commands.AddCommand("user", ChangeClass, true);

            commands.AddCommand("tp", TP, false);
            commands.AddCommand("bring", Bring, false);
            commands.AddCommand("freeze", Freeze, false);
            commands.AddCommand("unfreeze", Unfreeze, false);
            commands.AddCommand("setspawn", SetSpawn, false);

            commands.AddCommand("hide", Hide, false);
            commands.AddCommand("unhide", Unhide, false);

            commands.AddCommand("say", Say, true);

            commands.AddCommand("roll", Roll, true);

            commands.AddCommand("d", Dummy, false);
            commands.AddCommand("dummy", Dummy, false);
            commands.AddCommand("dt", DummyTrail, false);

            commands.AddCommand("nick", Nick, true);

            commands.AddCommand("me", Me, true);

            //commands.AddCommand( "reloadconfig", ReloadConfig, true );
        }