Guest User

Untitled

a guest
Oct 24th, 2016
29
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #ifndef __INC_METIN_II_LENGTH_H__
  2. #define __INC_METIN_II_LENGTH_H__
  3. #include "service.h"
  4. #define WORD_MAX 0xffff
  5. enum EMisc
  6. {
  7. MAX_HOST_LENGTH = 15,
  8. IP_ADDRESS_LENGTH = 15,
  9. LOGIN_MAX_LEN = 30,
  10. PASSWD_MAX_LEN = 16,
  11. PLAYER_PER_ACCOUNT = 4,
  12. ACCOUNT_STATUS_MAX_LEN = 8,
  13. CHARACTER_NAME_MAX_LEN = 24,
  14. SHOP_SIGN_MAX_LEN = 32,
  15. INVENTORY_MAX_NUM = 90,
  16. ABILITY_MAX_NUM = 50,
  17. EMPIRE_MAX_NUM = 4,
  18. BANWORD_MAX_LEN = 24,
  19. SMS_MAX_LEN = 80,
  20. MOBILE_MAX_LEN = 32,
  21. SOCIAL_ID_MAX_LEN = 18,
  22. GUILD_NAME_MAX_LEN = 12,
  23. SHOP_HOST_ITEM_MAX_NUM = 40,
  24. SHOP_GUEST_ITEM_MAX_NUM = 18,
  25. SHOP_PRICELIST_MAX_NUM = 40,
  26. CHAT_MAX_LEN = 512,
  27. QUICKSLOT_MAX_NUM = 36,
  28. JOURNAL_MAX_NUM = 2,
  29. QUERY_MAX_LEN = 8192,
  30. FILE_MAX_LEN = 128,
  31. PLAYER_EXP_TABLE_MAX = 120,
  32. PLAYER_MAX_LEVEL_CONST = 120,
  33. GUILD_MAX_LEVEL = 20,
  34. MOB_MAX_LEVEL = 100,
  35. ATTRIBUTE_MAX_VALUE = 20,
  36. CHARACTER_PATH_MAX_NUM = 64,
  37. SKILL_MAX_NUM = 255,
  38. SKILLBOOK_DELAY_MIN = 64800,
  39. SKILLBOOK_DELAY_MAX = 108000,
  40. SKILL_MAX_LEVEL = 40,
  41. APPLY_NAME_MAX_LEN = 32,
  42. EVENT_FLAG_NAME_MAX_LEN = 32,
  43. MOB_SKILL_MAX_NUM = 5,
  44. POINT_MAX_NUM = 255,
  45. DRAGON_SOUL_BOX_SIZE = 32,
  46. DRAGON_SOUL_BOX_COLUMN_NUM = 8,
  47. DRAGON_SOUL_BOX_ROW_NUM = DRAGON_SOUL_BOX_SIZE / DRAGON_SOUL_BOX_COLUMN_NUM,
  48. DRAGON_SOUL_REFINE_GRID_SIZE = 15,
  49. MAX_AMOUNT_OF_MALL_BONUS = 20,
  50. WEAR_MAX_NUM = 32,
  51. GOLD_MAX = 2000000000,
  52. MAX_PASSPOD = 8 ,
  53. OPENID_AUTHKEY_LEN = 32,
  54. SHOP_TAB_NAME_MAX = 32,
  55. SHOP_TAB_COUNT_MAX = 3,
  56. BELT_INVENTORY_SLOT_WIDTH = 4,
  57. BELT_INVENTORY_SLOT_HEIGHT= 4,
  58. BELT_INVENTORY_SLOT_COUNT = BELT_INVENTORY_SLOT_WIDTH * BELT_INVENTORY_SLOT_HEIGHT,
  59. };
  60.  
  61. enum EMatrixCard
  62. {
  63. MATRIX_CODE_MAX_LEN = 192,
  64. MATRIX_ANSWER_MAX_LEN = 8,
  65. };
  66.  
  67. enum EWearPositions
  68. {
  69. WEAR_BODY, // 0
  70. WEAR_HEAD, // 1
  71. WEAR_FOOTS, // 2
  72. WEAR_WRIST, // 3
  73. WEAR_WEAPON, // 4
  74. WEAR_NECK, // 5
  75. WEAR_EAR, // 6
  76. WEAR_UNIQUE1, // 7
  77. WEAR_UNIQUE2, // 8
  78. WEAR_ARROW, // 9
  79. WEAR_SHIELD, // 10
  80. WEAR_ABILITY1, // 11
  81. WEAR_ABILITY2, // 12
  82. WEAR_ABILITY3, // 13
  83. WEAR_ABILITY4, // 14
  84. WEAR_ABILITY5, // 15
  85. WEAR_ABILITY6, // 16
  86. WEAR_ABILITY7, // 17
  87. WEAR_ABILITY8, // 18
  88. WEAR_COSTUME_BODY, // 19
  89. WEAR_COSTUME_HAIR, // 20
  90. WEAR_RING1, // 21
  91. WEAR_RING2, // 22
  92. WEAR_BELT, // 23
  93.  
  94. WEAR_MAX = 32 //
  95. };
  96.  
  97. enum EDragonSoulDeckType
  98. {
  99. DRAGON_SOUL_DECK_0,
  100. DRAGON_SOUL_DECK_1,
  101. DRAGON_SOUL_DECK_MAX_NUM = 2,
  102.  
  103. DRAGON_SOUL_DECK_RESERVED_MAX_NUM = 3,
  104. };
  105.  
  106. enum ESex
  107. {
  108. SEX_MALE,
  109. SEX_FEMALE
  110. };
  111.  
  112. enum EDirection
  113. {
  114. DIR_NORTH,
  115. DIR_NORTHEAST,
  116. DIR_EAST,
  117. DIR_SOUTHEAST,
  118. DIR_SOUTH,
  119. DIR_SOUTHWEST,
  120. DIR_WEST,
  121. DIR_NORTHWEST,
  122. DIR_MAX_NUM
  123. };
  124.  
  125. #define ABILITY_MAX_LEVEL 10
  126.  
  127. enum EAbilityDifficulty
  128. {
  129. DIFFICULTY_EASY,
  130. DIFFICULTY_NORMAL,
  131. DIFFICULTY_HARD,
  132. DIFFICULTY_VERY_HARD,
  133. DIFFICULTY_NUM_TYPES
  134. };
  135.  
  136. enum EAbilityCategory
  137. {
  138. CATEGORY_PHYSICAL,
  139. CATEGORY_MENTAL,
  140. CATEGORY_ATTRIBUTE,
  141. CATEGORY_NUM_TYPES
  142. };
  143.  
  144. enum EJobs
  145. {
  146. JOB_WARRIOR,
  147. JOB_ASSASSIN,
  148. JOB_SURA,
  149. JOB_SHAMAN,
  150. #ifdef ENABLE_WOLFMAN_CHARACTER
  151. JOB_WOLFMAN,
  152. #endif
  153. JOB_MAX_NUM
  154. };
  155.  
  156. enum ESkillGroups
  157. {
  158. SKILL_GROUP_MAX_NUM = 2,
  159. };
  160.  
  161. enum ERaceFlags
  162. {
  163. RACE_FLAG_ANIMAL = (1 << 0),
  164. RACE_FLAG_UNDEAD = (1 << 1),
  165. RACE_FLAG_DEVIL = (1 << 2),
  166. RACE_FLAG_HUMAN = (1 << 3),
  167. RACE_FLAG_ORC = (1 << 4),
  168. RACE_FLAG_MILGYO = (1 << 5),
  169. RACE_FLAG_INSECT = (1 << 6),
  170. RACE_FLAG_FIRE = (1 << 7),
  171. RACE_FLAG_ICE = (1 << 8),
  172. RACE_FLAG_DESERT = (1 << 9),
  173. RACE_FLAG_TREE = (1 << 10),
  174. RACE_FLAG_ATT_ELEC = (1 << 11),
  175. RACE_FLAG_ATT_FIRE = (1 << 12),
  176. RACE_FLAG_ATT_ICE = (1 << 13),
  177. RACE_FLAG_ATT_WIND = (1 << 14),
  178. RACE_FLAG_ATT_EARTH = (1 << 15),
  179. RACE_FLAG_ATT_DARK = (1 << 16),
  180. };
  181.  
  182. enum ELoads
  183. {
  184. LOAD_NONE,
  185. LOAD_LIGHT,
  186. LOAD_NORMAL,
  187. LOAD_HEAVY,
  188. LOAD_MASSIVE
  189. };
  190.  
  191. enum
  192. {
  193. QUICKSLOT_TYPE_NONE,
  194. QUICKSLOT_TYPE_ITEM,
  195. QUICKSLOT_TYPE_SKILL,
  196. QUICKSLOT_TYPE_COMMAND,
  197. QUICKSLOT_TYPE_MAX_NUM,
  198. };
  199.  
  200. enum EParts
  201. {
  202. PART_MAIN,
  203. PART_WEAPON,
  204. PART_HEAD,
  205. PART_HAIR,
  206.  
  207. PART_MAX_NUM,
  208. PART_WEAPON_SUB,
  209. };
  210.  
  211. enum EChatType
  212. {
  213. CHAT_TYPE_TALKING,
  214. CHAT_TYPE_INFO,
  215. CHAT_TYPE_NOTICE,
  216. CHAT_TYPE_PARTY,
  217. CHAT_TYPE_GUILD,
  218. CHAT_TYPE_COMMAND,
  219. CHAT_TYPE_SHOUT,
  220. CHAT_TYPE_WHISPER,
  221. CHAT_TYPE_BIG_NOTICE,
  222. CHAT_TYPE_MONARCH_NOTICE,
  223. CHAT_TYPE_MAX_NUM
  224. };
  225.  
  226. enum EWhisperType
  227. {
  228. WHISPER_TYPE_NORMAL = 0,
  229. WHISPER_TYPE_NOT_EXIST = 1,
  230. WHISPER_TYPE_TARGET_BLOCKED = 2,
  231. WHISPER_TYPE_SENDER_BLOCKED = 3,
  232. WHISPER_TYPE_ERROR = 4,
  233. WHISPER_TYPE_GM = 5,
  234. WHISPER_TYPE_SYSTEM = 0xFF
  235. };
  236.  
  237. enum ECharacterPosition
  238. {
  239. POSITION_GENERAL,
  240. POSITION_BATTLE,
  241. POSITION_DYING,
  242. POSITION_SITTING_CHAIR,
  243. POSITION_SITTING_GROUND,
  244. POSITION_INTRO,
  245. POSITION_MAX_NUM
  246. };
  247.  
  248. enum EGMLevels
  249. {
  250. GM_PLAYER,
  251. GM_LOW_WIZARD,
  252. GM_WIZARD,
  253. GM_HIGH_WIZARD,
  254. GM_GOD,
  255. GM_IMPLEMENTOR
  256. };
  257.  
  258. enum EMobRank
  259. {
  260. MOB_RANK_PAWN,
  261. MOB_RANK_S_PAWN,
  262. MOB_RANK_KNIGHT,
  263. MOB_RANK_S_KNIGHT,
  264. MOB_RANK_BOSS,
  265. MOB_RANK_KING,
  266. MOB_RANK_MAX_NUM
  267. };
  268.  
  269. enum ECharType
  270. {
  271. CHAR_TYPE_MONSTER,
  272. CHAR_TYPE_NPC,
  273. CHAR_TYPE_STONE,
  274. CHAR_TYPE_WARP,
  275. CHAR_TYPE_DOOR,
  276. CHAR_TYPE_BUILDING,
  277. CHAR_TYPE_PC,
  278. CHAR_TYPE_POLYMORPH_PC,
  279. CHAR_TYPE_HORSE,
  280. CHAR_TYPE_GOTO
  281. };
  282.  
  283. enum EBattleType
  284. {
  285. BATTLE_TYPE_MELEE,
  286. BATTLE_TYPE_RANGE,
  287. BATTLE_TYPE_MAGIC,
  288. BATTLE_TYPE_SPECIAL,
  289. BATTLE_TYPE_POWER,
  290. BATTLE_TYPE_TANKER,
  291. BATTLE_TYPE_SUPER_POWER,
  292. BATTLE_TYPE_SUPER_TANKER,
  293. BATTLE_TYPE_MAX_NUM
  294. };
  295.  
  296. enum EApplyTypes
  297. {
  298. APPLY_NONE, // 0
  299. APPLY_MAX_HP, // 1
  300. APPLY_MAX_SP, // 2
  301. APPLY_CON, // 3
  302. APPLY_INT, // 4
  303. APPLY_STR, // 5
  304. APPLY_DEX, // 6
  305. APPLY_ATT_SPEED, // 7
  306. APPLY_MOV_SPEED, // 8
  307. APPLY_CAST_SPEED, // 9
  308. APPLY_HP_REGEN, // 10
  309. APPLY_SP_REGEN, // 11
  310. APPLY_POISON_PCT, // 12
  311. APPLY_STUN_PCT, // 13
  312. APPLY_SLOW_PCT, // 14
  313. APPLY_CRITICAL_PCT, // 15
  314. APPLY_PENETRATE_PCT, // 16
  315. APPLY_ATTBONUS_HUMAN, // 17
  316. APPLY_ATTBONUS_ANIMAL, // 18
  317. APPLY_ATTBONUS_ORC, // 19
  318. APPLY_ATTBONUS_MILGYO, // 20
  319. APPLY_ATTBONUS_UNDEAD, // 21
  320. APPLY_ATTBONUS_DEVIL, // 22
  321. APPLY_STEAL_HP, // 23
  322. APPLY_STEAL_SP, // 24
  323. APPLY_MANA_BURN_PCT, // 25
  324. APPLY_DAMAGE_SP_RECOVER, // 26
  325. APPLY_BLOCK, // 27
  326. APPLY_DODGE, // 28
  327. APPLY_RESIST_SWORD, // 29
  328. APPLY_RESIST_TWOHAND, // 30
  329. APPLY_RESIST_DAGGER, // 31
  330. APPLY_RESIST_BELL, // 32
  331. APPLY_RESIST_FAN, // 33
  332. APPLY_RESIST_BOW, // 34
  333. APPLY_RESIST_FIRE, // 35
  334. APPLY_RESIST_ELEC, // 36
  335. APPLY_RESIST_MAGIC, // 37
  336. APPLY_RESIST_WIND, // 38
  337. APPLY_REFLECT_MELEE, // 39
  338. APPLY_REFLECT_CURSE, // 40
  339. APPLY_POISON_REDUCE, // 41
  340. APPLY_KILL_SP_RECOVER, // 42
  341. APPLY_EXP_DOUBLE_BONUS, // 43
  342. APPLY_GOLD_DOUBLE_BONUS, // 44
  343. APPLY_ITEM_DROP_BONUS, // 45
  344. APPLY_POTION_BONUS, // 46
  345. APPLY_KILL_HP_RECOVER, // 47
  346. APPLY_IMMUNE_STUN, // 48
  347. APPLY_IMMUNE_SLOW, // 49
  348. APPLY_IMMUNE_FALL, // 50
  349. APPLY_SKILL, // 51
  350. APPLY_BOW_DISTANCE, // 52
  351. APPLY_ATT_GRADE_BONUS, // 53
  352. APPLY_DEF_GRADE_BONUS, // 54
  353. APPLY_MAGIC_ATT_GRADE, // 55
  354. APPLY_MAGIC_DEF_GRADE, // 56
  355. APPLY_CURSE_PCT, // 57
  356. APPLY_MAX_STAMINA, // 58
  357. APPLY_ATTBONUS_WARRIOR, // 59
  358. APPLY_ATTBONUS_ASSASSIN, // 60
  359. APPLY_ATTBONUS_SURA, // 61
  360. APPLY_ATTBONUS_SHAMAN, // 62
  361. APPLY_ATTBONUS_MONSTER, // 63
  362. APPLY_MALL_ATTBONUS, // 64
  363. APPLY_MALL_DEFBONUS, // 65
  364. APPLY_MALL_EXPBONUS, // 66
  365. APPLY_MALL_ITEMBONUS, // 67
  366. APPLY_MALL_GOLDBONUS, // 68
  367. APPLY_MAX_HP_PCT, // 69
  368. APPLY_MAX_SP_PCT, // 70
  369. APPLY_SKILL_DAMAGE_BONUS, // 71
  370. APPLY_NORMAL_HIT_DAMAGE_BONUS, // 72
  371. APPLY_SKILL_DEFEND_BONUS, // 73
  372. APPLY_NORMAL_HIT_DEFEND_BONUS, // 74
  373. APPLY_PC_BANG_EXP_BONUS, // 75
  374. APPLY_PC_BANG_DROP_BONUS, // 76
  375.  
  376. APPLY_EXTRACT_HP_PCT,
  377. APPLY_RESIST_WARRIOR,
  378. APPLY_RESIST_ASSASSIN,
  379. APPLY_RESIST_SURA,
  380. APPLY_RESIST_SHAMAN,
  381. APPLY_ENERGY,
  382. APPLY_DEF_GRADE,
  383. APPLY_COSTUME_ATTR_BONUS,
  384. APPLY_MAGIC_ATTBONUS_PER,
  385. APPLY_MELEE_MAGIC_ATTBONUS_PER,
  386. APPLY_RESIST_ICE,
  387. APPLY_RESIST_EARTH,
  388. APPLY_RESIST_DARK,
  389. APPLY_ANTI_CRITICAL_PCT,
  390. APPLY_ANTI_PENETRATE_PCT,
  391. #ifdef ENABLE_WOLFMAN_CHARACTER
  392. APPLY_BLEEDING_PCT,
  393. APPLY_BLEEDING_REDUCE,
  394. APPLY_ATTBONUS_WOLFMAN,
  395. APPLY_RESIST_WOLFMAN,
  396. APPLY_RESIST_CLAW,
  397. #endif
  398. MAX_APPLY_NUM,
  399. };
  400.  
  401. enum EOnClickEvents
  402. {
  403. ON_CLICK_NONE,
  404. ON_CLICK_SHOP,
  405. ON_CLICK_TALK,
  406. ON_CLICK_MAX_NUM
  407. };
  408.  
  409. enum EOnIdleEvents
  410. {
  411. ON_IDLE_NONE,
  412. ON_IDLE_GENERAL,
  413. ON_IDLE_MAX_NUM
  414. };
  415.  
  416. enum EWindows
  417. {
  418. RESERVED_WINDOW,
  419. INVENTORY,
  420. EQUIPMENT,
  421. SAFEBOX,
  422. MALL,
  423. DRAGON_SOUL_INVENTORY,
  424. BELT_INVENTORY,
  425. #ifdef __AUCTION__
  426. AUCTION,
  427. #endif
  428. GROUND
  429. };
  430.  
  431. enum EMobSizes
  432. {
  433. MOBSIZE_RESERVED,
  434. MOBSIZE_SMALL,
  435. MOBSIZE_MEDIUM,
  436. MOBSIZE_BIG
  437. };
  438.  
  439. enum EAIFlags
  440. {
  441. AIFLAG_AGGRESSIVE = (1 << 0),
  442. AIFLAG_NOMOVE = (1 << 1),
  443. AIFLAG_COWARD = (1 << 2),
  444. AIFLAG_NOATTACKSHINSU = (1 << 3),
  445. AIFLAG_NOATTACKJINNO = (1 << 4),
  446. AIFLAG_NOATTACKCHUNJO = (1 << 5),
  447. AIFLAG_ATTACKMOB = (1 << 6 ),
  448. AIFLAG_BERSERK = (1 << 7),
  449. AIFLAG_STONESKIN = (1 << 8),
  450. AIFLAG_GODSPEED = (1 << 9),
  451. AIFLAG_DEATHBLOW = (1 << 10),
  452. AIFLAG_REVIVE = (1 << 11),
  453. };
  454.  
  455. enum EMobStatType
  456. {
  457. MOB_STATTYPE_POWER,
  458. MOB_STATTYPE_TANKER,
  459. MOB_STATTYPE_SUPER_POWER,
  460. MOB_STATTYPE_SUPER_TANKER,
  461. MOB_STATTYPE_RANGE,
  462. MOB_STATTYPE_MAGIC,
  463. MOB_STATTYPE_MAX_NUM
  464. };
  465.  
  466. enum EImmuneFlags
  467. {
  468. IMMUNE_STUN = (1 << 0),
  469. IMMUNE_SLOW = (1 << 1),
  470. IMMUNE_FALL = (1 << 2),
  471. IMMUNE_CURSE = (1 << 3),
  472. IMMUNE_POISON = (1 << 4),
  473. IMMUNE_TERROR = (1 << 5),
  474. IMMUNE_REFLECT = (1 << 6),
  475. };
  476.  
  477. enum EMobEnchants
  478. {
  479. MOB_ENCHANT_CURSE,
  480. MOB_ENCHANT_SLOW,
  481. MOB_ENCHANT_POISON,
  482. MOB_ENCHANT_STUN,
  483. MOB_ENCHANT_CRITICAL,
  484. MOB_ENCHANT_PENETRATE,
  485. MOB_ENCHANTS_MAX_NUM
  486. };
  487.  
  488. enum EMobResists
  489. {
  490. MOB_RESIST_SWORD,
  491. MOB_RESIST_TWOHAND,
  492. MOB_RESIST_DAGGER,
  493. MOB_RESIST_BELL,
  494. MOB_RESIST_FAN,
  495. MOB_RESIST_BOW,
  496. MOB_RESIST_FIRE,
  497. MOB_RESIST_ELECT,
  498. MOB_RESIST_MAGIC,
  499. MOB_RESIST_WIND,
  500. MOB_RESIST_POISON,
  501. MOB_RESISTS_MAX_NUM
  502. };
  503.  
  504. enum
  505. {
  506. SKILL_ATTR_TYPE_NORMAL = 1,
  507. SKILL_ATTR_TYPE_MELEE,
  508. SKILL_ATTR_TYPE_RANGE,
  509. SKILL_ATTR_TYPE_MAGIC
  510. };
  511.  
  512. enum
  513. {
  514. SKILL_NORMAL,
  515. SKILL_MASTER,
  516. SKILL_GRAND_MASTER,
  517. SKILL_PERFECT_MASTER,
  518. };
  519.  
  520. enum EGuildWarType
  521. {
  522. GUILD_WAR_TYPE_FIELD,
  523. GUILD_WAR_TYPE_BATTLE,
  524. GUILD_WAR_TYPE_FLAG,
  525. GUILD_WAR_TYPE_MAX_NUM
  526. };
  527.  
  528. enum EGuildWarState
  529. {
  530. GUILD_WAR_NONE,
  531. GUILD_WAR_SEND_DECLARE,
  532. GUILD_WAR_REFUSE,
  533. GUILD_WAR_RECV_DECLARE,
  534. GUILD_WAR_WAIT_START,
  535. GUILD_WAR_CANCEL,
  536. GUILD_WAR_ON_WAR,
  537. GUILD_WAR_END,
  538. GUILD_WAR_OVER,
  539. GUILD_WAR_RESERVE,
  540.  
  541. GUILD_WAR_DURATION = 30*60,
  542. GUILD_WAR_WIN_POINT = 1000,
  543. GUILD_WAR_LADDER_HALF_PENALTY_TIME = 12*60*60,
  544. };
  545.  
  546. enum EAttributeSet
  547. {
  548. ATTRIBUTE_SET_WEAPON,
  549. ATTRIBUTE_SET_BODY,
  550. ATTRIBUTE_SET_WRIST,
  551. ATTRIBUTE_SET_FOOTS,
  552. ATTRIBUTE_SET_NECK,
  553. ATTRIBUTE_SET_HEAD,
  554. ATTRIBUTE_SET_SHIELD,
  555. ATTRIBUTE_SET_EAR,
  556. ATTRIBUTE_SET_MAX_NUM
  557. };
  558.  
  559. enum EPrivType
  560. {
  561. PRIV_NONE,
  562. PRIV_ITEM_DROP,
  563. PRIV_GOLD_DROP,
  564. PRIV_GOLD10_DROP,
  565. PRIV_EXP_PCT,
  566. MAX_PRIV_NUM,
  567. };
  568.  
  569. enum EMoneyLogType
  570. {
  571. MONEY_LOG_RESERVED,
  572. MONEY_LOG_MONSTER,
  573. MONEY_LOG_SHOP,
  574. MONEY_LOG_REFINE,
  575. MONEY_LOG_QUEST,
  576. MONEY_LOG_GUILD,
  577. MONEY_LOG_MISC,
  578. MONEY_LOG_MONSTER_KILL,
  579. MONEY_LOG_DROP,
  580. MONEY_LOG_TYPE_MAX_NUM,
  581. };
  582.  
  583. enum EPremiumTypes
  584. {
  585. PREMIUM_EXP,
  586. PREMIUM_ITEM,
  587. PREMIUM_SAFEBOX,
  588. PREMIUM_AUTOLOOT,
  589. PREMIUM_FISH_MIND,
  590. PREMIUM_MARRIAGE_FAST,
  591. PREMIUM_GOLD,
  592. PREMIUM_MAX_NUM = 9
  593. };
  594.  
  595. enum SPECIAL_EFFECT
  596. {
  597. SE_NONE,
  598.  
  599. SE_HPUP_RED,
  600. SE_SPUP_BLUE,
  601. SE_SPEEDUP_GREEN,
  602. SE_DXUP_PURPLE,
  603. SE_CRITICAL,
  604. SE_PENETRATE,
  605. SE_BLOCK,
  606. SE_DODGE,
  607. SE_CHINA_FIREWORK,
  608. SE_SPIN_TOP,
  609. SE_SUCCESS,
  610. SE_FAIL,
  611. SE_FR_SUCCESS,
  612. SE_LEVELUP_ON_14_FOR_GERMANY,
  613. SE_LEVELUP_UNDER_15_FOR_GERMANY,
  614. SE_PERCENT_DAMAGE1,
  615. SE_PERCENT_DAMAGE2,
  616. SE_PERCENT_DAMAGE3,
  617.  
  618. SE_AUTO_HPUP,
  619. SE_AUTO_SPUP,
  620.  
  621. SE_EQUIP_RAMADAN_RING,
  622. SE_EQUIP_HALLOWEEN_CANDY,
  623. SE_EQUIP_HAPPINESS_RING,
  624. SE_EQUIP_LOVE_PENDANT,
  625. } ;
  626.  
  627. enum ETeenFlags
  628. {
  629. TEENFLAG_NONE = 0,
  630. TEENFLAG_1HOUR,
  631. TEENFLAG_2HOUR,
  632. TEENFLAG_3HOUR,
  633. TEENFLAG_4HOUR,
  634. TEENFLAG_5HOUR,
  635. };
  636.  
  637. #include "item_length.h"
  638.  
  639. enum EDragonSoulRefineWindowSize
  640. {
  641. DRAGON_SOUL_REFINE_GRID_MAX = 15,
  642. };
  643.  
  644. enum EMisc2
  645. {
  646. DRAGON_SOUL_EQUIP_SLOT_START = INVENTORY_MAX_NUM + WEAR_MAX_NUM,
  647. DRAGON_SOUL_EQUIP_SLOT_END = DRAGON_SOUL_EQUIP_SLOT_START + (DS_SLOT_MAX * DRAGON_SOUL_DECK_MAX_NUM),
  648. DRAGON_SOUL_EQUIP_RESERVED_SLOT_END = DRAGON_SOUL_EQUIP_SLOT_END + (DS_SLOT_MAX * DRAGON_SOUL_DECK_RESERVED_MAX_NUM),
  649.  
  650. BELT_INVENTORY_SLOT_START = DRAGON_SOUL_EQUIP_RESERVED_SLOT_END,
  651. BELT_INVENTORY_SLOT_END = BELT_INVENTORY_SLOT_START + BELT_INVENTORY_SLOT_COUNT,
  652.  
  653. INVENTORY_AND_EQUIP_SLOT_MAX = BELT_INVENTORY_SLOT_END,
  654. };
  655.  
  656. #pragma pack(push, 1)
  657.  
  658. typedef struct SItemPos
  659. {
  660. BYTE window_type;
  661. WORD cell;
  662. SItemPos ()
  663. {
  664. window_type = INVENTORY;
  665. cell = WORD_MAX;
  666. }
  667.  
  668. SItemPos (BYTE _window_type, WORD _cell)
  669. {
  670. window_type = _window_type;
  671. cell = _cell;
  672. }
  673.  
  674. bool IsValidItemPosition() const
  675. {
  676. switch (window_type)
  677. {
  678. case RESERVED_WINDOW:
  679. return false;
  680. case INVENTORY:
  681. case EQUIPMENT:
  682. case BELT_INVENTORY:
  683. return cell < INVENTORY_AND_EQUIP_SLOT_MAX;
  684. case DRAGON_SOUL_INVENTORY:
  685. return cell < (DRAGON_SOUL_INVENTORY_MAX_NUM);
  686. case SAFEBOX:
  687. case MALL:
  688. return false;
  689. default:
  690. return false;
  691. }
  692. return false;
  693. }
  694.  
  695. bool IsEquipPosition() const
  696. {
  697. return ((INVENTORY == window_type || EQUIPMENT == window_type) && cell >= INVENTORY_MAX_NUM && cell < INVENTORY_MAX_NUM + WEAR_MAX_NUM)
  698. || IsDragonSoulEquipPosition();
  699. }
  700.  
  701. bool IsDragonSoulEquipPosition() const
  702. {
  703. return (DRAGON_SOUL_EQUIP_SLOT_START <= cell) && (DRAGON_SOUL_EQUIP_SLOT_END > cell);
  704. }
  705.  
  706. bool IsBeltInventoryPosition() const
  707. {
  708. return (BELT_INVENTORY_SLOT_START <= cell) && (BELT_INVENTORY_SLOT_END > cell);
  709. }
  710.  
  711. bool IsDefaultInventoryPosition() const
  712. {
  713. return INVENTORY == window_type && cell < INVENTORY_MAX_NUM;
  714. }
  715.  
  716. bool operator==(const struct SItemPos& rhs) const
  717. {
  718. return (window_type == rhs.window_type) && (cell == rhs.cell);
  719. }
  720. bool operator<(const struct SItemPos& rhs) const
  721. {
  722. return (window_type < rhs.window_type) || ((window_type == rhs.window_type) && (cell < rhs.cell));
  723. }
  724. } TItemPos;
  725.  
  726. const TItemPos NPOS (RESERVED_WINDOW, WORD_MAX);
  727.  
  728. typedef enum
  729. {
  730. SHOP_COIN_TYPE_GOLD,
  731. SHOP_COIN_TYPE_SECONDARY_COIN,
  732. } EShopCoinType;
  733.  
  734. #pragma pack(pop)
  735.  
  736. #endif
RAW Paste Data