- All commands are now required to have a Help property. MudGame: - Finished the Create command. Now allows for creating Realms, Zones and Rooms - Added LinkRoom command for linking Rooms. Not finished. - Added Help command. Typing Help prints all of the currently available commands. Typing Help 'CommandName' prints that Commands help property. Default commands print a help document.
28 lines
778 B
C#
28 lines
778 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.IO;
|
|
using System.Text;
|
|
|
|
using MudEngine.FileSystem;
|
|
using MudEngine.GameObjects.Characters;
|
|
using MudEngine.GameManagement;
|
|
using MudEngine.Commands;
|
|
using MudEngine.GameObjects.Environment;
|
|
|
|
namespace MudEngine.Commands
|
|
{
|
|
public class CommandSaveWorld : IGameCommand
|
|
{
|
|
public Boolean Override { get; set; }
|
|
public String Name { get; set; }
|
|
public List<String> Help { get; set; }
|
|
public void Execute(String command, BaseCharacter player)
|
|
{
|
|
if ((player.Role == SecurityRoles.Admin) || (player.Role == SecurityRoles.GM))
|
|
{
|
|
player.ActiveGame.Save();
|
|
}
|
|
}
|
|
}
|
|
}
|