Bump down the plugin API version

nothing major was *removed*, meaning all existing v2 plugins should still work
This commit is contained in:
KingRainbow44 2023-09-02 19:05:30 -04:00
parent ed0e89074b
commit 416ef56101
No known key found for this signature in database
GPG Key ID: FC2CB64B00D257BE

View File

@ -1,17 +1,18 @@
package emu.grasscutter.plugin; package emu.grasscutter.plugin;
import static emu.grasscutter.utils.lang.Language.translate;
import emu.grasscutter.Grasscutter; import emu.grasscutter.Grasscutter;
import emu.grasscutter.server.event.*; import emu.grasscutter.server.event.*;
import emu.grasscutter.utils.*; import emu.grasscutter.utils.*;
import lombok.*;
import javax.annotation.Nullable;
import java.io.*; import java.io.*;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import java.net.*; import java.net.*;
import java.util.*; import java.util.*;
import java.util.jar.*; import java.util.jar.*;
import javax.annotation.Nullable;
import lombok.*; import static emu.grasscutter.utils.lang.Language.translate;
/** Manages the server's plugins and the event system. */ /** Manages the server's plugins and the event system. */
public final class PluginManager { public final class PluginManager {
@ -20,7 +21,7 @@ public final class PluginManager {
* A 'breaking change' is something which changes the existing logic of the API. * A 'breaking change' is something which changes the existing logic of the API.
*/ */
@SuppressWarnings("FieldCanBeLocal") @SuppressWarnings("FieldCanBeLocal")
public static int API_VERSION = 3; public static int API_VERSION = 2;
/* All loaded plugins. */ /* All loaded plugins. */
private final Map<String, Plugin> plugins = new LinkedHashMap<>(); private final Map<String, Plugin> plugins = new LinkedHashMap<>();