- Removed the need for the old CommandResult Type to be a returned value on all commands. Command.Execute() is now just void. - All commands updated to now return a value. They use player.Send() to direct messages to the player instead. - Removed CommandClear from the project and made it a script so that developers can see how to write custom command scripts.
24 lines
590 B
C#
24 lines
590 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.IO;
|
|
|
|
using MudEngine.FileSystem;
|
|
using MudEngine.GameManagement;
|
|
using MudEngine.GameObjects;
|
|
using MudEngine.GameObjects.Characters;
|
|
|
|
namespace MudEngine.Commands
|
|
{
|
|
public class CommandSave : IGameCommand
|
|
{
|
|
public Boolean Override { get; set; }
|
|
public String Name { get; set; }
|
|
|
|
public void Execute(String command, BaseCharacter player)
|
|
{
|
|
player.Save(player.ActiveGame.DataPaths.Players);
|
|
}
|
|
}
|
|
}
|