diff options
author | shennetsind <ind@henn.et> | 2013-11-02 18:02:36 -0200 |
---|---|---|
committer | shennetsind <ind@henn.et> | 2013-11-02 18:02:36 -0200 |
commit | 84e4e6ee1dcaf37d73ec6f590c675ce4b17352b9 (patch) | |
tree | 5022572b54a20f2931f09e98fa607f65edc21384 | |
parent | 566529c819bcf9aeb1bd3a4a691c443c2b88d076 (diff) | |
download | hercules-84e4e6ee1dcaf37d73ec6f590c675ce4b17352b9.tar.gz hercules-84e4e6ee1dcaf37d73ec6f590c675ce4b17352b9.tar.bz2 hercules-84e4e6ee1dcaf37d73ec6f590c675ce4b17352b9.tar.xz hercules-84e4e6ee1dcaf37d73ec6f590c675ce4b17352b9.zip |
Fixed Shadow System Bonuses
Item in shadow slots are now able to give bonuses properly, thanks to rosfus for pointing it out!
Also added the missing constants for script handling.
Signed-off-by: shennetsind <ind@henn.et>
-rw-r--r-- | db/const.txt | 6 | ||||
-rw-r--r-- | doc/script_commands.txt | 7 | ||||
-rw-r--r-- | src/map/pc.c | 2 | ||||
-rw-r--r-- | src/map/pc.h | 2 | ||||
-rw-r--r-- | src/map/script.c | 2 | ||||
-rw-r--r-- | src/map/script.h | 2 |
6 files changed, 17 insertions, 4 deletions
diff --git a/db/const.txt b/db/const.txt index 3c20abc4a..cdb000417 100644 --- a/db/const.txt +++ b/db/const.txt @@ -610,6 +610,12 @@ EQI_COSTUME_HEAD_LOW 11 EQI_COSTUME_HEAD_MID 12 EQI_COSTUME_HEAD_TOP 13 EQI_COSTUME_GARMENT 14 +EQI_SHADOW_ARMOR 15 +EQI_SHADOW_WEAPON 16 +EQI_SHADOW_SHIELD 17 +EQI_SHADOW_SHOES 18 +EQI_SHADOW_ACC_R 19 +EQI_SHADOW_ACC_L 20 LOOK_BASE 0 LOOK_HAIR 1 diff --git a/doc/script_commands.txt b/doc/script_commands.txt index bd0b032f1..f2ba9f6ba 100644 --- a/doc/script_commands.txt +++ b/doc/script_commands.txt @@ -2550,6 +2550,13 @@ EQI_HEAD_LOW (10) - Lower Headgear (beards, some masks) EQI_COSTUME_HEAD_LOW (11) - Lower Costume Headgear EQI_COSTUME_HEAD_MID (12) - Middle Costume Headgear EQI_COSTUME_HEAD_TOP (13) - Upper Costume Headgear +EQI_COSTUME_GARMENT (14) - Costume Garment +EQI_SHADOW_ARMOR (15) - Shadow Armor +EQI_SHADOW_WEAPON (16) - Shadow Weapon +EQI_SHADOW_SHIELD (17) - Shadow Shield +EQI_SHADOW_SHOES (18) - Shadow Shoes +EQI_SHADOW_ACC_R (19) - Shadow Accessory 2 +EQI_SHADOW_ACC_L (20) - Shadow Accessory 1 Notice that a few items occupy several equipment slots, and if the character is wearing such an item, 'getequipid' will return it's ID number diff --git a/src/map/pc.c b/src/map/pc.c index 35d883b6f..41f4a1a96 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -10257,7 +10257,7 @@ void pc_defaults(void) { { SG_MOON_ANGER, SG_MOON_BLESS, SG_MOON_COMFORT, "PC_FEEL_MOON", "PC_HATE_MOB_MOON", is_day_of_moon }, { SG_STAR_ANGER, SG_STAR_BLESS, SG_STAR_COMFORT, "PC_FEEL_STAR", "PC_HATE_MOB_STAR", is_day_of_star } }; - unsigned short equip_pos[EQI_MAX]={EQP_ACC_L,EQP_ACC_R,EQP_SHOES,EQP_GARMENT,EQP_HEAD_LOW,EQP_HEAD_MID,EQP_HEAD_TOP,EQP_ARMOR,EQP_HAND_L,EQP_HAND_R,EQP_COSTUME_HEAD_TOP,EQP_COSTUME_HEAD_MID,EQP_COSTUME_HEAD_LOW,EQP_COSTUME_GARMENT,EQP_AMMO}; + unsigned int equip_pos[EQI_MAX]={EQP_ACC_L,EQP_ACC_R,EQP_SHOES,EQP_GARMENT,EQP_HEAD_LOW,EQP_HEAD_MID,EQP_HEAD_TOP,EQP_ARMOR,EQP_HAND_L,EQP_HAND_R,EQP_COSTUME_HEAD_TOP,EQP_COSTUME_HEAD_MID,EQP_COSTUME_HEAD_LOW,EQP_COSTUME_GARMENT,EQP_AMMO, EQP_SHADOW_ARMOR, EQP_SHADOW_WEAPON, EQP_SHADOW_SHIELD, EQP_SHADOW_SHOES, EQP_SHADOW_ACC_R, EQP_SHADOW_ACC_L }; pc = &pc_s; diff --git a/src/map/pc.h b/src/map/pc.h index fc37d0ef2..8eb7e692a 100644 --- a/src/map/pc.h +++ b/src/map/pc.h @@ -731,7 +731,7 @@ struct pc_interface { #if defined(RENEWAL_DROP) || defined(RENEWAL_EXP) unsigned int level_penalty[3][RC_MAX][MAX_LEVEL*2+1]; #endif - unsigned short equip_pos[EQI_MAX]; + unsigned int equip_pos[EQI_MAX]; /* */ struct skill_tree_entry skill_tree[CLASS_COUNT][MAX_SKILL_TREE]; struct fame_list smith_fame_list[MAX_FAME_LIST]; diff --git a/src/map/script.c b/src/map/script.c index d51f27ce9..944759f39 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -18210,7 +18210,7 @@ void script_label_add(int key, int pos) { void script_defaults(void) { // aegis->athena slot position conversion table - unsigned int equip[SCRIPT_EQUIP_TABLE_SIZE] = {EQP_HEAD_TOP,EQP_ARMOR,EQP_HAND_L,EQP_HAND_R,EQP_GARMENT,EQP_SHOES,EQP_ACC_L,EQP_ACC_R,EQP_HEAD_MID,EQP_HEAD_LOW,EQP_COSTUME_HEAD_LOW,EQP_COSTUME_HEAD_MID,EQP_COSTUME_HEAD_TOP,EQP_COSTUME_GARMENT}; + unsigned int equip[SCRIPT_EQUIP_TABLE_SIZE] = {EQP_HEAD_TOP,EQP_ARMOR,EQP_HAND_L,EQP_HAND_R,EQP_GARMENT,EQP_SHOES,EQP_ACC_L,EQP_ACC_R,EQP_HEAD_MID,EQP_HEAD_LOW,EQP_COSTUME_HEAD_LOW,EQP_COSTUME_HEAD_MID,EQP_COSTUME_HEAD_TOP,EQP_COSTUME_GARMENT,EQP_SHADOW_ARMOR, EQP_SHADOW_WEAPON, EQP_SHADOW_SHIELD, EQP_SHADOW_SHOES, EQP_SHADOW_ACC_R, EQP_SHADOW_ACC_L}; script = &script_s; diff --git a/src/map/script.h b/src/map/script.h index c6cb6070b..a4d14c777 100644 --- a/src/map/script.h +++ b/src/map/script.h @@ -35,7 +35,7 @@ struct eri; //#define SCRIPT_HASH_SDBM #define SCRIPT_HASH_ELF -#define SCRIPT_EQUIP_TABLE_SIZE 14 +#define SCRIPT_EQUIP_TABLE_SIZE 20 //#define SCRIPT_DEBUG_DISP //#define SCRIPT_DEBUG_DISASM |