Skip to content

Fix mod parsing for "enemies you <verb> have ..."#2378

Open
moxaj wants to merge 1 commit into
PathOfBuildingCommunity:devfrom
moxaj:enemies-you-x
Open

Fix mod parsing for "enemies you <verb> have ..."#2378
moxaj wants to merge 1 commit into
PathOfBuildingCommunity:devfrom
moxaj:enemies-you-x

Conversation

@moxaj

@moxaj moxaj commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Description of the problem being solved:

Some mods like Enemies you Curse have -6% to Chaos Resistance were parsed but did not function.

This PR:

  • fixes the generic enemies you .. have ..
  • fixes enemies you .. cannot recharge energy shield
  • removes the redundant enemies you electrocute have .. and enemies you mark have #% reduced accuracy rating

Steps taken to verify a working solution:

  • Add Essence Drain
  • Add Temporal Chains
  • Add the custom configuration Enemies you Curse have -6% to Chaos Resistance
  • Verify that your damage increases

Comment thread src/Modules/ModParser.lua

-- Convert condition verb forms to their proper condition variable names
local function getConditionVar(verb)
local conditionMap = {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this conditionMap could go next to statusToEffectMap or otherwise be combined in a clever way, as they are essentially just converting the same terms in opposite directions.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can see the connection, but I'm not sure how they could be combined. There's not much of an overlap between the two.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, not sure "combining" is actually feasible, but it would be nice to only maintain one if someone actually figured out a way.

My main point was that imo they should be located in similar places in the code though since they serve similar functions. It's just that mod wording is not 100% consistent for e.g. "Enemies you ..." and "Enemies ... by you" and similar mods. Some use the verb, some the participle, which is why we apparently need to map both ways.

No idea which place is actually better in the code, but having those maps close to each other does seem to make sense 🤷

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants