diff options
author | Vicious <Vicious@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-02 18:50:09 +0000 |
---|---|---|
committer | Vicious <Vicious@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-02 18:50:09 +0000 |
commit | 430f60e0b89f43358026ff1a170ac8938a534244 (patch) | |
tree | 6094005321b26405258b47ce4a4de6a8ae33d806 /npc/custom/eAAC_Scripts/kafraExpress/ke_rent.txt | |
parent | 32ebde394d7762fdbb28ba9b5c3ce9a232292bb7 (diff) | |
download | hercules-430f60e0b89f43358026ff1a170ac8938a534244.tar.gz hercules-430f60e0b89f43358026ff1a170ac8938a534244.tar.bz2 hercules-430f60e0b89f43358026ff1a170ac8938a534244.tar.xz hercules-430f60e0b89f43358026ff1a170ac8938a534244.zip |
eACC scripts.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5429 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/custom/eAAC_Scripts/kafraExpress/ke_rent.txt')
-rw-r--r-- | npc/custom/eAAC_Scripts/kafraExpress/ke_rent.txt | 81 |
1 files changed, 81 insertions, 0 deletions
diff --git a/npc/custom/eAAC_Scripts/kafraExpress/ke_rent.txt b/npc/custom/eAAC_Scripts/kafraExpress/ke_rent.txt new file mode 100644 index 000000000..b2edbba4e --- /dev/null +++ b/npc/custom/eAAC_Scripts/kafraExpress/ke_rent.txt @@ -0,0 +1,81 @@ +//===== eAthena Script ======================================= +//= Kafra Express - Rental Module +//===== By: ================================================== +//= Skotlex +//===== Current Version: ===================================== +//= 1.8 +//===== Compatible With: ===================================== +//= eAthena SVN R3424+ +//===== Description: ========================================= +//= Part of the Kafra Express Script Package. +//= Rents PecoPecos, Falcons, Carts +//===== Additional Comments: ================================= +//= See config.txt for configuration. +//============================================================ + +- script keInit_rent { +OnInit: //Load Config + donpcevent "keConfig::OnLoadRent"; + end; +} + +function script F_keRent { + set @cartCost,callfunc("F_keCost",$@kert_cartCost,100); + if(@kert_cartOnly) { + set @kmenu, 2; + } else { + set @falconCost,callfunc("F_keCost",$@kert_falconCost,100); + set @pecoCost,callfunc("F_keCost",$@kert_pecoCost,100); + set @kmenu, select ( + "- Cancel", + "- Rent a Cart ("+@cartCost+"z)", + "- Rent a Falcon ("+@falconCost+"z)", + "- Rent a PecoPeco ("+@pecoCost+"z)" + ); + } + switch (@kmenu) { + case 2: //Cart + if (getskilllv(39)==0) { + callfunc "F_keIntro", -1, "Sorry, only those with the skill 'Pushcart' may rent a Cart."; + } else + if (checkcart()) { + callfunc "F_keIntro", -1, "You are already equipped."; + } else + if (!(callfunc("F_keCharge",$@kert_cartCost,100,1))) { + callfunc "F_keIntro", e_an, "Sorry, but you don't have enough Zeny."; + } else { + setcart; + emotion e_ok; + } + break; + case 3: //Falcon + if (getskilllv(127)==0) { + callfunc "F_keIntro", -1, "Sorry, only those with the skill 'Falcon Taming' may rent a Falcon."; + } else + if (checkfalcon()) { + callfunc "F_keIntro", -1, "You are already equipped."; + } else + if (!(callfunc("F_keCharge",$@kert_falconCost,100,1))) { + callfunc "F_keIntro", e_an, "Sorry, but you don't have enough Zeny."; + } else { + setfalcon; + emotion e_ok; + } + break; + case 4: //pecopeco + if (getskilllv(63)==0) { + callfunc "F_keIntro", -1, "Sorry, only those with the skill 'PecoPeco Riding' may rent a PecoPeco."; + } else + if (checkriding()) { + callfunc "F_keIntro", -1, "You are already equipped."; + } else + if (!(callfunc("F_keCharge",$@kert_pecoCost,100,1))) { + callfunc "F_keIntro", e_an, "Sorry, but you don't have enough Zeny."; + } else { + setriding; + emotion e_ok; + } + break; + } + return; +} |