Advertisement
XConquer

Sistema Climas

Dec 24th, 2020
208
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.93 KB | None | 0 0
  1. #region Sistema Climas / Pezzi The Best
  2. ArgCO.Network.GamePackets.Weather weather;
  3. #region Rain System
  4. if (DateTime.Now.Minute == 10 && DateTime.Now.Second == 0 || DateTime.Now.Minute == 00 && DateTime.Now.Second == 00)
  5. {
  6. foreach (GameState state in Kernel.GamePool.Values)
  7. {
  8. Program.WeatherType = ArgCO.Network.GamePackets.Weather.Snow;
  9. weather = new ArgCO.Network.GamePackets.Weather(true)
  10. {
  11. WeatherType = (uint)Program.WeatherType,
  12. Intensity = 255,
  13. Appearence = 255,
  14. Direction = 255
  15. };
  16. state.Send(weather);
  17. }
  18. }
  19. #endregion Rain System
  20. #region Snow System
  21. if (DateTime.Now.Minute == 20 && DateTime.Now.Second == 0 || DateTime.Now.Minute == 00 && DateTime.Now.Second == 00)
  22. {
  23. foreach (GameState state in Kernel.GamePool.Values)
  24. {
  25. Program.WeatherType = ArgCO.Network.GamePackets.Weather.Snow;
  26. weather = new ArgCO.Network.GamePackets.Weather(true)
  27. {
  28. WeatherType = (uint)Program.WeatherType,
  29. Intensity = 255,
  30. Appearence = 255,
  31. Direction = 255
  32. };
  33. state.Send(weather);
  34. }
  35. }
  36. #endregion Snow System
  37. #region AutumnLeaves
  38. if (DateTime.Now.Minute == 30 && DateTime.Now.Second == 0 || DateTime.Now.Minute == 00 && DateTime.Now.Second == 00)
  39. {
  40. foreach (GameState state in Kernel.GamePool.Values)
  41. {
  42. Program.WeatherType = ArgCO.Network.GamePackets.Weather.Snow;
  43. weather = new ArgCO.Network.GamePackets.Weather(true)
  44. {
  45. WeatherType = (uint)Program.WeatherType,
  46. Intensity = 255,
  47. Appearence = 255,
  48. Direction = 255
  49. };
  50. state.Send(weather);
  51. }
  52. }
  53. #endregion AutumnLeaves
  54. #region CherryBlossomPetals
  55. if (DateTime.Now.Minute == 40 && DateTime.Now.Second == 0 || DateTime.Now.Minute == 00 && DateTime.Now.Second == 00)
  56. {
  57. foreach (GameState state in Kernel.GamePool.Values)
  58. {
  59. Program.WeatherType = ArgCO.Network.GamePackets.Weather.Snow;
  60. weather = new ArgCO.Network.GamePackets.Weather(true)
  61. {
  62. WeatherType = (uint)Program.WeatherType,
  63. Intensity = 255,
  64. Appearence = 255,
  65. Direction = 255
  66. };
  67. state.Send(weather);
  68. }
  69. }
  70. #endregion CherryBlossomPetals
  71. #region BlowingCotten
  72. if (DateTime.Now.Minute == 60 && DateTime.Now.Second == 0 || DateTime.Now.Minute == 00 && DateTime.Now.Second == 00)
  73. {
  74. foreach (GameState state in Kernel.GamePool.Values)
  75. {
  76. Program.WeatherType = ArgCO.Network.GamePackets.Weather.Snow;
  77. weather = new ArgCO.Network.GamePackets.Weather(true)
  78. {
  79. WeatherType = (uint)Program.WeatherType,
  80. Intensity = 255,
  81. Appearence = 255,
  82. Direction = 255
  83. };
  84. state.Send(weather);
  85. }
  86. }
  87. #endregion CherryBlossomPetals
  88. #endregion
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement