Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First Pass On XML-Based Store Expansions #51

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

Dargino
Copy link

@Dargino Dargino commented Mar 26, 2024

This is a first draft for expanding the silver store with new actions via companion mods.
Action data (title, description, silver cost, etc) are provided via XML, accessible via Rimworld's DefDictionary.
The definition also has a pointer to a class (inheriting from the Action abstract).
This custom action class can be located in the assemblies of any mod loaded after RimConnect (or in RimConnect's own assemblies).
A new list for all custom actions is created, and the action definitions are loaded using the GetAction() function.
The custom actions list is appended to the built-in lists to be added to the silver store.

Everything else is handled by the existing code structure.

I have tested it to the point of working without producing console errors, but rigorous bug testing has not been done.

Also, please review this carefully.. I'm not great with github, so something might be misplaced..

@Dargino
Copy link
Author

Dargino commented Mar 26, 2024

Also, I suggest exposing the AlertManager class to public so that expansion actions can trigger the Twitch Event letters, too

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.

1 participant