Skip to content

Replace Overwrite mixin with smaller injectors#10

Open
ChiefArug wants to merge 6 commits intoMinenash:masterfrom
ChiefArug:mixin-fixin
Open

Replace Overwrite mixin with smaller injectors#10
ChiefArug wants to merge 6 commits intoMinenash:masterfrom
ChiefArug:mixin-fixin

Conversation

@ChiefArug
Copy link

Also replaces the redirect with two ModifyExpressionValues.

This was done by formatting the overwrite to be very similar to the decompiled vanilla code then opening that in a diff with the vanilla code and replacing each difference with a new injector.

This has led to some... interesting behaviours being discovered, namely actionHunger$removeCondition and actionHunger$dontSetPrevFoodLevel. These have been made as new injectors but you should consider fixing these if it does get merged.
Additionally some other behaviour could be improved if you want to have a go at that (ie replace all the unconditional replacements with multipliers), and you could probably reduce the number of injectors a bit if you don't care about preserving some behaviour.

The diff of the original overwrite method and a debug export of these new mixins applied can be seen here: https://gist.github.com/ChiefArug/cfa125c75c59b8ccb4a10e72fd62b0c4
Note that this is with a lot of inlining of the mixins and reformatting of the overwrite, if you wish to replicate the diff.

Fixes #7

If you have any questions about any of these changes ask and I will be very happy to answer them.

@ChiefArug
Copy link
Author

Before merging please have a read of the comments on the new injectors, as some of them are questionable old behaviour (which I left it in to preserve the entire behaviour of the old overwrite).

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.

incompatibility with Pufferfish's Attributes

1 participant