summaryrefslogblamecommitdiff
path: root/npc/functions/ferry.txt
blob: d0fcd04fa8fb33f5ad443b4d319c966e836d43b2 (plain) (tree)
1
2
3
4
5
6
7
8
9
10


                                 

                                  
                               

                                          

                                             
 








                                                                     


                                                                     
                                                            






















                                         









                                      







                                                       
// The ferry system

function	script	Ferry	{
	set @cost_tulimshar, 1000;
	set @cost_hurnscald, 1000;
	set @cost_candor, 3000;
	mes "Where would you like to go?";
	next;
	if (BaseLevel < 40) goto L_PlainMenu;
	goto L_MenuWithCandor;


L_PlainMenu:
	menu
		"Tulimshar (" + @cost_tulimshar + "GP)", L_Tulimshar,
		"Hurnscald (" + @cost_hurnscald + "GP)", L_Hurnscald,
		"Nevermind", -;
	close;

L_MenuWithCandor:
	menu
		"Tulimshar (" + @cost_tulimshar + "GP)", L_Tulimshar,
		"Hurnscald (" + @cost_hurnscald + "GP)", L_Hurnscald,
		"Candor (" + @cost_candor + "GP)", L_Candor,
		"Nevermind", -;
	close;

L_Tulimshar:
	if (@loc == DOCK_tulimshar)
		goto L_AlreadyThere;
	if (zeny < @cost_tulimshar)
		goto L_NotEnoughGP;
	
	set zeny, zeny - @cost_tulimshar;
	warp "022-1.gat", 76, 72;
	close;

L_Hurnscald:
	if (@loc == DOCK_hurnscald)
		goto L_AlreadyThere;
	if (zeny < @cost_hurnscald)
		goto L_NotEnoughGP;
	
	set zeny, zeny - @cost_hurnscald;
	warp "008-1.gat", 137, 64;
	close;

L_Candor:
	if (@loc == DOCK_candor)
		goto L_AlreadyThere;
	if (zeny < @cost_candor)
		goto L_NotEnoughGP;
	
	set zeny, zeny - @cost_candor;
	warp "029-1.gat", 25, 37;
	close;

L_AlreadyThere:
	mes "You're already here!";
	close;

L_NotEnoughGP:
	mes "You don't have enough money to go there!";
	close;
}