This repository was archived by the owner on Aug 12, 2024. It is now read-only.
Repository navigation
Item
Sam edited this page Sep 22, 2023
·
11 revisions
This page contains every new property and function added to item.lua.
-
bolt_count: Determines the amount of bolts, or bars, this item adds to a battler's total bolts. Default value is 1 for weapons, 0 for armors. This should always be an integer. -
bolt_speed: Determines how fast the bolts move, as well as how large the attack box is. Default value is 8 for weapons, 0 for armors. It's recommended to stick to multiples of 8 while changing this, as desynced bolts may become extremely difficult to hit. -
bolt_offset: Affects the starting position of the first bolt. Default value is 0. Positive values move it right, negative values move it left. -
critical_bonus: Adds extra points to a party member's attack if they get a crit. Default value is 0.
-
bolt_accel: Determines the acceleration of every bolt in a battler's lane. Default value is 0. This tends to get fast quickly because of how acceleration works, so lower values (i.e. 0.6) are recommended. -
bolt_target: Affects the position of the critical box. Default value is 0. Positive values move it right, negative values move it left. -
bolt_miss_threshold: Determines how far a bolt must be from the crit box to count as a miss. Default value is -5.
-
critical_threshold: Determines the score leniency for a crit. Higher values mean it's harder to get a crit. Default value is 30. -
multibolt_variance: A table of tables that determines the distance the next bolt spawns from the last. WhengetMultiboltVariance(index)is called, it picks a value from the table at the specified index, which corresponds to the current bolt. If there are more bolts than entries, the last table is repeated. -
max_points: In most situations, you should leave this alone. Determines the max points of a multibolt weapon. Default value iscritical_threshold * 3.5.
-
getBoltCount(): returnsbolt_count -
getBoltSpeed(): returnsbolt_speed -
getBoltOffset(): returnsbolt_offset -
getBoltCriticalBonus(): returnscritical_bonus
-
getBoltBoltAcceleration(): returnsbolt_accel -
getBoltTarget(): returnsbolt_target -
getBoltMissThreshold(): returns-5if nil,bolt_miss_thresholdotherwise
-
getCriticalThreshold(): returnscritical_threshold -
getMultiboltVariance(index): If the index is valid, it returns a random entry frommultibolt_variance[index]. Otherwise, it returns a random entry from the last entry (multibolt_variance[#multibolt_variance]). -
getMaxPoints(): returnscritical_threshold * 3.5if nil,max_pointsotherwise
-
onHit(battler, score, bolts, close): Handles what a bolt should do when it's hit. Called for every equip. Must return score. -
onWeaponMiss(battler, score, bolts, close): Weapons only. Called at the same time asonArmorMiss. Handles what a bolt should do when it's missed. Must return score. -
onArmorMiss(battler, score, bolts, close): Armors only, empty by default, Called at the same time asonWeaponMiss. Handles what a bolt should do when it's missed. Must return score. -
onDamage(action, battler, enemy, score, bolts, close): Weapon only. Called when a battler attacks. -
onBoltBurst(battler, score, bolts, close): Called viaonHit. Handles audiovisual effects for a bolt as it bursts and gets removed.
-
evaluateHit(battler, close): Called when a bolt is hit. Depending on how close the bolt is to the crit box, a higher score is added. Must return an integer. -
checkAttackEnd(battler, score, bolts, close): Called viaonHit. Checks if all of the bolts in a lane are gone. If they are,evaluateScoreis called. Must return score. -
evaluateScore(battler, score, bolts, close): Called viaonAttack. Returns a score based on total points.
-
battler: The battler who the AttackBox belongs to. -
score: The current score of the battler's AttackBox. -
bolts: A table of all of the bolts an AttackBox has. -
close: An integer representing how close the bolt furthest to the left is to the crit box, rounded down. For reference, a value of 0 means that it's in the crit zone.
-
enemy: The targeted enemy. -
action: The action of the battler.