Scripted Damage Combos
Overview
Creator:
Moosh
Added: 22 Aug 2019
Tags:
FFC
Downloads: 25
|
View Script
Download Example (918.98 KB) |
Information
This is a substitute for ZC's somewhat less than desirable damage combo hit detection.
Description Setup Reviews Comments
First off, set the constants if needed:
Place down an FFC with the following D0-D7 arguments:
This script uses std.zh and ghost.zh.
- SCRIPTEDDAMAGECOMBO_ONLYFACING: If 1, Link will only get hurt when walking into spikes in the direction he's facing at a diagonal. Otherwise they can hit him from the sides too.
- SCRIPTEDDAMAGECOMBO_DAMAGEONHEADBONK: If 1, Link is hurt by the bottom part of spikes when jumping into them in sideview. Otherwise they're harmless from the bottom.
- DELAY_SCRIPTEDDAMAGECOMBO: Delay in frames (60ths of a second) before Link takes damage walking into a solid damage combo.
- DELAY_SCRIPTEDDAMAGECOMBO_SIDEVIEW: Same as above, but only in sideview.
Place down an FFC with the following D0-D7 arguments:
- D0: The flag marking which combos the FFC is controlling. If 0, the FFC itself is treated as a scripted damage combo.
- D1: How much base damage the combo does. 4 = 1 heart without tunics.
- D2: If 1, the damage pierces rings (see details on ring function below).
- D3: If >0, the script uses a different damage delay from the default when Link pushes against it.
- D4: If 1, the combos being flagged aren't solid and use different collision logic.
- D5: If 1, the script won't deal knockback
int ScriptedDamageCombo_GetTunicMultipliers(){
//Return the divisor of the highest level ring
if(Link->Item[I_RING3])
return 8;
else if(Link->Item[I_RING2])
return 4;
else if(Link->Item[I_RING1])
return 2;
//Otherwise no ring and damage is normal
return 1;
}
The gist of it is it's checking each of Link's rings in order from highest to lowest and if he has one and then returns its damage multiplier so the script can undo it. The words in [] are the item IDs for the items (you can just use numbers instead when editing it). The values after return are the damage divisors of the rings. It's a pretty simple function to edit if need be.This script uses std.zh and ghost.zh.



