Maruno17 / pokemon-essentials

A heavily modified RPG Maker XP game project that makes the game play like a Pokémon game. Not a full project in itself; this repo is to be added into an existing RMXP game project.
Other
208 stars 398 forks source link

Improvements to PluginManager #226

Closed dpertierra closed 4 weeks ago

dpertierra commented 1 month ago
DerxwnaKapsyla commented 1 month ago

In regards to that first suggestion, all you need to do is rename the meta.txt file to something like "_meta.txt", and that plugin effectively is disabled next time you do a full game recompliation. Considerably less work than adding a whole new tag to meta.txt imo.

dpertierra commented 1 month ago

In regards to that first suggestion, all you need to do is rename the meta.txt file to something like "_meta.txt", and that plugin effectively is disabled next time you do a full game recompliation. Considerably less work than adding a whole new tag to meta.txt imo.

I actually didn't about this, I don't think its a bad idea having both options, with the disabled tag you could also have a method that returns disabled plugins. But yes if want it disabled is probably easier just to rename the meta.txt to something else.

But anyways I think the most important fix of this PR is the issue of not always recompiling the plugins when you add or remove folders

Maruno17 commented 1 month ago

Essentials now has the Setting PROMPT_TO_COMPILE, which triggers upon running the game and lets you choose whether to compile at your leisure. If you think it's too difficult to hold a button while the game starts to force a compile, you can use that instead. It should be common practice to compile when you change something.

I see no need to add a "Disabled" meta property. You disable a plugin by not having it in the Plugins folder.

dpertierra commented 1 month ago

PROMPT_TO_COMPILE

By now you mean starting with essentials 22, right? I'm not able to find it in essentials 21.

I have tried holding the CTRL button and it does not always work for Plugins.

Maruno17 commented 4 weeks ago

Correct, it's not in a released version of Essentials yet.

Your idea of checking whether the number of plugins has changed was a start, but more could have been done. I've just pushed a commit that does this, as well as checking whether the name/version of any found plugin doesn't match a previously compiled plugin and vice versa. This will catch cases where you've replaced one plugin with another or updated a plugin.