ItsVerday / LuckyAPI

A modloader for Luck be a Landlord
https://discord.gg/7ZncdvbXp7
MIT License
12 stars 7 forks source link

Add sub-effects system to allow for greater control of effects #15

Closed ItsVerday closed 3 years ago

ItsVerday commented 3 years ago

Is your feature request related to a problem? Please describe. Effects have no way to trigger other effects. In other words, effects check their conditions independently of each other, so two effects that have the same random condition will not always execute together.

Describe the solution you'd like Effects can contain sub-effects which are only executed if the parent effect's conditions pass. Sub effects don't need conditions, they instead inherit the conditions of the parent effect.

Additional context This would probably be implemented via a .sub() method on the effect builder class. The method will take one argument, a sub effect to be added to this effect.

ItsVerday commented 3 years ago

Implemented in most recent update.