Skip to content

Conversation

@Dubledice
Copy link

PR to Parent Branch

Commits summarized:

Addition of onExpire effect system, allowing for effects to be applied to the player when a prior effect ends.
Addition of Ui elements to support threshold effects, giving players a tracker to see when they hit their threshold breakpoint.
Cleaned up useless comments

General:

All new systems should be datapack-friendly.
Includes changes from my first and second PR request so + and - are inflated. <- New stuff starts here: onExpire + Ui Implementation

Contains (NEW) API + Event Hooks.

Contains Refactored/Factored Code.

Desc: Made for new "WHILE_LEECHING" system. Also houses new HasExileEffectCondition, e.g. allowing WHILE_(...) tags.
Added new More Damage While Leeching Magic Shield Offense Stat.

Added new Leech At Full Health Conditional Resource Stat,
Implemented brand new Resource Threshold fetcher, tracking ALL resources for conditional stats/effects.

Desc: Completely Datapack driven.
Suggested Fixes: Datapack Threshold
Suggested Fixes: SpendThresholdManager.java
Fixed effect consumption logic for certain effects like Overheat.
@SaloEater
Copy link

SaloEater commented Sep 4, 2025

I don't know what's the right decision, but if I were the owner, I would ask Dice to rewrite this PR.

Main change would be adding a new field List<ComponentPart> on_expire inside of ExileEffect class and execute these parts with already written code.
That way would be achieved several goals:

  1. Making PR lighter by reusing existing code and logic
  2. Making exile effects more flexible by using various SpellAction

This would bring us to generic exile effect:

{
  "id": "parent_effect",
  "max_stacks": 1,
  "mc_stats": [],
  "one_of_a_kind_id": "",
  "on_expire": [
    {
      "acts": [
          {
            "type": "exile_effect",
            "map": {
              "count": 1.0,
              "exile_potion_id": "child_effect",
              "potion_action": "GIVE_STACKS",
              "potion_dur": 20.0
            }
          }
        ],
        "en_preds": [
          //array of EffectCondition
        ],
        "ifs": [
          //array of EffectCondition
        ],
        "targets": [
          //array of BaseTargetSelector
        ]
    }
  ],
  "tags": {
  }
}

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