shared code for my plugins. plain Java 21 lib, no Bukkit/Velocity/Hikari/MySQL in here so paper and velocity plugins can both use it. MikeyStaff is the only thing using it right now.
whats in it (mikey.me.core):
communication.protocol.PluginProtocolsigns and checks plugin messages (wrap/unwrap, HMAC-SHA256 with a shared secret, 30s window, replayed nonces get dropped)communication.LocalCommunicationin process message bus for paper only mode, behindCommunicationApi.CommunicationModeisPROXYorPAPERjson.JsonUtiltiny json helpers (escape,extractString,extractLong, etc)persistence.DatabaseConfigdb settings record,toStringhides the passwordpersistence.ActivePunishmentPolicychecks if a ban/mute is still active from its start time and duration
its not published anywhere, plugins pull it in as a Gradle composite build. put this repo next to the plugin repo and add to the plugins settings.gradle.kts:
includeBuild("../MikeyCore") {
name = "mikey-core"
}then depend on it and shade it into the plugin jar:
implementation("mikey.core:mikey-core:0.1.0-SNAPSHOT")gradle swaps in the local build for that coordinate so changes here show up without publishing.
needs JDK 21.
./gradlew build./gradlew test for just the tests.