Skip to content

Commit

Permalink
feat: add k_eff to reactor NBT
Browse files Browse the repository at this point in the history
  • Loading branch information
bruberu committed Jul 9, 2024
1 parent 395c450 commit f310069
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -675,6 +675,7 @@ public NBTTagCompound writeToNBT(NBTTagCompound data) {
data.setInteger("flowRate", this.flowRate);
data.setDouble("controlRodInsertion", this.controlRodInsertionValue);
data.setBoolean("locked", this.lockingState == LockingState.LOCKED);
data.setDouble("kEff", this.kEff);
if (fissionReactor != null) {
data.setTag("transientData", this.fissionReactor.serializeNBT());
}
Expand All @@ -691,6 +692,7 @@ public void readFromNBT(NBTTagCompound data) {
this.flowRate = data.getInteger("flowRate");
this.controlRodInsertionValue = data.getDouble("controlRodInsertion");
this.height = this.heightTop + this.heightBottom + 1;
this.kEff = data.getDouble("kEff");
if (data.getBoolean("locked")) {
this.lockingState = LockingState.SHOULD_LOCK;
}
Expand Down

0 comments on commit f310069

Please sign in to comment.