Difference between revisions of "FF7/DamageFormula"

From Final Fantasy Inside
< FF7
Jump to navigation Jump to search
my_wiki>NFITC1
m (I'll come back to this later too)
my_wiki>NFITC1
m (off by a few bytes)
Line 8: Line 8:
 
<!-- 5X = 5 none (always hit)-->
 
<!-- 5X = 5 none (always hit)-->
 
<!-- 6X = 0, 2 physical, isCritical-->
 
<!-- 6X = 0, 2 physical, isCritical-->
<!-- 7X = 2 iscritical-->
+
<!-- 7X = 1 magical-->
<!-- 8X = 1 magical-->
+
<!-- 8X = 7 LevelBasedAccuracy-->
<!-- 9X = 7 LevelBasedAccuracy-->
+
<!-- 9X = 6 manipulate-->
<!-- AX = 6 manipulate-->
+
<!-- AX = 0, 2 physical, isCritical-->
<!-- BX = 0, 2 physical, isCritical-->
+
<!-- BX = 0 physical-->
 
<!-- CX = 8 none (always hit)-->
 
<!-- CX = 8 none (always hit)-->
 
<!-- DX = 8 none (always hit)-->
 
<!-- DX = 8 none (always hit)-->

Revision as of 23:08, 12 January 2012

Damage Formula's description

0x11:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

Damage Function 0x1


0xA0:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

Damage Function 0x1

damage = damage * (1 + number_of_status1 + 2 * number_of_status2).

number_of_status1 are calculated as sum of attacker statuses darkness, slow, silence, sadness, poison, near death.

number_of_status2 are calculated as sum of attacker statuses death sentence, slow-numb.


0xA1:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

Damage Function 0x1

if current hp less then max hp / 4 then damage = damage * 2.

if attacker in death sentence then damage = damage * 4.


0xA2:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

Damage Function 0x1

damage = damage * (1 + number_of_dead_player_units).


0xA3:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

power_modifier = total_level_of_all_enemy_target / number_of_enemy_target.

(this only use enemy units from 4 to 10 that includes in target mask after all preparation)

Damage Function 0x1


0xA4:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

power_modifier = 1 + (((current_hp * 3) / max_hp) * power_modifier).

Damage Function 0x1


0xA5:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

power_modifier = 1 + (((current_mp * 3) / max_mp) * power_modifier).

Damage Function 0x1


0xA6:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

power_modifier = 1 + (((total_ap / 10000) * power_modifier) / 16).

(total_ap is no more than ap needed for max star, so underwater materia won't work)

Damage Function 0x1



0xA7:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

power_modifier = 10 + (((number_of_kills / 128) * power_modifier) / 16).

Damage Function 0x1


0xA8:

Prepare Function 0x0 (calculate physical hit chance)

Prepare Function 0x2 (calculate critical chance)

power_modifier = 1 + (((limit_bar_value * (limit_level + 1) / 16) * power_modifier) / 16).

Damage Function 0x1


Damage Calculations

For standard damage functions

X0:

Sets Target's 02h flag to 1. (Unknown effect)

X1:

If Attack is set as "Always critical" then make damage physical type
x = Attacker's level * attacker's damage stat (depending on physical or magic type)
x = (x + Attacker's level AND 31) >> 5
y = Attacker's level + attacker's damage stat (depending on physical or magic type)
y = (y + Attacker's level AND 31) >> 5
z = attacker's damage stat + (x * y)
z = z * ( 512 - target's defense ) * attack's power
Damage = z / 16
If attack is Berserk and Attack is Physical: Damage = Damage * 3 / 2
If target is in Confu status, set target to un-confuse
If target is in Fury, Damage = Damage / 2
If attack is back-attack attack: Damage = Damage * (back attack modifier / 8)
If attacker is in Frog: Damage = Damage / 4
If target is in Sadness: Damage = Damage - (Damage * 3 / 10)
"Split Damage" -pending
If target has barrier appropriate to attack: Damage = Damage / 2
Damage = Damage * (0x5DE8BF / 100)?
If attacker is Mini'd: Damage = 0
Damage = Max( Damage * [3841..4096] / 4096 , 1 )