Refresh of repo required.

This commit is contained in:
Scionwest_cp 2010-01-17 18:56:44 -08:00
parent dafcc55437
commit 9311435007
47 changed files with 0 additions and 4421 deletions

View file

@ -1,56 +0,0 @@
using System;
namespace MudDesigner.MudEngine.GameObjects
{
public enum AvailableTravelDirections
{
None = 0,
North,
South,
East,
West,
Up,
Down,
}
public static class TravelDirections
{
public static AvailableTravelDirections GetReverseDirection(AvailableTravelDirections Direction)
{
switch (Direction)
{
case AvailableTravelDirections.Down:
return AvailableTravelDirections.Up;
case AvailableTravelDirections.East:
return AvailableTravelDirections.West;
case AvailableTravelDirections.None:
return AvailableTravelDirections.None;
case AvailableTravelDirections.North:
return AvailableTravelDirections.South;
case AvailableTravelDirections.South:
return AvailableTravelDirections.North;
case AvailableTravelDirections.Up:
return AvailableTravelDirections.Down;
case AvailableTravelDirections.West:
return AvailableTravelDirections.East;
default:
return AvailableTravelDirections.None;
}
}
public static AvailableTravelDirections GetTravelDirectionValue(string Direction)
{
Array values = Enum.GetValues(typeof(AvailableTravelDirections));
foreach (int value in values)
{
string displayName = Enum.GetName(typeof(AvailableTravelDirections), value);
if (displayName == Direction)
return (AvailableTravelDirections)Enum.Parse(typeof(AvailableTravelDirections), displayName);
}
return AvailableTravelDirections.None;
}
}
}