//===== eAthena Script ======================================= 
//= Clothes Dyer
//===== By: ================================================== 
//= Usnul
//===== Current Version: ===================================== 
//= 2.0
//===== Compatible With: ===================================== 
//= eAthena 1.0+
//===== Description: ========================================= 
//= Clothes dyer with standard palletes
//===== Additional Comments: ================================= 
//= Fully working
//============================================================ 


// Dyer Ginedin Rephere ---------------------------------------------------
prt_in.gat,284,168,2	script	Dyer Ginedin Rephere	55,{
	mes "[Dyer Ginedin Rephere]";
	mes "11... 12... Mmm... good.  I think I'll be able ot finish before tonights party.  Oh! I didn't notice that you were here.   Anyway how may I assist you?";
M_Menu:
	next;
	menu "-Talk",L_Talk, "-Dye Clothing",L_Dye, "-Price list",L_PriceList, "-Cancel",L_End;
	
	L_Talk:
		mes "[Dyer Ginedin Rephere]";
		mes "Life may have gotten a little better.... but when I look at all of the orders I've recieved... Whew!";
		mes "It seems that the young women of Rune Midgard must be very well off these days.";
		next;
		mes "[Dyer Ginedin Rephere]";
		mes "Not that I think that they are indulging in anything luxurious mind you.";
		mes "I don't think there is anything wrong with the pursuit of beauty and being fashionable.";
		next;
		mes "[Dyer Ginedin Rephere]";
		mes "For us humans, who have no colorful fur or decorative scales, clothes are one of the few ways we have to display our personality, style, and beauty.";
		next;
		mes "[Dyer Ginedin Rephere]";
		mes "Haha... When I think about it, I really feel that my job is worthwhile.  I believe that I provide a service that the people desire.";
		next;
		mes "[Dyer Ginedin Rephere]";
		mes "Can you feel it too? The energy that is released when rough fabric and leather are brought to life with color?.....";
		next;
		mes "[Dyer Ginedin Rephere]";
		mes "Although the process is very tedious and time consuming, the joy and happiness I feel when a dress is finished.....";
		mes "more than makes up for all of the hard work!!";
		goto M_Menu;

	L_Dye:
		mes "[Dyer Ginedin Rephere]";
		if(Class==0) goto sL_Novice;
		if(Class==12) goto L_Assassin_M;
		mes "Oh... you need my work? Well... okay sounds good.";
		next;
		mes "[Dyer Ginedin Rephere]";
		mes "Please choose a color that suits you.";
		next;
		if(Sex==0) goto Female_dye;
//=================================
// Clothing Dyeing for Males
//=================================

Male_dye:
		//1 Class
		if(Class==5 || Class==1) goto L_Wiz_Hunt_Bard_SN_M;
		if(Class==2) goto L_Mage_M;
		if(Class==3) goto L_Archer_M;
		if(Class==4) goto L_Aco_M;
		if(Class==6) goto L_Thief_M;
		
		//2 Class
		if(Class==7 || Class==14) goto L_Knight_Crus_M;
		if(Class==8 || Class==15) goto L_Priest_Monk_M;
		if(Class==9 || Class==11 || Class==19 || Class==23) goto L_Wiz_Hunt_Bard_SN_M;
		if(Class==10 || Class==18) goto L_BlackSmith_Alchemist_M;
//		if(Class==12) goto L_Assassin_M;
		if(Class==17) goto L_Rogue_M;
	
	//1 Class
	L_Mage_M:
		set @red, 1;
		set @violet, 2;
		set @orange, 3;
		set @white, 4;
		menu "- Red",L_Dye_Red,"- Violet",L_Dye_Violet,"- Orange",L_Dye_Orange,"- White",L_Dye_White,"- Cancel",L_End;
	L_Archer_M:
		set @red, 1;
		set @violet, 2;
		set @green, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Violet",L_Dye_Violet,"- Green",L_Dye_Green,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Aco_M:
		set @blue, 1;
		set @red, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Thief_M:
		set @blue, 1;
		set @red, 2;
		set @green, 3;
		set @white, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- White",L_Dye_White,"- Cancel",L_End;
		
	//2 Class
	L_Knight_Crus_M:
		set @orange, 1;
		set @violet, 2;
		set @red, 3;
		set @black, 4;
		menu "- Orange",L_Dye_Orange,"- Violet",L_Dye_Violet,"- Red",L_Dye_Red,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Priest_Monk_M:
		set @blue, 1;
		set @green, 2;
		set @red, 3;
		set @white, 4;
		menu "- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- Red",L_Dye_Red,"- White",L_Dye_White,"- Cancel",L_End;
	L_Wiz_Hunt_Bard_SN_M:
		set @red, 1;
		set @blue, 2;
		set @green, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_BlackSmith_Alchemist_M:
		set @red, 1;
		set @green, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Green",L_Dye_Green,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Assassin_M:
		mes "I'm am sorry but I currently cannot dye male Assassin clothing.";
		close;
//		set @blue, 1;
//		set @red, 2;
//		set @green, 3;
//		set @black, 4;
//		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Rogue_M:
		set @red, 2;
		set @green, 3;
		menu "- Red",L_Dye_Red,"- Green",L_Dye_Green,"- Cancel",L_End;

//=================================
// Clothing Dyeing for Females
//=================================	
Female_dye:
		//1 Class
		if(Class==1 || Class==4) goto L_Sword_Aco_F;
		if(Class==2) goto L_Knight_Crus_F;
		if(Class==3) goto L_Priest_F;
		if(Class==5) goto L_Merch_F;
		//2 Class
		if(Class==7 || Class==14) goto L_Knight_Crus_F;
		if(Class==8) goto L_Priest_F;
		if(Class==9 || Class==16) goto L_Wiz_Sage_F;
		if(Class==10 || Class==18) goto L_BlackSmith_Alchemist_F;
		if(Class==11 || Class==20) goto L_Hunt_Dancer_F;
		if(Class==12 || Class==17) goto L_Assassin_Rogue_F;
		if(Class==23) goto L_SN_F;
	
	//1 Class
	L_Sword_Aco_F:
		set @blue, 1;
		set @red, 2;
		set @green, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Merch_F:
		set @violet, 1;
		set @blue, 2;
		set @green, 3;
		set @black, 4;
		menu "- Violet",L_Dye_Violet,"- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Thief_F:
		set @blue, 1;
		set @red, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;
	
	//2 Class
	L_Knight_Crus_F:
		set @red, 1;
		set @blue, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Priest_F:
		set @red, 1;
		set @green, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Green",L_Dye_Green,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Wiz_Sage_F:
		set @red, 1;
		set @blue, 2;
		set @white, 3;
		set @green, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- White",L_Dye_White,"- Green",L_Dye_Green,"- Cancel",L_End;
	L_Hunt_Dancer_F:
		set @red, 1;
		set @blue, 2;
		set @green, 3;
		set @violet, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- Green",L_Dye_Green,"- Violet",L_Dye_Violet,"- Cancel",L_End;
	L_BlackSmith_Alchemist_F:
		set @red, 1;
		set @green, 2;
		set @violet, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Green",L_Dye_Green,"- Violet",L_Dye_Violet,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_Assassin_Rogue_F:
		set @red, 1;
		set @yellow, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Yellow",L_Dye_Yellow,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;
	L_SN_F:
		set @blue, 1;
		set @red, 2;
		set @white, 3;
		set @black, 4;
		menu "- Red",L_Dye_Red,"- Blue",L_Dye_Blue,"- White",L_Dye_White,"- Black",L_Dye_Black,"- Cancel",L_End;

L_Dye_Orange:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(980) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes Orange.";
		setlook 7,@orange;
		delitem 980,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_Violet:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(981) < 1) goto  sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes Violet.";
		setlook 7,@violet;
		delitem 981,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_Red:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(975) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes red.";
		setlook 7,@red;
		delitem 975,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_Black:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(983) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes black.";
		setlook 7,@black;
		delitem 983,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_Green:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(979) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes green.";
		setlook 7,@green;
		delitem 979,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_Blue:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(978) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes blue.";
		setlook 7,@blue;
		delitem 978,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_White:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(982) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes white.";
		setlook 7,@white;
		delitem 982,1;
		set Zeny, Zeny - 10000;
		close;
L_Dye_Yellow:
		mes "[Dyer Ginedin Rephere]";
		if(countitem(976) < 1) goto sL_NoDye;
		if(Zeny < 10000) goto sL_Zeny;
		mes "Ok. I will dye you clothes yellow.";
		setlook 7,@yellow;
		delitem 976,1;
		set Zeny, Zeny - 10000;
		close;
		
		sL_Sorry:
			mes "Wow, your clothes is very strange, I haven't seen anything like it before . Hmmm... I'm sorry, but there is no way I can paint it.";
			close;
		sL_NoDye:
			mes "For me to dye your clothes, I'll need the appropriate Dyestuff.  Please check my price list for the information.";
			next;
			goto L_PriceList;

		sL_Zeny:
			mes "I'm sorry but you don't have enough money.";
			close;
			
		sL_Novice:
			mes "I'm sorry, but first you need to get a job.";
			close;
			

	L_PriceList:
		mes "[Dyer Ginedin Rephere]";
		mes "Here is the list of colors you can choose from and their prices:";
		mes " ";
		mes " - ^FF4422Red^000000: 10000 zeny, 1 Scarlet Dyestuff";
		mes " - ^D5A500Yellow^000000: 10000 zeny, 1 Lemon Dyestuff";
		mes " - ^AA00AAViolet^000000: 10000 zeny, 1 Violet Dyestuff";
		mes " - ^FF8800Orange^000000: 10000 zeny, 1 Orange Dyestuff";
		mes " - ^4422FFBlue^000000: 10000 zeny, 1 CobaltBlue Dyestuff";
		mes " - ^009500Green^000000: 10000 zeny, 1 DarkGreen Dyestuff";
		goto M_Menu;

	L_End:
		mes "[Dyer Ginedin Rephere]";
		mes "Make yourself at home. Even though I don't have time for you.";
		close;
}
