Advertisement
Guest User

Draco_Coin_Exchanger

a guest
Jan 12th, 2012
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.48 KB | None | 0 0
  1. //================ rAthena / eAthena Script ===========================
  2. //================= Credits : =========================================
  3. //====================== All Credits go to Rikimaru ===================
  4. //================== on rathena.org for making the Script =============
  5. //========== Function : ===============================================
  6. //===== exchanges Draco Coins into Skulls or Cash =====================
  7. //============= Version : =============================================
  8. //====== v. 1.0 : Finished the Script [ Rikimaru ] ====================
  9. //====== v. 1.1 : Fixed a little Bug [ Rikimaru ] =====================
  10. //========== DO NOT REMOVE MY CREDITS!! ===============================
  11. MAPNAME,XXX,YYY,DIRECTION script Draco Coin Exchanger 904,{//CHANGE MAPNAME,X-Coord,Y-Coord,and direction
  12. //========= Settings : ================================================
  13. set .@dracon$,"[ Draco Coin Exchanger ]";
  14. set .dracocoinid,XXXX;// CHANGE THE XXXX TO THE DRACO COIN ID!!!!
  15. set .skullid,XXXX;// CHANGE THE XXXX TO THE SKULL ID!!!!
  16. //======== End of Settings ============================================
  17. mes .@dracon$;
  18. mes "Hello " + strcharinfo(0) + ",I'm";
  19. mes "able to exchange your";
  20. mes "Draco Coins to Cash or";
  21. mes "Skulls.What do you want";
  22. mes "me to do for you?";
  23. next;
  24. switch(select("Exchange to Cash:Exchange to Skulls:Nothing")) {
  25. case 1:
  26. mes .@dracon$;
  27. mes "Okay you can exchange :";
  28. mes "10 Draco Coins to 100 Cash";
  29. mes "30 Draco Coins to 350 Cash";
  30. mes "and 50 Draco Coins to 700 Cash";
  31. next;
  32. mes .@dracon$;
  33. mes "Please Input the amount";
  34. mes "of Draco Coins,which you";
  35. mes "want to exchange!";
  36. next;
  37. input @dracoamount;
  38. if (@dracoamount == 10) goto cash1;
  39. if (@dracoamount == 30) goto cash2;
  40. if (@dracoamount == 50) goto cash3;
  41. mes .@dracon$;
  42. mes "Sorry you didn't input the correct amount!";
  43. close;
  44. //
  45. cash1:
  46. mes .@dracon$;
  47. delitem .dracocoinid,@dracoamount;
  48. set #CASHPOINTS,#CASHPOINTS + 100;
  49. dispbottom "You receive 100 Cashpoints!";
  50. mes "Current Balance = "+#CASHPOINTS+" Cashpoints";
  51. close;
  52. //
  53. cash2:
  54. mes .@dracon$;
  55. delitem .dracocoinid,@dracoamount;
  56. set #CASHPOINTS,#CASHPOINTS + 350;
  57. dispbottom "You receive 350 Cashpoints!";
  58. mes "Current Balance = "+#CASHPOINTS+" Cashpoints";
  59. close;
  60. //
  61. cash3:
  62. mes .@dracon$;
  63. delitem .dracocoinid,@dracoamount;
  64. set #CASHPOINTS,#CASHPOINTS + 700;
  65. dispbottom "You receive 700 Cashpoints!";
  66. mes "Current Balance = "+#CASHPOINTS+" Cashpoints";
  67. close;
  68. //
  69. case 2:
  70. mes .@dracon$;
  71. mes "Okay you can exchange:";
  72. mes "10 Draco Coins for 100 Skulls";
  73. mes "30 Draco Coins for 350 Skulls";
  74. mes "and 50 Draco Coins for 700 Skulls";
  75. next;
  76. mes .@dracon$;
  77. mes "Please input the amount of";
  78. mes "Draco Coins you want to exchange!";
  79. next;
  80. input @dracoskullamount;
  81. if (@dracoskullamount == 10) goto skull1;
  82. if (@dracoskullamount == 30) goto skull2;
  83. if (@dracoskullamount == 50) goto skull3;
  84. mes .@dracon$;
  85. mes "Sorry you didn't input the correct amount!";
  86. close;
  87. //
  88. skull1:
  89. mes .@dracon$;
  90. delitem .dracocoinid,@dracoskullamount;
  91. getitem .skullid,100;
  92. mes "You received 100 Skulls.";
  93. close;
  94. //
  95. skull2:
  96. mes .@dracon$;
  97. delitem .dracocoinid,@dracoskullamount;
  98. getitem .skullid,350;
  99. mes "You received 350 Skulls.";
  100. close;
  101. //
  102. skull3:
  103. mes .@dracon$;
  104. delitem .dracocoinid,@dracoskullamount;
  105. getitem .skullid,700;
  106. mes "You received 700 Skulls.";
  107. close;
  108. //
  109. case 3:
  110. mes .@dracon$;
  111. mes "Okay goodbye!";
  112. close;
  113. }
  114. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement