diff options
author | L0ne_W0lf <L0ne_W0lf@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2010-08-03 18:27:00 +0000 |
---|---|---|
committer | L0ne_W0lf <L0ne_W0lf@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2010-08-03 18:27:00 +0000 |
commit | 2c9cbc9cc309ec61a4a62c59ac2a6c678fd8b478 (patch) | |
tree | 47af6729a0757215798873f52b9c62971336df4a /npc/other/Global_Functions.txt | |
parent | 419927ac9f5ea5b71b21b52728bb56925b797937 (diff) | |
download | hercules-2c9cbc9cc309ec61a4a62c59ac2a6c678fd8b478.tar.gz hercules-2c9cbc9cc309ec61a4a62c59ac2a6c678fd8b478.tar.bz2 hercules-2c9cbc9cc309ec61a4a62c59ac2a6c678fd8b478.tar.xz hercules-2c9cbc9cc309ec61a4a62c59ac2a6c678fd8b478.zip |
* A rather large overhaul of the battlegrounds.
- in bg_common.txt, stripped out KvM npcs, fixed coordinates.
- Needs to be tested, none of the BG files are on by default.
- Created subfolder battleground/KvM/ which now holds KVM files.
- Added kvm_enter.txt, which warps players to the waiting rooms.
- Added kvm_item_pay.txt, which holds the point redemption NPC.
- Made the KvM battlegrounds work closer to official, needs work.
* Corrected variable typos in the acolyte arena. (bugreport:4374)
* Corrected donpcevent typo in the party arena. (bugreport:4374)
* Added two global functions which will return equip data as strings.
- F_GetWeaponType: returns the type of weapon by 'look', (ie "Dagger")
- F_GetArmorType: returns the kind of armor via 'equip loc'. (ie "Armor")
* Fixed duplicate documentation for getitemslot. (bugreport:4362)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14369 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/other/Global_Functions.txt')
-rw-r--r-- | npc/other/Global_Functions.txt | 55 |
1 files changed, 54 insertions, 1 deletions
diff --git a/npc/other/Global_Functions.txt b/npc/other/Global_Functions.txt index 37a3c556c..cd18b3a22 100644 --- a/npc/other/Global_Functions.txt +++ b/npc/other/Global_Functions.txt @@ -3,7 +3,7 @@ //===== By: ================================================== //= Lupus, kobra_k88 //===== Current Version: ===================================== -//= 2.15 +//= 2.16 //===== Compatible With: ===================================== //= eAthena 1.0 //===== Description: ========================================= @@ -38,6 +38,7 @@ //= 2.13 Added more unused vars to F_ClearGarbage [Lupus] //= 2.14 Added old novice variables to F_ClearGarbage. [L0ne_W0lf] //= 2.15 Added no unused DTS variables to F_ClearGarbage. [L0ne_W0lf] +//= 2.6 Added F_GetWeaponType, and F_GetArmorType. [L0ne_W0lf] //============================================================ @@ -257,3 +258,55 @@ function script F_Load2Skills { set ADV_QSK2,0; //Clear var return; } + +////////////////////////////////////////////////////////////////////////////////// +// *** Function "F_GetWeaponType": Determine weapon type by view +////////////////////////////////////////////////////////////////////////////////// +function script F_GetWeaponType { + switch(getiteminfo(getarg(0),11)) { + case 1: return "Dagger"; break; + case 2: return "One-handed Sword"; break; + case 3: return "Two-handed Sword"; break; + case 4: return "One-handed Spear"; break; + case 5: return "Two-handed Spear"; break; + case 6: return "One-handed Axe"; break; + case 7: return "Two-handed Axe"; break; + case 8: return "Mace"; break; + //case 9: return "Unused"; break; + case 10: return "Staff"; break; + case 11: return "Bow"; break; + case 12: return "Knuckle"; break; + case 13: return "Instrument"; break; + case 14: return "Whip"; break; + case 15: return "Book"; break; + case 16: return "Katar"; break; + case 17: return "Revolver"; break; + case 18: return "Rifle"; break; + case 19: return "Gatling gun"; break; + case 20: return "Shotgun"; break; + case 21: return "Grenade Launcher"; break; + case 22: return "Shuriken"; break; + default: return "Unable to Determine Equip Type"; break; + } + end; +} + +////////////////////////////////////////////////////////////////////////////////// +// *** Function "F_GetArmorType": Determine equipment type by equip location +////////////////////////////////////////////////////////////////////////////////// +function script F_GetArmorType { + switch(getiteminfo(getarg(0),5)) { + case 001: return "Lower Headgear"; break; + case 2: return "Weapon"; break; + case 4: return "Garment"; break; + case 8: return "Accessory"; break; + case 16: return "Armor"; break; + case 32: return "Shield"; break; + case 64: return "Shoes"; break; + case 128: return "Accessory"; break; + case 256: return "Upper Headgear"; break; + case 512: return "Middle Headgear"; break; + default: return "Unable to Determine Equip Location"; break; + } + end; +} |