AvalonBase
Modding for multiple loaders has always meant doubling your workload. You write a feature once for Forge, then rewrite it for Fabric, and somewhere along the way your GUI code drifts apart and your config handling stops matching. AvalonBase is a prerequisite support library that tackles this problem head-on. Created by Huziyang520, it gives mod developers a single common codebase that runs on both Forge and Fabric, so you spend your time on features instead of platform plumbing.
This library contains zero business-specific logic. Everything inside it is general-purpose, low-level utility work: themed GUI widgets, a configuration framework, cross-platform networking, and platform helpers. If you are building a mod that needs any of these, AvalonBase can serve as a required dependency and save you from reinventing the wheel.
Why Developers Reach for AvalonBase
The core pitch is simple: keep your mod lean. All the generic low-level logic lives inside the library, and your mod only contains feature-specific code. Because the API is unified across loaders, your business code stays loader-agnostic. There are no separate implementations for Forge and Fabric, no conditional branches scattered through your common source set, and no duplicated configuration logic.
There is also a user-experience benefit. Every mod that depends on AvalonBase shares uniform styling and interaction patterns for configuration screens, so players get a consistent look and feel across your entire mod lineup rather than a patchwork of mismatched menus.
Core Features at a Glance
Themed GUI System
The GUI system renders purely in code with no texture assets required. Two complete built-in styles ship with the library: a vanilla-style theme and an ender-purple modern theme. You get themed buttons, radio selectors, toggle switches, panels, cards, scrollbars, and icon rendering out of the box, plus hover easing animations and state-aware color palettes. Every widget respects the active theme, so a polished interface takes minimal boilerplate.
Base Configuration Screen
Building config GUIs from scratch is tedious. AvalonBase wraps the whole infrastructure: a one-line helper for Save and Cancel buttons, automatic permission checking with read-only mode support, scrollable item lists, cursor state switching, click sounds, and a status hint bar. Subclasses only need to implement the save logic to get a fully working configuration screen.
TOML Configuration Framework
Built on top of night-config, the config wrapper auto-generates default files when they are missing, supports read-write operations and sub-list handling, preserves comments, and detects external file changes for hot-reloading. Parsing and serialization behavior is standardized, so configs behave predictably across your projects.
Cross-Platform Networking
The networking layer unifies the Forge and Fabric APIs behind one interface. Message registration, encoding, decoding, and handler wiring all work the same way. You can send packets to the server, broadcast to all players, or target a single player, and thread scheduling is abstracted across platforms. Your common-side code never needs loader-specific branches.
Platform Service Utilities
A small helper API lets you query the current runtime loader, check whether another mod is loaded, and distinguish development environments from production. All loader-specific implementation stays encapsulated inside the library, invisible to consuming mods.
Supported Versions and Loaders
AvalonBase targets both Forge and Fabric, which is the entire point of its cross-platform design. Because it is a dependency library rather than a content mod, the exact supported Minecraft versions depend on the build you pick up, so check the file listing for the release that matches your mod's target version before you download AvalonBase. Mixing a library built for one Minecraft version with a mod built for another is the most common source of startup crashes.
How to Install AvalonBase
For players, installation is straightforward. If you are wondering how to install it, the process mirrors any other mod:
- Confirm your mod loader (Forge or Fabric) and the Minecraft version your modpack uses.
- Download the AvalonBase jar that matches that loader and version.
- Drop the jar into your mods folder alongside the mods that require it.
- Launch the game once and check the log to confirm the library loaded without errors.
For developers, the setup differs slightly. You can add a local jar dependency using compileOnly for the common source set and modImplementation for the platform-specific runtime jar, then declare AvalonBase as a mandatory required dependency in your mod metadata. Larger projects can publish artifacts to a private Maven repository and reference them by standard coordinates. One note: the TOML functionality depends on night-config. Forge ships it by default, but on Fabric you need to bundle it inside your mod jar.
If you manage a large modpack, keeping library versions in sync across dozens of mods gets messy fast. The foxygame.net launcher eases that burden by tracking version compatibility for AvalonBase and flagging mismatches before launch, so a stale library jar never silently breaks your pack.
Who Should Use It
AvalonBase fits a specific niche well. It is ideal for utility mods with visual configuration GUIs, permission or command management mods on the server side, mods that need client-to-server data synchronization, and any cross-platform project that demands identical behavior on both loaders. If your mod is a small content addition with no config screen or networking, the library adds little. But once you need a settings menu, packet handling, or platform detection, the time savings compound quickly.
Final Thoughts
AvalonBase is not flashy, and that is exactly its strength. It quietly removes the repetitive scaffolding that makes cross-loader modding exhausting, giving developers a shared foundation for GUI, configuration, networking, and platform utilities. Whether you are a player hunting down a missing dependency or a developer tired of maintaining two parallel codebases, this library is worth a serious look. Grab the build that matches your Minecraft version and loader, and let the boilerplate take care of itself.