Added Ki Cost to Ability

This commit is contained in:
Vidal committed 2026-02-15 00:40:43 -03:00
1 parent 0f774a68fc
commit 61405add97
1 file changed
+17
@@ -110,6 +110,9 @@ public abstract class Ability implements IAbility {
protected boolean burstReplayAnimations = true;
protected boolean burstOverlap = false; // if true, don't wait for entity death between bursts
// Ki
protected int kiCost = 0;
// ═══════════════════════════════════════════════════════════════════
// EXECUTION STATE (not saved, reset each combat)
// ═══════════════════════════════════════════════════════════════════
@@ -1149,6 +1152,9 @@ public abstract class Ability implements IAbility {
nbt.setBoolean("burstReplayAnimations", burstReplayAnimations);
nbt.setBoolean("burstOverlap", burstOverlap);
// Ki
nbt.setInteger("kiCost", kiCost);
// Conditions
NBTTagList condList = new NBTTagList();
for (Condition c : conditions) condList.appendTag(c.writeNBT());
@@ -1212,6 +1218,9 @@ public abstract class Ability implements IAbility {
burstReplayAnimations = nbt.getBoolean("burstReplayAnimations");
burstOverlap = nbt.getBoolean("burstOverlap");
// Ki
kiCost = nbt.getInteger("kiCost");
// Conditions
conditions.clear();
NBTTagList condList = nbt.getTagList("conditions", 10);
@@ -1751,6 +1760,14 @@ public abstract class Ability implements IAbility {
return burstIndex;
}
public int getKiCost() {
return kiCost;
}
public void setKiCost(int kiCost) {
this.kiCost = kiCost;
}
/**
* Get display keys for rotation phase dropdown (excludes "None" since mode=FREE handles that).
*/