summaryrefslogtreecommitdiff
path: root/npc/custom/card_remover.txt
diff options
context:
space:
mode:
authorbrianluau <brianluau@54d463be-8e91-2dee-dedb-b68131a5f0ec>2011-12-25 06:54:26 +0000
committerbrianluau <brianluau@54d463be-8e91-2dee-dedb-b68131a5f0ec>2011-12-25 06:54:26 +0000
commit1d8592b23ce221f543fb9978c88620f70280c885 (patch)
tree66b363ecaa0da42195d2c9d1b8e5cd6fe8cc33a2 /npc/custom/card_remover.txt
parent0f82fd5bc403400dc9464a8f02298416b99b0bbc (diff)
downloadhercules-1d8592b23ce221f543fb9978c88620f70280c885.tar.gz
hercules-1d8592b23ce221f543fb9978c88620f70280c885.tar.bz2
hercules-1d8592b23ce221f543fb9978c88620f70280c885.tar.xz
hercules-1d8592b23ce221f543fb9978c88620f70280c885.zip
- Standardized script headers, starting with /npc/custom/
http://rathena.org/wiki/Script_header git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15262 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/custom/card_remover.txt')
-rw-r--r--npc/custom/card_remover.txt192
1 files changed, 96 insertions, 96 deletions
diff --git a/npc/custom/card_remover.txt b/npc/custom/card_remover.txt
index c336c0cda..e0b40272d 100644
--- a/npc/custom/card_remover.txt
+++ b/npc/custom/card_remover.txt
@@ -1,99 +1,99 @@
-//===== rAthena Script =======================================
+//===== rAthena Script =======================================
//= Card Removal NPC
-//===== By: ==================================================
+//===== By: ==================================================
//= TyrNemesis^
-//===== Current Version: =====================================
+//===== Current Version: =====================================
//= 1.2
-//===== Compatible With: =====================================
+//===== Compatible With: =====================================
//= rAthena SVN
-//===== Description: =========================================
+//===== Description: =========================================
//= Removes cards from equipped items.
-//===== Additional Comments: =================================
+//===== Additional Comments: =================================
//= 1.0 First version. [TyrNemesis^]
//= 1.2 Optimized and fixed getequipname menu. [Kisuka]
-//============================================================
+//============================================================
prt_in,28,73,4 script Wise Old Woman#eAcustom 78,{
mes "[Wise Old Woman]";
mes "Good day, young one. I have the power to remove cards that you have compounded onto your equipment. Does this idea please you?";
next;
switch(select("Yes, it does.:What do you charge?:No thanks.")) {
- case 1:
- mes "[Wise Old Woman]";
- mes "Very well. Which item shall I examine for you?";
- next;
+ case 1:
+ mes "[Wise Old Woman]";
+ mes "Very well. Which item shall I examine for you?";
+ next;
- setarray .@position$[1], "Head","Body","Left hand","Right hand","Robe","Shoes","Accessory 1","Accessory 2","Head 2","Head 3";
- set .@menu$,"";
- for( set .@i,1; .@i <= 10; set .@i,.@i+1 )
- {
- if( getequipisequiped(.@i) )
- set .@menu$, .@menu$ + .@position$[.@i] + "-" + "[" + getequipname(.@i) + "]";
+ setarray .@position$[1], "Head","Body","Left hand","Right hand","Robe","Shoes","Accessory 1","Accessory 2","Head 2","Head 3";
+ set .@menu$,"";
+ for( set .@i,1; .@i <= 10; set .@i,.@i+1 )
+ {
+ if( getequipisequiped(.@i) )
+ set .@menu$, .@menu$ + .@position$[.@i] + "-" + "[" + getequipname(.@i) + "]";
- set .@menu$, .@menu$ + ":";
- }
- set .@part,select(.@menu$);
- if(!getequipisequiped(.@part)) {
- mes "[Wise Old Woman]";
- mes "Young one... Your not wearing anything there that I can remove cards from.";
- close;
- }
- if(getequipcardcnt(.@part) == 0) {
- mes "[Wise Old Woman]";
- mes "Young one... There are no cards compounded on this item. I can do nothing with it, I'm afraid.";
- close;
- }
- set .@cardcount,getequipcardcnt(.@part);
-
- if (!checkweight(1202,(.@cardcount+1))) {
- mes "^3355FFJust a minute!";
- mes "I can't offer any of my";
- mes "services to you because";
- mes "you're carrying too much";
- mes "stuff. Put your extra items in";
- mes "Kafra Storage and come again~";
- close;
- }
+ set .@menu$, .@menu$ + ":";
+ }
+ set .@part,select(.@menu$);
+ if(!getequipisequiped(.@part)) {
mes "[Wise Old Woman]";
- mes "This item has " + .@cardcount + " cards compounded on it. To perform my magic, I will need " + (200000+(.@cardcount * 25000)) + " zeny, a ^0000FFStar Crumb^000000, and a ^0000FFYellow Gemstone^000000.";
- next;
- if(select("Very well. Do it.:Nevermind.") == 2) {
- mes "[Wise Old Woman]";
- mes "Very well. Return at once if you seek my services.";
- close;
- }
- if((zeny < (200000+(.@cardcount * 25000))) || (countitem(1000) < 1) || (countitem(715) < 1)) {
- mes "[Wise Old Woman]";
- mes "You do not have all the items I require to work my magic, child. Come again when you do.";
- close;
- }
+ mes "Young one... Your not wearing anything there that I can remove cards from.";
+ close;
+ }
+ if(getequipcardcnt(.@part) == 0) {
mes "[Wise Old Woman]";
- mes "Before I begin, I must warn you--I may fail. If I do, I may destroy the cards, the item, or both. I do not give refunds. That being said, which is more important to you: The cards, or the item?";
- next;
- switch(select("I changed my mind about this.:The item.:The cards.")) {
- case 1:
- mes "[Wise Old Woman]";
- mes "Very well. Return at once if you seek my services.";
- close;
- case 2:
- set .@failtype,1;
- break;
- case 3:
- set .@failtype,2;
- }
+ mes "Young one... There are no cards compounded on this item. I can do nothing with it, I'm afraid.";
+ close;
+ }
+ set .@cardcount,getequipcardcnt(.@part);
+
+ if (!checkweight(1202,(.@cardcount+1))) {
+ mes "^3355FFJust a minute!";
+ mes "I can't offer any of my";
+ mes "services to you because";
+ mes "you're carrying too much";
+ mes "stuff. Put your extra items in";
+ mes "Kafra Storage and come again~";
+ close;
+ }
+ mes "[Wise Old Woman]";
+ mes "This item has " + .@cardcount + " cards compounded on it. To perform my magic, I will need " + (200000+(.@cardcount * 25000)) + " zeny, a ^0000FFStar Crumb^000000, and a ^0000FFYellow Gemstone^000000.";
+ next;
+ if(select("Very well. Do it.:Nevermind.") == 2) {
+ mes "[Wise Old Woman]";
+ mes "Very well. Return at once if you seek my services.";
+ close;
+ }
+ if((zeny < (200000+(.@cardcount * 25000))) || (countitem(1000) < 1) || (countitem(715) < 1)) {
mes "[Wise Old Woman]";
- mes "Very well. I shall begin.";
- set zeny,zeny - (200000+(.@cardcount * 25000));
- delitem 1000,1;
- delitem 715,1;
-
- // Replace the constants in the next 3 lines with failure chance values defined in refine_db.txt
- // First value = Total failure chance (item and cards destroyed)
- // Second value = Partial failure chance (one or the other is destroyed, player decides which one is safe)
- // Third value = Harmless failure chance (all that's lost is your investment)
+ mes "You do not have all the items I require to work my magic, child. Come again when you do.";
+ close;
+ }
+ mes "[Wise Old Woman]";
+ mes "Before I begin, I must warn you--I may fail. If I do, I may destroy the cards, the item, or both. I do not give refunds. That being said, which is more important to you: The cards, or the item?";
+ next;
+ switch(select("I changed my mind about this.:The item.:The cards.")) {
+ case 1:
+ mes "[Wise Old Woman]";
+ mes "Very well. Return at once if you seek my services.";
+ close;
+ case 2:
+ set .@failtype,1;
+ break;
+ case 3:
+ set .@failtype,2;
+ }
+ mes "[Wise Old Woman]";
+ mes "Very well. I shall begin.";
+ set zeny,zeny - (200000+(.@cardcount * 25000));
+ delitem 1000,1;
+ delitem 715,1;
+
+ // Replace the constants in the next 3 lines with failure chance values defined in refine_db.txt
+ // First value = Total failure chance (item and cards destroyed)
+ // Second value = Partial failure chance (one or the other is destroyed, player decides which one is safe)
+ // Third value = Harmless failure chance (all that's lost is your investment)
- set .@failchance,rand(100);
- /*
+ set .@failchance,rand(100);
+ /*
if(.@failchance < 2) {
next;
failedremovecards .@part,0;
@@ -105,7 +105,7 @@ prt_in,28,73,4 script Wise Old Woman#eAcustom 78,{
if(.@failchance < 8) {
if (.@failtype == 1) {
next;
- failedremovecards .@part,1;
+ failedremovecards .@part,1;
mes "[Wise Old Woman]";
mes "While I have managed to remove the cards from the item, they were destroyed in the process. The item, however, is okay.";
close;
@@ -116,30 +116,30 @@ prt_in,28,73,4 script Wise Old Woman#eAcustom 78,{
failedremovecards .@part,2;
mes "[Wise Old Woman]";
mes "Most unfortunate. I succeeded at removing the cards, but the item itself was destroyed in the process.";
- close;
+ close;
}
}
*/
- if(.@failchance < 10) {
- next;
- failedremovecards .@part,3;
- mes "[Wise Old Woman]";
- mes "I have failed to remove the cards. Luckily, however, both the item and the cards are still okay.";
- close;
- }
+ if(.@failchance < 10) {
next;
- successremovecards .@part;
+ failedremovecards .@part,3;
mes "[Wise Old Woman]";
- mes "The process was a success. Here are your cards and your item. Farewell.";
- close;
- case 2:
- mes "[Wise Old Woman]";
- mes "I charge a flat fee of 200000 zeny, plus 25000 zeny for each card I remove from the item. In addition, I need a star crumb and a yellow gemstone to work my magic.";
- close;
- case 3:
- mes "[Wise Old Woman]";
- mes "Very well. Return at once if you seek my services.";
+ mes "I have failed to remove the cards. Luckily, however, both the item and the cards are still okay.";
close;
+ }
+ next;
+ successremovecards .@part;
+ mes "[Wise Old Woman]";
+ mes "The process was a success. Here are your cards and your item. Farewell.";
+ close;
+ case 2:
+ mes "[Wise Old Woman]";
+ mes "I charge a flat fee of 200000 zeny, plus 25000 zeny for each card I remove from the item. In addition, I need a star crumb and a yellow gemstone to work my magic.";
+ close;
+ case 3:
+ mes "[Wise Old Woman]";
+ mes "Very well. Return at once if you seek my services.";
+ close;
}
}