diff --git a/libs/sr/formula/src/data/lightCone/sheets/ASecretVow.ts b/libs/sr/formula/src/data/lightCone/sheets/ASecretVow.ts index 8fbeb49527..1d44233307 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ASecretVow.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ASecretVow.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ASecretVow' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Adversarial.ts b/libs/sr/formula/src/data/lightCone/sheets/Adversarial.ts index f392bffd86..e4743bc5d6 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Adversarial.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Adversarial.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Adversarial' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/AfterTheCharmonyFall.ts b/libs/sr/formula/src/data/lightCone/sheets/AfterTheCharmonyFall.ts index a1331ef634..6cae3431f3 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/AfterTheCharmonyFall.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/AfterTheCharmonyFall.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'AfterTheCharmonyFall' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/AlongThePassingShore.ts b/libs/sr/formula/src/data/lightCone/sheets/AlongThePassingShore.ts index 901b0b2b5e..0e1ad601ce 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/AlongThePassingShore.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/AlongThePassingShore.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'AlongThePassingShore' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Amber.ts b/libs/sr/formula/src/data/lightCone/sheets/Amber.ts index 961f211b6a..516bc53a00 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Amber.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Amber.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Amber' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/AnInstantBeforeAGaze.ts b/libs/sr/formula/src/data/lightCone/sheets/AnInstantBeforeAGaze.ts index ae11b5b14c..4a5ac5215a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/AnInstantBeforeAGaze.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/AnInstantBeforeAGaze.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'AnInstantBeforeAGaze' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Arrows.ts b/libs/sr/formula/src/data/lightCone/sheets/Arrows.ts index 5f3015e5de..6e7fd14ae0 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Arrows.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Arrows.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Arrows' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/BaptismOfPureThought.ts b/libs/sr/formula/src/data/lightCone/sheets/BaptismOfPureThought.ts index 51f1735d59..229fc1ffe1 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/BaptismOfPureThought.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/BaptismOfPureThought.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'BaptismOfPureThought' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/BeforeDawn.ts b/libs/sr/formula/src/data/lightCone/sheets/BeforeDawn.ts index 7608d8aa46..db4ca6d2f3 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/BeforeDawn.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/BeforeDawn.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'BeforeDawn' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/BeforeTheTutorialMissionStarts.ts b/libs/sr/formula/src/data/lightCone/sheets/BeforeTheTutorialMissionStarts.ts index 71e0e08ea3..b509cc958b 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/BeforeTheTutorialMissionStarts.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/BeforeTheTutorialMissionStarts.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'BeforeTheTutorialMissionStarts' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/BoundlessChoreo.ts b/libs/sr/formula/src/data/lightCone/sheets/BoundlessChoreo.ts index 2faca25298..e1f7f2bfdc 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/BoundlessChoreo.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/BoundlessChoreo.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'BoundlessChoreo' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/BrighterThanTheSun.ts b/libs/sr/formula/src/data/lightCone/sheets/BrighterThanTheSun.ts index 819bf17fda..61bb1fac5a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/BrighterThanTheSun.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/BrighterThanTheSun.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'BrighterThanTheSun' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ButTheBattleIsntOver.ts b/libs/sr/formula/src/data/lightCone/sheets/ButTheBattleIsntOver.ts index af90eb9013..2e2f5c75ef 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ButTheBattleIsntOver.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ButTheBattleIsntOver.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ButTheBattleIsntOver' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/CarveTheMoonWeaveTheClouds.ts b/libs/sr/formula/src/data/lightCone/sheets/CarveTheMoonWeaveTheClouds.ts index 2a743d04cd..cb5e925c1d 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/CarveTheMoonWeaveTheClouds.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/CarveTheMoonWeaveTheClouds.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'CarveTheMoonWeaveTheClouds' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Chorus.ts b/libs/sr/formula/src/data/lightCone/sheets/Chorus.ts index a9a456ad7c..5e21a0af24 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Chorus.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Chorus.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Chorus' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/CollapsingSky.ts b/libs/sr/formula/src/data/lightCone/sheets/CollapsingSky.ts index e3a96c33be..2eac88c730 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/CollapsingSky.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/CollapsingSky.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'CollapsingSky' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ConcertForTwo.ts b/libs/sr/formula/src/data/lightCone/sheets/ConcertForTwo.ts index cf156885a5..425787d234 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ConcertForTwo.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ConcertForTwo.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ConcertForTwo' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Cornucopia.ts b/libs/sr/formula/src/data/lightCone/sheets/Cornucopia.ts index a5847959a2..b745e53c0f 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Cornucopia.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Cornucopia.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Cornucopia' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/CruisingInTheStellarSea.ts b/libs/sr/formula/src/data/lightCone/sheets/CruisingInTheStellarSea.ts index 3e64ec126a..a1a26f155e 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/CruisingInTheStellarSea.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/CruisingInTheStellarSea.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'CruisingInTheStellarSea' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DanceAtSunset.ts b/libs/sr/formula/src/data/lightCone/sheets/DanceAtSunset.ts index ade59321ce..39d655d77a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DanceAtSunset.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DanceAtSunset.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DanceAtSunset' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DanceDanceDance.ts b/libs/sr/formula/src/data/lightCone/sheets/DanceDanceDance.ts index c8426e61bc..fc451955af 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DanceDanceDance.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DanceDanceDance.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DanceDanceDance' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DartingArrow.ts b/libs/sr/formula/src/data/lightCone/sheets/DartingArrow.ts index 0a727a0297..fde2f1676e 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DartingArrow.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DartingArrow.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DartingArrow' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DataBank.ts b/libs/sr/formula/src/data/lightCone/sheets/DataBank.ts index 8a5c51380b..25188ca6e4 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DataBank.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DataBank.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DataBank' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DayOneOfMyNewLife.ts b/libs/sr/formula/src/data/lightCone/sheets/DayOneOfMyNewLife.ts index e71d0f4e89..ee73854f6f 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DayOneOfMyNewLife.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DayOneOfMyNewLife.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DayOneOfMyNewLife' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Defense.ts b/libs/sr/formula/src/data/lightCone/sheets/Defense.ts index 9ebb1b99a9..baa70e2692 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Defense.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Defense.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Defense' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DestinysThreadsForewoven.ts b/libs/sr/formula/src/data/lightCone/sheets/DestinysThreadsForewoven.ts index 9d4ea01833..128037c472 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DestinysThreadsForewoven.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DestinysThreadsForewoven.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DestinysThreadsForewoven' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/DreamvilleAdventure.ts b/libs/sr/formula/src/data/lightCone/sheets/DreamvilleAdventure.ts index 1139edc4d4..2d52810dad 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/DreamvilleAdventure.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/DreamvilleAdventure.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'DreamvilleAdventure' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/EarthlyEscapade.ts b/libs/sr/formula/src/data/lightCone/sheets/EarthlyEscapade.ts index f42afd17b0..fb153d06f6 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/EarthlyEscapade.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/EarthlyEscapade.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'EarthlyEscapade' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/EchoesOfTheCoffin.ts b/libs/sr/formula/src/data/lightCone/sheets/EchoesOfTheCoffin.ts index 87c58b2a3d..44e4fe1381 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/EchoesOfTheCoffin.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/EchoesOfTheCoffin.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'EchoesOfTheCoffin' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/EyesOfThePrey.ts b/libs/sr/formula/src/data/lightCone/sheets/EyesOfThePrey.ts index dcb2ae2ef0..d95b3ac4dd 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/EyesOfThePrey.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/EyesOfThePrey.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'EyesOfThePrey' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Fermata.ts b/libs/sr/formula/src/data/lightCone/sheets/Fermata.ts index 829e40b8dd..4c154a0d9d 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Fermata.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Fermata.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Fermata' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/FinalVictor.ts b/libs/sr/formula/src/data/lightCone/sheets/FinalVictor.ts index bc5d242a82..8e1ecdff61 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/FinalVictor.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/FinalVictor.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'FinalVictor' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/FineFruit.ts b/libs/sr/formula/src/data/lightCone/sheets/FineFruit.ts index b6f5625c77..d8dac90e1a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/FineFruit.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/FineFruit.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'FineFruit' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/FlamesAfar.ts b/libs/sr/formula/src/data/lightCone/sheets/FlamesAfar.ts index 482270ea9c..fa52b483de 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/FlamesAfar.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/FlamesAfar.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'FlamesAfar' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/FlowingNightglow.ts b/libs/sr/formula/src/data/lightCone/sheets/FlowingNightglow.ts index c2d62f3a13..a849f52ad2 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/FlowingNightglow.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/FlowingNightglow.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'FlowingNightglow' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/GeniusesRepose.ts b/libs/sr/formula/src/data/lightCone/sheets/GeniusesRepose.ts index 5c6110cdcf..1faab60ab3 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/GeniusesRepose.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/GeniusesRepose.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'GeniusesRepose' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/GoodNightAndSleepWell.ts b/libs/sr/formula/src/data/lightCone/sheets/GoodNightAndSleepWell.ts index aee04a3b98..6bd84c247d 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/GoodNightAndSleepWell.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/GoodNightAndSleepWell.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'GoodNightAndSleepWell' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/HeyOverHere.ts b/libs/sr/formula/src/data/lightCone/sheets/HeyOverHere.ts index 261520d9ba..5ecb0fba3c 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/HeyOverHere.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/HeyOverHere.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'HeyOverHere' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/HiddenShadow.ts b/libs/sr/formula/src/data/lightCone/sheets/HiddenShadow.ts index d81459947d..92b995ba84 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/HiddenShadow.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/HiddenShadow.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'HiddenShadow' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/IShallBeMyOwnSword.ts b/libs/sr/formula/src/data/lightCone/sheets/IShallBeMyOwnSword.ts index ab2c0d3372..238dee3636 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/IShallBeMyOwnSword.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/IShallBeMyOwnSword.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'IShallBeMyOwnSword' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/InTheNameOfTheWorld.ts b/libs/sr/formula/src/data/lightCone/sheets/InTheNameOfTheWorld.ts index 65845f6de8..9cbbfecedd 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/InTheNameOfTheWorld.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/InTheNameOfTheWorld.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'InTheNameOfTheWorld' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/InTheNight.ts b/libs/sr/formula/src/data/lightCone/sheets/InTheNight.ts index 1fc8726af0..4c90bfc4d7 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/InTheNight.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/InTheNight.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'InTheNight' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/IncessantRain.ts b/libs/sr/formula/src/data/lightCone/sheets/IncessantRain.ts index 72053630d7..736f24e222 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/IncessantRain.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/IncessantRain.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'IncessantRain' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/IndeliblePromise.ts b/libs/sr/formula/src/data/lightCone/sheets/IndeliblePromise.ts index 9f54861e04..a327674e9a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/IndeliblePromise.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/IndeliblePromise.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'IndeliblePromise' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/InherentlyUnjustDestiny.ts b/libs/sr/formula/src/data/lightCone/sheets/InherentlyUnjustDestiny.ts index f76afc82b7..1d9b02fdc7 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/InherentlyUnjustDestiny.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/InherentlyUnjustDestiny.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'InherentlyUnjustDestiny' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ItsShowtime.ts b/libs/sr/formula/src/data/lightCone/sheets/ItsShowtime.ts index 8db547f6b2..411f979b7c 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ItsShowtime.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ItsShowtime.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ItsShowtime' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/LandausChoice.ts b/libs/sr/formula/src/data/lightCone/sheets/LandausChoice.ts index aee7713795..fc9aa639dd 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/LandausChoice.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/LandausChoice.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'LandausChoice' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Loop.ts b/libs/sr/formula/src/data/lightCone/sheets/Loop.ts index 6d66d4c847..81273bec95 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Loop.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Loop.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Loop' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/MakeTheWorldClamor.ts b/libs/sr/formula/src/data/lightCone/sheets/MakeTheWorldClamor.ts index 028799ea01..5a9d78b0fa 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/MakeTheWorldClamor.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/MakeTheWorldClamor.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'MakeTheWorldClamor' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Mediation.ts b/libs/sr/formula/src/data/lightCone/sheets/Mediation.ts index 8cb6f78848..e34a08535f 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Mediation.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Mediation.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Mediation' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/MemoriesOfThePast.ts b/libs/sr/formula/src/data/lightCone/sheets/MemoriesOfThePast.ts index 221a410f5a..12d84f0e80 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/MemoriesOfThePast.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/MemoriesOfThePast.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'MemoriesOfThePast' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/MeshingCogs.ts b/libs/sr/formula/src/data/lightCone/sheets/MeshingCogs.ts index bb8857ee46..4ba6550b1f 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/MeshingCogs.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/MeshingCogs.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'MeshingCogs' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/MomentOfVictory.ts b/libs/sr/formula/src/data/lightCone/sheets/MomentOfVictory.ts index b9942f1daf..5130c71fba 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/MomentOfVictory.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/MomentOfVictory.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'MomentOfVictory' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Multiplication.ts b/libs/sr/formula/src/data/lightCone/sheets/Multiplication.ts index cf83edc828..3a7359c9c2 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Multiplication.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Multiplication.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Multiplication' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/MutualDemise.ts b/libs/sr/formula/src/data/lightCone/sheets/MutualDemise.ts index 3e4e272bc8..6b8abaa4c1 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/MutualDemise.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/MutualDemise.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'MutualDemise' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/NightOfFright.ts b/libs/sr/formula/src/data/lightCone/sheets/NightOfFright.ts index a64e0fc210..01eb16ba34 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/NightOfFright.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/NightOfFright.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'NightOfFright' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/NightOnTheMilkyWay.ts b/libs/sr/formula/src/data/lightCone/sheets/NightOnTheMilkyWay.ts index 9a7c67397c..96e811662f 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/NightOnTheMilkyWay.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/NightOnTheMilkyWay.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'NightOnTheMilkyWay' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/NowhereToRun.ts b/libs/sr/formula/src/data/lightCone/sheets/NowhereToRun.ts index b4d27bdcd6..0cbded6f9b 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/NowhereToRun.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/NowhereToRun.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'NowhereToRun' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/OnTheFallOfAnAeon.ts b/libs/sr/formula/src/data/lightCone/sheets/OnTheFallOfAnAeon.ts index defe1d00ec..56d5351282 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/OnTheFallOfAnAeon.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/OnTheFallOfAnAeon.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'OnTheFallOfAnAeon' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/OnlySilenceRemains.ts b/libs/sr/formula/src/data/lightCone/sheets/OnlySilenceRemains.ts index 03ea0144a7..54c4d7de9b 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/OnlySilenceRemains.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/OnlySilenceRemains.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'OnlySilenceRemains' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Passkey.ts b/libs/sr/formula/src/data/lightCone/sheets/Passkey.ts index ac9faf8dee..e6a28c1c97 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Passkey.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Passkey.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Passkey' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PastAndFuture.ts b/libs/sr/formula/src/data/lightCone/sheets/PastAndFuture.ts index 23e757b8db..b76b806b3a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PastAndFuture.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PastAndFuture.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PastAndFuture' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PastSelfInMirror.ts b/libs/sr/formula/src/data/lightCone/sheets/PastSelfInMirror.ts index 2eef340f2c..fd56336d95 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PastSelfInMirror.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PastSelfInMirror.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PastSelfInMirror' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PatienceIsAllYouNeed.ts b/libs/sr/formula/src/data/lightCone/sheets/PatienceIsAllYouNeed.ts index f7ff75b104..71c5bf5a42 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PatienceIsAllYouNeed.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PatienceIsAllYouNeed.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PatienceIsAllYouNeed' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PerfectTiming.ts b/libs/sr/formula/src/data/lightCone/sheets/PerfectTiming.ts index 200973c9b3..0c35f23ecb 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PerfectTiming.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PerfectTiming.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PerfectTiming' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Pioneering.ts b/libs/sr/formula/src/data/lightCone/sheets/Pioneering.ts index 81a36eaf49..1439394ab6 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Pioneering.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Pioneering.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Pioneering' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PlanetaryRendezvous.ts b/libs/sr/formula/src/data/lightCone/sheets/PlanetaryRendezvous.ts index f9644e2a69..d9b9d02ccf 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PlanetaryRendezvous.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PlanetaryRendezvous.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PlanetaryRendezvous' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PoisedToBloom.ts b/libs/sr/formula/src/data/lightCone/sheets/PoisedToBloom.ts index 590dee8d02..d73b5c5ab7 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PoisedToBloom.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PoisedToBloom.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PoisedToBloom' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/PostOpConversation.ts b/libs/sr/formula/src/data/lightCone/sheets/PostOpConversation.ts index db679e1e50..95dbd41842 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/PostOpConversation.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/PostOpConversation.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'PostOpConversation' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/QuidProQuo.ts b/libs/sr/formula/src/data/lightCone/sheets/QuidProQuo.ts index a235a24d2a..8867909983 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/QuidProQuo.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/QuidProQuo.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'QuidProQuo' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ReforgedRemembrance.ts b/libs/sr/formula/src/data/lightCone/sheets/ReforgedRemembrance.ts index e670cad6be..28211956fb 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ReforgedRemembrance.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ReforgedRemembrance.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ReforgedRemembrance' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ResolutionShinesAsPearlsOfSweat.ts b/libs/sr/formula/src/data/lightCone/sheets/ResolutionShinesAsPearlsOfSweat.ts index 25aeefe8f8..ece22982bc 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ResolutionShinesAsPearlsOfSweat.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ResolutionShinesAsPearlsOfSweat.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ResolutionShinesAsPearlsOfSweat' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ReturnToDarkness.ts b/libs/sr/formula/src/data/lightCone/sheets/ReturnToDarkness.ts index 1d04096975..18d2c65764 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ReturnToDarkness.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ReturnToDarkness.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ReturnToDarkness' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/RiverFlowsInSpring.ts b/libs/sr/formula/src/data/lightCone/sheets/RiverFlowsInSpring.ts index 5193dc665c..94899d2697 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/RiverFlowsInSpring.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/RiverFlowsInSpring.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'RiverFlowsInSpring' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Sagacity.ts b/libs/sr/formula/src/data/lightCone/sheets/Sagacity.ts index 0d97aa8445..8f9fcd6d2e 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Sagacity.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Sagacity.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Sagacity' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SailingTowardsASecondLife.ts b/libs/sr/formula/src/data/lightCone/sheets/SailingTowardsASecondLife.ts index 324cf592e4..c1defde4b4 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SailingTowardsASecondLife.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SailingTowardsASecondLife.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SailingTowardsASecondLife' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SharedFeeling.ts b/libs/sr/formula/src/data/lightCone/sheets/SharedFeeling.ts index 0ef2a7279e..ddb3a3f27e 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SharedFeeling.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SharedFeeling.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SharedFeeling' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ShatteredHome.ts b/libs/sr/formula/src/data/lightCone/sheets/ShatteredHome.ts index 22d4ff62a8..216db67deb 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ShatteredHome.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ShatteredHome.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ShatteredHome' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SheAlreadyShutHerEyes.ts b/libs/sr/formula/src/data/lightCone/sheets/SheAlreadyShutHerEyes.ts index f7ba3ce3b4..0f1cd5322e 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SheAlreadyShutHerEyes.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SheAlreadyShutHerEyes.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SheAlreadyShutHerEyes' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SleepLikeTheDead.ts b/libs/sr/formula/src/data/lightCone/sheets/SleepLikeTheDead.ts index 057d60c904..df9a4af6ee 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SleepLikeTheDead.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SleepLikeTheDead.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SleepLikeTheDead' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SolitaryHealing.ts b/libs/sr/formula/src/data/lightCone/sheets/SolitaryHealing.ts index 32c1baec36..f4a50d87e0 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SolitaryHealing.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SolitaryHealing.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SolitaryHealing' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SomethingIrreplaceable.ts b/libs/sr/formula/src/data/lightCone/sheets/SomethingIrreplaceable.ts index fde51403a8..af8c3c5052 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SomethingIrreplaceable.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SomethingIrreplaceable.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SomethingIrreplaceable' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/SubscribeForMore.ts b/libs/sr/formula/src/data/lightCone/sheets/SubscribeForMore.ts index 6c26de0766..40b866068a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/SubscribeForMore.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/SubscribeForMore.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'SubscribeForMore' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Swordplay.ts b/libs/sr/formula/src/data/lightCone/sheets/Swordplay.ts index 2f03e2572f..7193ede45e 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Swordplay.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Swordplay.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Swordplay' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TextureOfMemories.ts b/libs/sr/formula/src/data/lightCone/sheets/TextureOfMemories.ts index eace042cea..468c303d51 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TextureOfMemories.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TextureOfMemories.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TextureOfMemories' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TheBirthOfTheSelf.ts b/libs/sr/formula/src/data/lightCone/sheets/TheBirthOfTheSelf.ts index e977365588..3c1d691282 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TheBirthOfTheSelf.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TheBirthOfTheSelf.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TheBirthOfTheSelf' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TheDayTheCosmosFell.ts b/libs/sr/formula/src/data/lightCone/sheets/TheDayTheCosmosFell.ts index bd86077636..a87150d298 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TheDayTheCosmosFell.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TheDayTheCosmosFell.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TheDayTheCosmosFell' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TheMolesWelcomeYou.ts b/libs/sr/formula/src/data/lightCone/sheets/TheMolesWelcomeYou.ts index 47a0432058..0de0d9fbde 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TheMolesWelcomeYou.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TheMolesWelcomeYou.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TheMolesWelcomeYou' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TheSeriousnessOfBreakfast.ts b/libs/sr/formula/src/data/lightCone/sheets/TheSeriousnessOfBreakfast.ts index 646e7b3c66..91a6798a05 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TheSeriousnessOfBreakfast.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TheSeriousnessOfBreakfast.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TheSeriousnessOfBreakfast' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TheUnreachableSide.ts b/libs/sr/formula/src/data/lightCone/sheets/TheUnreachableSide.ts index c32447502c..0d5672a32b 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TheUnreachableSide.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TheUnreachableSide.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TheUnreachableSide' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/ThisIsMe.ts b/libs/sr/formula/src/data/lightCone/sheets/ThisIsMe.ts index eba50b7d07..4f247d88a1 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/ThisIsMe.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/ThisIsMe.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'ThisIsMe' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TimeWaitsForNoOne.ts b/libs/sr/formula/src/data/lightCone/sheets/TimeWaitsForNoOne.ts index fcdba820a3..c54606f56a 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TimeWaitsForNoOne.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TimeWaitsForNoOne.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TimeWaitsForNoOne' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TodayIsAnotherPeacefulDay.ts b/libs/sr/formula/src/data/lightCone/sheets/TodayIsAnotherPeacefulDay.ts index 1eb5ba4120..be570472d2 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TodayIsAnotherPeacefulDay.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TodayIsAnotherPeacefulDay.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TodayIsAnotherPeacefulDay' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/TrendOfTheUniversalMarket.ts b/libs/sr/formula/src/data/lightCone/sheets/TrendOfTheUniversalMarket.ts index 7fa9141855..f02c178576 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/TrendOfTheUniversalMarket.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/TrendOfTheUniversalMarket.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'TrendOfTheUniversalMarket' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/UnderTheBlueSky.ts b/libs/sr/formula/src/data/lightCone/sheets/UnderTheBlueSky.ts index 45ca26af63..33b3e98b2d 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/UnderTheBlueSky.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/UnderTheBlueSky.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'UnderTheBlueSky' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/Void.ts b/libs/sr/formula/src/data/lightCone/sheets/Void.ts index 80e15c7763..ccf760d354 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/Void.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/Void.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'Void' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WarmthShortensColdNights.ts b/libs/sr/formula/src/data/lightCone/sheets/WarmthShortensColdNights.ts index d3b09bed55..500b98419f 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WarmthShortensColdNights.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WarmthShortensColdNights.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WarmthShortensColdNights' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WeAreWildfire.ts b/libs/sr/formula/src/data/lightCone/sheets/WeAreWildfire.ts index bc99dbc136..f96d055cf3 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WeAreWildfire.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WeAreWildfire.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WeAreWildfire' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WeWillMeetAgain.ts b/libs/sr/formula/src/data/lightCone/sheets/WeWillMeetAgain.ts index 46149f2fbb..1226d7bc11 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WeWillMeetAgain.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WeWillMeetAgain.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WeWillMeetAgain' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WhatIsReal.ts b/libs/sr/formula/src/data/lightCone/sheets/WhatIsReal.ts index 5232a8ac24..4b63e861f8 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WhatIsReal.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WhatIsReal.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WhatIsReal' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WhereaboutsShouldDreamsRest.ts b/libs/sr/formula/src/data/lightCone/sheets/WhereaboutsShouldDreamsRest.ts index b5a6d420be..697f493066 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WhereaboutsShouldDreamsRest.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WhereaboutsShouldDreamsRest.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WhereaboutsShouldDreamsRest' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WoofWalkTime.ts b/libs/sr/formula/src/data/lightCone/sheets/WoofWalkTime.ts index 16b533a7d8..69dcd44270 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WoofWalkTime.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WoofWalkTime.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WoofWalkTime' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/WorrisomeBlissful.ts b/libs/sr/formula/src/data/lightCone/sheets/WorrisomeBlissful.ts index 219be5226e..c94ec235f4 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/WorrisomeBlissful.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/WorrisomeBlissful.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'WorrisomeBlissful' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet diff --git a/libs/sr/formula/src/data/lightCone/sheets/YetHopeIsPriceless.ts b/libs/sr/formula/src/data/lightCone/sheets/YetHopeIsPriceless.ts index 2e10eef9e9..7acb3efb51 100644 --- a/libs/sr/formula/src/data/lightCone/sheets/YetHopeIsPriceless.ts +++ b/libs/sr/formula/src/data/lightCone/sheets/YetHopeIsPriceless.ts @@ -1,4 +1,4 @@ -import { subscript } from '@genshin-optimizer/pando/engine' +import { cmpGE, subscript } from '@genshin-optimizer/pando/engine' import type { LightConeKey } from '@genshin-optimizer/sr/consts' import { allStats, mappedStats } from '@genshin-optimizer/sr/stats' import { @@ -17,7 +17,7 @@ import { entriesForLightCone } from '../util' const key: LightConeKey = 'YetHopeIsPriceless' const data_gen = allStats.lightCone[key] const dm = mappedStats.lightCone[key] - +const lcCount = own.common.count.sheet(key) const { superimpose } = own.lightCone // TODO: Add conditionals @@ -28,20 +28,27 @@ const { numConditional } = allNumConditionals(key, true, 0, 2) const sheet = register( key, // Handles base stats and passive buffs - entriesForLightCone(data_gen), + entriesForLightCone(key, data_gen), // TODO: Add formulas/buffs // Conditional buffs registerBuff( 'cond_dmg_', ownBuff.premod.dmg_.add( - boolConditional.ifOn(subscript(superimpose, dm.cond_dmg_)) + boolConditional.ifOn( + cmpGE(lcCount, 1, subscript(superimpose, dm.cond_dmg_)) + ) ) ), registerBuff( 'team_dmg_', - teamBuff.premod.dmg_.add(listConditional.map({ val1: 1, val2: 2 })) + teamBuff.premod.dmg_.add( + cmpGE(lcCount, 1, listConditional.map({ val1: 1, val2: 2 })) + ) ), - registerBuff('enemy_defIgn_', enemyDebuff.common.defIgn_.add(numConditional)) + registerBuff( + 'enemy_defIgn_', + enemyDebuff.common.defIgn_.add(cmpGE(lcCount, 1, numConditional)) + ) ) export default sheet