CommonConfig.cs 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. /**通用配置(2021/12/18新增) */
  5. public class CommonConfig
  6. {
  7. public static bool needToExamine = true;
  8. public static bool isReleaseVersion = true;
  9. /**环数精度小数位 */
  10. public static readonly int ringsPrecision = 1;
  11. /**箭的速度精度小数位 */
  12. public static readonly int arrowSpeedPrecision = 1;
  13. //实体模具箭重,单位克
  14. public static float arrowWeight = 75;
  15. public enum ServerType {LocalTest, Produce};
  16. private static ServerType serverType = ServerType.Produce;
  17. //业务服务端访问地址
  18. public static string businessServerURI {
  19. get {
  20. if (serverType == ServerType.LocalTest) {
  21. return "http://192.168.137.1:11332/SmartBowBusinessServer";
  22. }
  23. if (serverType == ServerType.Produce) {
  24. return "http://49.234.219.63:11332/SmartBowBusinessServer";
  25. }
  26. return "";
  27. }
  28. }
  29. //业务服务端WS访问地址
  30. public static string businessServerWsURI {
  31. get {
  32. if (serverType == ServerType.LocalTest) {
  33. return "ws://192.168.137.1:11333/SmartBowBusinessServerSK";
  34. }
  35. if (serverType == ServerType.Produce) {
  36. return "ws://49.234.219.63:11333/SmartBowBusinessServerSK";
  37. }
  38. return "";
  39. }
  40. }
  41. //游戏对战服务器
  42. public static string gamePKServerWsURI {
  43. get {
  44. if (serverType == ServerType.LocalTest) {
  45. return "ws://192.168.137.1:11811/SmartBowGameServer";
  46. }
  47. if (serverType == ServerType.Produce) {
  48. return "ws://49.234.219.63:11811/SmartBowGameServer";
  49. }
  50. return "";
  51. }
  52. }
  53. }