RealmGateAddressHelper.cs 651 B

123456789101112131415161718192021222324252627
  1. using System.Collections.Generic;
  2. namespace ET.Server
  3. {
  4. public static class RealmGateAddressHelper
  5. {
  6. public static StartSceneConfig GetGame(int zone)
  7. {
  8. List<StartSceneConfig> zoneGates = StartSceneConfigCategory.Instance.Games[zone];
  9. int n = RandomGenerator.RandomNumber(0, zoneGates.Count);
  10. return zoneGates[n];
  11. }
  12. /// <summary>
  13. /// 获取所有游戏服
  14. /// </summary>
  15. /// <param name="zone"></param>
  16. /// <returns></returns>
  17. public static List<StartSceneConfig> GetAllGame(int zone)
  18. {
  19. return StartSceneConfigCategory.Instance.Games[zone];
  20. }
  21. }
  22. }