summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Changelog-Trunk.txt3
-rw-r--r--src/map/status.c26
2 files changed, 21 insertions, 8 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index 90b268543..2fa09f053 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -3,6 +3,9 @@ Date Added
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
+2007/08/17
+ * Implemented the official dual-wield aspd equation [ultramage]
+ - using 0.7 instead of 0.66 as modifier (so aspd will be lower now)
2007/08/16
* Fixed eAthena's wrong interpretation of the respawn times [Playtester]
* Added icons for NPC_CRITICALWOUND and NPC_SLOWCAST [Playtester]
diff --git a/src/map/status.c b/src/map/status.c
index 7059bb903..21ab964a5 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -59,7 +59,6 @@ int current_equip_item_index; //Contains inventory index of an equipped item. To
int current_equip_card_id; //To prevent card-stacking (from jA) [Skotlex]
//we need it for new cards 15 Feb 2005, to check if the combo cards are insrerted into the CURRENT weapon only
//to avoid cards exploits
-void status_calc_bl_sub_hom(struct homun_data *hd, unsigned long flag); //[orn]
static void add_sc(int skill, int sc)
{
@@ -1170,13 +1169,24 @@ int status_check_visibility(struct block_list *src, struct block_list *target)
void status_calc_bl(struct block_list *bl, unsigned long flag);
- // Basic ASPD value
-#define status_base_amotion_pc(sd,status) (sd->aspd_add + \
- (sd->status.weapon < MAX_WEAPON_TYPE? \
- (1000 -4*status->agi -status->dex)*aspd_base[sd->status.class_][sd->status.weapon]/1000:\
- (1000 -4*status->agi -status->dex)*(\
- aspd_base[sd->status.class_][sd->weapontype1]+\
- aspd_base[sd->status.class_][sd->weapontype2])*2/3000))
+// Basic ASPD value
+int status_base_amotion_pc(struct map_session_data* sd, struct status_data* status)
+{
+ int amotion;
+
+ // base weapon delay
+ amotion = (sd->status.weapon < MAX_WEAPON_TYPE)
+ ? (aspd_base[sd->status.class_][sd->status.weapon]) // single weapon
+ : (aspd_base[sd->status.class_][sd->weapontype1] + aspd_base[sd->status.class_][sd->weapontype2])*7/10; // dual-wield
+
+ // percentual delay reduction from stats
+ amotion-= amotion * (4*status->agi + status->dex)/1000;
+
+ // raw delay adjustment from bAspd bonus
+ amotion+= sd->aspd_add;
+
+ return amotion;
+}
static int status_base_atk(struct block_list *bl, struct status_data *status)
{