city-generation/Game/Assets/Scripts/Business/ConfigurationManager.cs

28 lines
864 B
C#
Raw Normal View History

2015-03-13 15:36:12 +00:00
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
using Assets.Scripts.Model.Config;
using TransportGame.Utils;
namespace TransportGame.Business
{
public static class ConfigurationManager
{
public static readonly string BiomeDirectory = "Assets\\Data\\Biomes";
public static readonly string ConfigurationDirectory = "Assets\\Data\\Config";
public static readonly string TerrGenConfigFile = "tergen.xml";
public static TerrainGeneratorConfig TerrGenConfig { get; private set; }
public static void LoadConfiguration()
{
// Load terrgen config
TerrGenConfig = SerializationHelper.DeserializeXml<TerrainGeneratorConfig>(Path.Combine(ConfigurationDirectory, TerrGenConfigFile));
2015-03-13 15:36:12 +00:00
}
}
}