ghost_palace_exchange.txt 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. //===== rAthena Script =======================================
  2. //= Ghost Palace Exchange NPC.
  3. //===== Description: =========================================
  4. //= Walkthrough Conversion.
  5. //===== Changelogs: ==========================================
  6. //= 1.0 First Version. [Capuche]
  7. //============================================================
  8. dali02,51,130,4 script Dimension Traveler 4_F_SHABBY,{
  9. if (checkweight(28100,1) == 0) {// Thanos Axe
  10. mes "- You cannot proceed because you have too many items with you. -";
  11. close;
  12. }
  13. .@item_name_req$ = getitemname(6672);// Gray_Shard
  14. mes "[Dimension Traveler]";
  15. mes "Adventurer friend, <ITEM>[" + .@item_name_req$ + "]<INFO>6672</INFO></ITEM> is what I need. How about exchanging it with something I have?";
  16. next;
  17. .@type = select( "Show me your weapon.", "Show me your armor.", "Anything special?", "I do not need." ) - 1;
  18. mes "[Dimension Traveler]";
  19. switch(.@type) {
  20. case 0:
  21. mes "Oh! Are you interested in weapons? We have all the weapons we can get from the Ghost Palace. Why don't you choose one?";
  22. break;
  23. case 1:
  24. mes "Armor? We have all the armors we can get from the Ghost Palace. Why don't you choose one?";
  25. break;
  26. case 2:
  27. mes "Huhh! It seems like many of them already heard that I have the best stuff. Feel free to check out my collections.";
  28. break;
  29. case 3:
  30. mes "Goodbye friend~ Come again!";
  31. close;
  32. }
  33. next;
  34. mes "[Dimension Traveler]";
  35. mes "Ah! The number that is written beside <ITEM>[" + .@item_name_req$ + "]<INFO>6672</INFO></ITEM> will be needed.";
  36. mes "Please keep that in mind.";
  37. switch(.@type) {
  38. case 0:
  39. setarray .@items[0],
  40. 13441, 200, // Thanos Sword
  41. 21009, 200, // Thanos Great Sword
  42. 1438, 200, // Thanos Spear
  43. 1496, 200, // Thanos Long Spear
  44. 1669, 200, // Thanos Staff
  45. 2023, 200, // Thanos Rod
  46. 18119, 200, // Thanos Bow
  47. 13093, 200, // Thanos Dagger
  48. 28000, 200, // Thanos Katar
  49. 1836, 200, // Thanos Knuckle
  50. 16028, 200, // Thanos Hammer
  51. 28100, 200, // Thanos Axe
  52. 1933, 200, // Thanos Violin
  53. 1988, 200; // Thanos Whip
  54. break;
  55. case 1:
  56. setarray .@items[0],
  57. 2187, 100, // Shield Of Gray
  58. 15090, 100, // Armor Of Gray
  59. 15091, 100, // Gray Robe
  60. 20721, 100, // Cloak Of Gray
  61. 22033, 100, // Boots Of Gray
  62. 18820, 100; // Gray Helmet
  63. break;
  64. case 2:
  65. setarray .@items[0],
  66. 27184, 10000, // Knight Sakray Card
  67. 23676, 50, // Gray Charcoal Melee (Melee)
  68. 23677, 50, // Gray Charcoal Magic (Magic)
  69. 23678, 50, // Gray Charcoal Range (Range)
  70. 27184, 10000; // Knight Sakray Card
  71. break;
  72. }
  73. .@size = getarraysize(.@items);
  74. for ( .@i = 0; .@i < .@size; .@i += 2 )
  75. .@menu$ += getitemname(.@items[.@i]) + " - " + .@items[.@i+1] + ":";
  76. while(true) {
  77. next;
  78. .@s = (select(.@menu$) - 1) * 2;
  79. mes "[Dimension Traveler]";
  80. if (.@type != 1) // armor type doesn't display item info
  81. mes "Do you mean <ITEM>[" + getitemname(.@items[.@s]) + "]<INFO>" + .@items[.@s] + "</INFO></ITEM>?";
  82. mes "" + .@items[.@s+1] + " ^006400" + .@item_name_req$ + "^000000 are required in exchange.";
  83. next;
  84. switch( select( "Let's exchange.", "Let me see other stuff.", "I will come back later." ) ) {
  85. case 1:
  86. break;
  87. case 2:
  88. mes "[Dimension Traveler]";
  89. switch(.@type) {
  90. case 0:
  91. mes "I have more than enough weapons.";
  92. break;
  93. case 1:
  94. mes "We have many armors for you. Why don't you pick one?";
  95. break;
  96. case 2:
  97. mes "If you bring me " + .@item_name_req$ + ", I will trade it with anything you want.";
  98. break;
  99. }
  100. continue;
  101. case 3:
  102. mes "[Dimension Traveler]";
  103. mes "Take care friend~ See you next time!";
  104. close;
  105. }
  106. if (countitem(6672) < .@items[.@s+1]) {
  107. mes "[Dimension Traveler]";
  108. mes "You put me in a difficult situation, friend.";
  109. mes "I am in need of " + .@item_name_req$ + ". I will exchange it for ^006400" + .@items[.@s+1] + " " + .@item_name_req$ + "^000000.";
  110. close;
  111. }
  112. mes "[Dimension Traveler]";
  113. mes "Thank you. Come back if you need anything else.";
  114. delitem 6672, .@items[.@s+1];
  115. getitem .@items[.@s], 1;
  116. close;
  117. }
  118. }