packets.hpp 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. // Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
  2. // For more information, see LICENCE in the main folder
  3. #ifndef CONFIG_PACKETS_HPP
  4. #define CONFIG_PACKETS_HPP
  5. /**
  6. * rAthena configuration file (http://rathena.org)
  7. * For detailed guidance on these check http://rathena.org/wiki/SRC/config/
  8. **/
  9. #ifndef PACKETVER
  10. /// Do NOT edit this line! To set your client version, please do this instead:
  11. /// In Windows: Add this line in your src\custom\defines_pre.hpp file: #define PACKETVER YYYYMMDD
  12. /// In Linux: The same as above or run the following command: ./configure --enable-packetver=YYYYMMDD
  13. #define PACKETVER 20200401
  14. #endif
  15. #ifndef PACKETVER_RE
  16. /// From November 2015 only RagexeRE are supported.
  17. /// After July 2018 only Ragexe are supported.
  18. #if PACKETVER > 20151104 && PACKETVER < 20180704
  19. #define PACKETVER_RE
  20. #endif
  21. #endif
  22. #ifndef PACKETVER_RE
  23. #define PACKETVER_MAIN_NUM PACKETVER
  24. // Undefine all sakray server definitions
  25. #undef PACKETVER_RE
  26. #undef PACKETVER_RE_NUM
  27. #else
  28. // Undefine existing definition
  29. #undef PACKETVER_RE
  30. #define PACKETVER_RE PACKETVER
  31. #define PACKETVER_RE_NUM PACKETVER
  32. // Undefine all main server definitions
  33. #undef PACKETVER_MAIN_NUM
  34. #endif
  35. #if PACKETVER >= 20110817
  36. /// Comment to disable the official packet obfuscation support.
  37. /// This requires PACKETVER 2011-08-17 or newer.
  38. #ifndef PACKET_OBFUSCATION
  39. #define PACKET_OBFUSCATION
  40. // Define these inside src/custom/defines_pre.hpp or src/custom/defines_post.hpp
  41. //#define PACKET_OBFUSCATION_KEY1 <key1>
  42. //#define PACKET_OBFUSCATION_KEY2 <key2>
  43. //#define PACKET_OBFUSCATION_KEY3 <key3>
  44. /// Comment this to disable warnings for missing client side encryption
  45. #define PACKET_OBFUSCATION_WARN
  46. #endif
  47. #else
  48. #if defined(PACKET_OBFUSCATION)
  49. #error You enabled packet obfuscation for a version which is too old. Minimum supported client is 2011-08-17.
  50. #endif
  51. #endif
  52. /// Comment to disable the official Guild Storage skill.
  53. /// When enabled, this will set the guild storage size to the level of the skill * 100.
  54. #if PACKETVER >= 20131223
  55. #define OFFICIAL_GUILD_STORAGE
  56. #endif
  57. #ifndef DUMP_UNKNOWN_PACKET
  58. //#define DUMP_UNKNOWN_PACKET
  59. #endif
  60. #ifndef DUMP_INVALID_PACKET
  61. //#define DUMP_INVALID_PACKET
  62. #endif
  63. /**
  64. * No settings past this point
  65. **/
  66. /// Check if the specified packetversion supports the pincode system
  67. #define PACKETVER_SUPPORTS_PINCODE PACKETVER >= 20110309
  68. /// Check if the client needs delete_date as remaining time and not the actual delete_date (actually it was tested for clients since 2013)
  69. #define PACKETVER_CHAR_DELETEDATE (PACKETVER > 20130000 && PACKETVER <= 20141022) || PACKETVER >= 20150513
  70. /// Check if the specified packetvresion supports the cashshop sale system
  71. #define PACKETVER_SUPPORTS_SALES PACKETVER >= 20131223
  72. #endif /* CONFIG_PACKETS_HPP */