// Card removal NPC by TyrNemesis^
// DANGEROUS! TODO: Think.. think 8) [Lupus]
// Transelated By Memory.


prontera,164,106,4	script	һʦ	709,{

UPGRADEROOT:
	mes "[һʦ]";
	mes "ð~~. ҿ԰һ, Ҫ";
	mes "ȷϼǮûлͷ·";
	next;
	menu "һ״̬-100W",TO_ALL_STATUS,
		 "һǿ״̬-500W",TO_SUPER_STATUS,
		 "һɾǷߣ0Z",TO_DO,
		 "һȫ-1W",TO_IDENTITY,
		 "һȫ޸-10W",TO_REPAIRE,
		 "һ+10-1E",TO_REFINE_10,
		 "һ+15-8E",TO_REFINE_15,
		 "һ+20-16E",TO_REFINE_20,
		 "һƲ0Z",TO_BANKRUPTCY,
		 "һɱ-100W",TO_KILL_OTHER,
		 ",벻Ͷ.",TO_CLOSE;


TO_IDENTITY:
	set @money,10000;
	if(zeny >= @money) {
		set zeny,(zeny - @money);
		callfunc("F_IDENTIFY_ALL");
		goto TO_CLOSE;

	} else {
		goto NO_ZENY;
	}


TO_REPAIRE:
	set @money,100000;
	if(zeny >= @money) {
		set zeny,(zeny - @money);
		repairall;
		goto TO_CLOSE;

	} else {
		goto NO_ZENY;
	}


TO_ALL_STATUS:
	set @money,1000000;
	if(zeny >= @money) {
		set zeny,(zeny - @money);

		percentheal 100,100;												//  HP/SP
		skilleffect "AL_BLESSING",0; sc_start SC_BLESSING,600000,10;		// ʹ֮͸
		skilleffect "AL_INCAGI",0; sc_start SC_INCREASEAGI,600000,10;		// 
		skilleffect "AL_ANGELUS",0; sc_start SC_ANGELUS,600000,10;			// ʹ֮ϱ
		skilleffect "SC_IMPOSITIO",0; sc_start SC_IMPOSITIO,600000,5;		// 
		skilleffect "HP_ASSUMPTIO",0; sc_start SC_ASSUMPTIO,600000,5;		// ʥĸ֮
		skilleffect "PR_MAGNIFICAT",0; sc_start SC_MAGNIFICAT,600000,3;		// ʥĸ̸֮
		skilleffect "AM_CP_WEAPON",0; sc_start SC_CP_WEAPON,600000,10;		// ѧ
		skilleffect "AM_CP_SHIELD",0; sc_start SC_CP_SHIELD,600000,10;		// ѧƱ
		skilleffect "AM_CP_ARMOR",0; sc_start SC_CP_ARMOR,600000,10;		// ѧױ
		skilleffect "AM_CP_HELM",0; sc_start SC_CP_HELM,600000,10;			// ѧͷ
		sc_start SC_SUFFRAGIUM,600000,3;									// 
		sc_start SC_KYRIE,600000,10;										// а֮
		sc_start SC_GLORIA,600000,5;										// ̸֮
		sc_start SC_ASPDPOTION2,600000,10;									// ɫҩˮ

		goto TO_CLOSE;

	} else {
		goto NO_ZENY;
	}


TO_SUPER_STATUS:
	set @money,5000000;
	if(zeny >= @money) {
		set zeny,(zeny - @money);

		percentheal 100,100;												//  HP/SP
		skilleffect "AL_BLESSING",0; sc_start SC_BLESSING,600000,10;		// ʹ֮͸
		skilleffect "AL_INCAGI",0; sc_start SC_SPEEDUP1,600000,10;			// ƶٶ״̬1(ȼ)
		skilleffect "AL_ANGELUS",0; sc_start SC_ANGELUS,600000,10;			// ʹ֮ϱ
		skilleffect "SC_IMPOSITIO",0; sc_start SC_IMPOSITIO,600000,5;		// 
		skilleffect "HP_ASSUMPTIO",0; sc_start SC_ASSUMPTIO,600000,5;		// ʥĸ֮
		skilleffect "PR_MAGNIFICAT",0; sc_start SC_MAGNIFICAT,600000,3;		// ʥĸ̸֮
		skilleffect "AM_CP_WEAPON",0; sc_start SC_CP_WEAPON,600000,10;		// ѧ
		skilleffect "AM_CP_SHIELD",0; sc_start SC_CP_SHIELD,600000,10;		// ѧƱ
		skilleffect "AM_CP_ARMOR",0; sc_start SC_CP_ARMOR,600000,10;		// ѧױ
		skilleffect "AM_CP_HELM",0; sc_start SC_CP_HELM,600000,10;			// ѧͷ
		sc_start SC_SUFFRAGIUM,600000,3;									// 
		sc_start SC_KYRIE,600000,10;										// а֮
		sc_start SC_GLORIA,600000,5;										// ̸֮
		sc_start SC_ASPDPOTION3,600000,10;									// ״̬3(Ȳɫ˸죬̿ͳԶҩ)

		skilleffect "SN_WINDWALK",0; sc_start SC_WINDWALK,600000,5;			// ֮
		sc_start SC_HALLUCINATIONWALK,600000,1;								// Ӱ
		sc_start SC_ADRENALINE,600000,5;									// ٶȼ
		sc_start SC_WEAPONPERFECTION,600000,5;								// 
		sc_start SC_MAXIMIZEPOWER,600000,5;									// ֵ
		sc_start SC_ENDURE,600000,10;										// 
		sc_start SC_LOUD,600000,1;											// ź
		sc_start SC_ENERGYCOAT,600000,1;									// 
		sc_start SC_AUTOGUARD,600000,10;									// Զ
		sc_start SC_RUWACH,600000,1;										// 
		sc_start SC_KAUPE,600000,3;											// رһ()
		sc_start SC_KAIZEL,600000,7;										// ()
		
		goto TO_CLOSE;

	} else {
		goto NO_ZENY;
	}


TO_REFINE_10:
	set @money,100000000;
	if(zeny >= @money) {
		set @refine_num,10;
		goto TO_SELECT;

	} else {
		goto NO_ZENY;
	}


TO_REFINE_15:
	set @money,800000000;
	if(zeny >= @money) {
		set @refine_num,15;
		goto TO_SELECT;

	} else {
		goto NO_ZENY;
	}


TO_REFINE_20:
	set @money,1600000000;
	if(zeny >= @money) {
		set @refine_num,20;
		goto TO_SELECT;

	} else {
		goto NO_ZENY;
	}


TO_SELECT:
	mes "[һʦ]";
	mes "֣뾫ļװ?";
	next;
	menu "emmm, ...",TO_CLOSE,
		 getequipname(0),SLOT00,
	     getequipname(1),SLOT01,
	     getequipname(2),SLOT02,
	     getequipname(3),SLOT03,
	     getequipname(4),SLOT04,
	     getequipname(5),SLOT05,
	     getequipname(6),SLOT06,
	     getequipname(7),SLOT07,
	     getequipname(8),SLOT08,
	     getequipname(9),SLOT09;


SLOT00:
	set @slot,0;	// װƷ-
	goto TO_REFINE;

SLOT01:
	set @slot,1;	// װƷ-
	goto TO_REFINE;

SLOT02:
	set @slot,2;	// Ь
	goto TO_REFINE;

SLOT03:
	set @slot,3;	// 
	goto TO_REFINE;

SLOT04:
	set @slot,4;	// ͷ-
	goto TO_REFINE;

SLOT05:
	set @slot,5;	// ͷ-
	goto TO_REFINE;

SLOT06:
	set @slot,6;	// ͷ-
	goto TO_REFINE;

SLOT07:
	set @slot,7;	// ·
	goto TO_REFINE;

SLOT08:
	set @slot,8;	// 
	goto TO_REFINE;

SLOT09:
	set @slot,9;	// 
	goto TO_REFINE;


TO_REFINE:
	mes "[һʦ]";
	set @cur_refine,getequiprefinerycnt(@slot);
	set @refine_count,(@refine_num - @cur_refine);

	if(@refine_count <= 0) {
		mes "TMأѾ[+" + @cur_refine + "]ŲҰ...";

	} else {
		set zeny,(zeny - @money);
		successrefitem @slot,@refine_count;
		mes "Ѿˣ򰲰ɣ~";
	}
	next;
	goto TO_CLOSE;


TO_BANKRUPTCY:
	mes "[һʦ]";
	mes "һûǮȷ?";
	next;
	menu "emmm, ...",TO_CLOSE,
		 "ɵǮ",_TO_BANKRUPTCY;

_TO_BANKRUPTCY:
	set zeny,0;
	mes "[һʦ]";
	mes "ٺ~ ɵ~";
	next;
	goto TO_CLOSE;


TO_KILL_OTHER:
	set @money,1000000;
	set @money_tips,100000;
	if(zeny >= @money) {
		mes "[һʦ]";
		mes "㣺";
		mes "Ӷİ˳ɽתĿ˺ţ";
		mes "Ǳ鷳ѣ";
		next;

		mes "[һʦ]";
		mes "д [ʼ] ɣ";
		mes "һҲܴ";
		mes "ͬʱӣ";
		mes "ȻܻʧЧɱˣ";

		input @player_name$;
		next;
		mes "[һʦ]";

		set @succ_rate,rand(100);
		if(@succ_rate < 40) {
			mes "ɱʧܣ";
			mes "̫Ŷ";
			mes "Ȼȡ 10% ķѣ";

			set zeny,(zeny - @money_tips);

		} else {
			mes "ɱɹ";
			mes "[" + @player_name$ + "] Ѿ poorguy ˣ";
			mes "һƺ";

			set zeny,(zeny - @money);
			charcommand("#zeny " + @player_name$ + " 800000");
			atcommand("@nuke " + @player_name$);
		}

		end;
		close;

	} else {
		goto NO_ZENY;
	}


TO_CLEAR_ITEMS:
	clearitem;
	next;
	goto TO_CLOSE;


TO_DO:
	mes "[һʦ]";
	mes "˹ڿ...";
	next;
	goto TO_CLOSE;


NO_ZENY:
	mes "[һʦ]";
	mes "Զ";
	close;


TO_CLOSE:
	mes "[һʦ]";
	mes "OJBK,";
	close;

}
