Skip to content

The AddonHelper System

nullved edited this page Feb 24, 2026 · 1 revision

As of PMWeather 0.16.2, a new AddonHelper system was added, primarily for version compatibility purposes.

To register with the addon system, add this in your main class constructor (this example registers for 0.16.4 only):

// The versions use a #startsWith check, so "0.16" would match all 0.16.X versions
AddonHelper.registerAddon(new AddonInfo(modContainer, List.of("0.16.4")));

Now, if somebody runs a PMWeather version not in the list, the game will fail to start with a RuntimeException.

If any addons are registered, PMWeather will output this to the console:

PMWEATHER IS RUNNING WITH ADDONS, BEFORE REPORTING ISSUES TO THE PMWEATHER TEAM, PLEASE TRY WITHOUT ADDONS

Because of this message, it is highly recommended you register with the addon system, although it is opt-in and nothing will break if you don't.

Clone this wiki locally