public GameSettings Load() { var settings = _xmlFileSerializer.Deserialize <GameSettings>(FilePath); _settingsCache = settings.GameType; _strategy[_settingsCache.GetType()].Invoke(); return(settings); }
static void Main(string[] args) { Console.WriteLine("Hello World!"); GameType gameType = new GameType(); string[] gameTypeNameArray = Enum.GetNames(gameType.GetType()); Console.WriteLine("枚举个数:\t{0}", gameTypeNameArray.Length); for (int i = 0; i < gameTypeNameArray.Length; i++) { Console.WriteLine("{0}", gameTypeNameArray[i]); } }
public bool IsDropXP(AwardType _awardtype, GameType _gametype) { return ((DropDictionary_[_awardtype][_gametype.GetType().ToString()] & FlagXP) != 0); }