Skip to content

1.2.2 - #71

Merged
WillTDA merged 6 commits into
masterfrom
1.2.2
Sep 28, 2026
Merged

WillTDA merged 6 commits into
masterfrom
1.2.2

Conversation

@WillTDA

@WillTDA WillTDA commented Sep 28, 2026

Copy link
Copy Markdown
Collaborator

A patch release on top of 1.2.1: World Type and the other settings Minecraft only reads on a server's first start, Normal as the default difficulty, and a modpack hardening fix. Versioned 1.2.2 in the last commit, so merging leaves master ready to tag.

New

  • World Type — the create page and Settings gain World Type, and their world options now sit under a separator, two to a row: Game Mode and Difficulty, then World Type and World Seed. Minecraft 1.19 renamed the world types and reads none of the old names it doesn't happen to share (checked on real servers: largeBiomes or default on 26.3, and minecraft:flat on 1.18.2, all generate a normal world), so each version gets its own list. A value is stored in the spelling the server's version reads, and a version change in Settings translates it. A value Craftbox doesn't know, like a modpack's own world type, is kept rather than saved over, and creating from a modpack offers "Modpack default" so the pack's stays unless another is picked. The API takes levelType on create, both modpack creates and edit; the server record mirrors it and templates carry it. Checked end to end: a flat world picked in Craftbox really generates flat on 26.3 and 1.18.2.
  • First-start settings — level-type, hardcore, generator-settings and (1.19.3+) initial-enabled-packs/initial-disabled-packs are only read when a world is generated, and Minecraft only writes them on the first start (1.17 never writes most of them), so they couldn't be set before the one start that uses them. New servers now get them up front with the defaults each version writes itself, taken from real 1.12.2 through 26.3 servers, and the Properties page lists them.

Changed

  • Normal difficulty by default — preselected on the create page and used by the API when a create request leaves it out, in place of Easy. Existing servers are unchanged.

Fixed

  • A modpack could put JVM flags on the server's command line. Forge and NeoForge start as java … @libraries/…/unix_args.txt, a JVM argument file, and a pack's files and overrides land after the loader installs, so a pack could overwrite it (or add a higher-numbered folder, which Craftbox picked) with -javaagent or -XX:OnOutOfMemoryError=<command>. Any pack file that would land under libraries/, as a top-level .jar or *_args.txt, or as user_jvm_args.txt, run.sh, run.bat or fabric-server-launcher.properties is now skipped and named in the install warnings, and Forge/NeoForge launch the args file of the build Craftbox installed first. A pack's recommended memory was checked as well: the .mrpack format has no memory setting, so the 4 GB suggestion for modpacks stays.
  • The Properties page matches enum values case-insensitively, so 1.12's level-type=DEFAULT shows as Normal.

CI

  • The API smoke test now covers the new defaults and first-start settings, World Type on create and edit, the Settings, Properties and create pages' HTML (the first page checks, over the setup wizard's session), and a real .mrpack install that plants launch files. It builds the pack itself with a small zip writer, so still no test dependencies.
  • Run locally against this branch's Docker image: 31/31 API checks, and all seven server types started at their newest versions.

Screenshots

The README's Create and Settings images were retaken in Chrome on Windows from the 1.2.2 image, with the same server, selections and framing as before and the new options at their defaults.

Notes

  • NeoForge's Maven served a truncated version list for a while today (its metadata was rewritten at 14:47 UTC on 2026-09-28), which left the NeoForge version list empty in every Craftbox version. It had recovered by the time this was pushed; if the NeoForge start job fails on this PR, that's the first thing to rule out.
  • Not in scope, noticed along the way: Minecraft 1.12 and older read difficulty and gamemode as numbers, while Craftbox has always written names, so those versions fall back to Easy/Survival.

Minecraft reads level-type, hardcore, generator-settings and (from 1.19.3)
initial-enabled-packs/initial-disabled-packs only when it generates a
world, and a server only writes them to server.properties on its first
start; 1.17 never writes most of them at all. So none of them could be set
through Craftbox before the one start that uses them. New servers now get
them up front, with the defaults each version writes itself, taken from
real 1.12.2, 1.16.5, 1.17.1, 1.18.2, 1.19.2, 1.19.3 and 26.3 servers.

The create page and Settings gain World Type, and their world options sit
under a separator, two to a row: Game Mode and Difficulty, then World Type
and World Seed. Minecraft 1.19 renamed the world types and reads none of
the old names it doesn't happen to share: on 26.3 `largeBiomes` or
`default` generates a normal world, and on 1.18.2 `minecraft:flat` does
the same. So each version gets its own list, a value is stored in the
spelling the server's version reads, and a version change in Settings
translates it. A value Craftbox doesn't know, such as a modpack's own world
type, is kept rather than saved over, and creating from a modpack offers
"Modpack default" so the pack's stays unless another is picked.

The API takes `levelType` on create, both modpack creates and edit, the
server record mirrors it from server.properties, and templates carry it.
The Properties page lists the new settings and matches enum values
case-insensitively, since 1.12 writes `DEFAULT`.
Normal is now preselected on the create page, and is what the API uses
when a create request leaves difficulty out, in place of Easy. It is also
the default for a new server.properties and for templates saved from a
server with none recorded. Existing servers keep whatever they have.
Forge and NeoForge start as `java ... @libraries/.../unix_args.txt`, and
that file is a JVM argument file. A modpack's files and overrides land
after the loader installs, so a pack could overwrite it, or add a
higher-numbered folder beside it, which Craftbox picked, and put its own
flags on the command line: -javaagent, or -XX:OnOutOfMemoryError running a
shell command. A pack's mods already run inside the server, but how the JVM
starts should not be the pack's to decide.

Any pack file, from the manifest or the overrides, that would land under
libraries/, as a .jar or *_args.txt at the top of the server directory, or
as user_jvm_args.txt, run.sh, run.bat or fabric-server-launcher.properties
is now skipped, and the install's warnings and the log name what was left
out. Paths are checked in canonical form, so `./server.jar` or
`Libraries/` don't slip past. Forge and NeoForge also launch the args file
of the build Craftbox installed ahead of any other folder, falling back to
the newest only when that build has none.

A pack's recommended memory was checked too: the .mrpack format carries no
memory setting, so the create page's 4 GB suggestion for modpacks stays.
…nstall

The API smoke test now covers:
- the Normal difficulty default and the first-start settings a new server
  gets, and the record's levelType;
- World Type stored in the spelling the version reads, and unknown types
  refused on create and edit;
- the Settings, Properties and create pages rendering the new fields, the
  first checks of any page's HTML, over the session the setup wizard opens;
- a real .mrpack install (a Fabric pack built in the test) that plants
  launch files, which must all be skipped, while the pack's own
  server.properties values are kept and online-mode stays on.

lib.mjs gains bootstrapPanel(), which also returns a logged-in page
fetcher, and makeZip(), a stored-only zip writer so the test needs no zip
dependency.
Both pages changed layout, so the README images were retaken: in Chrome on
Windows, from the 1.2.2 Docker image, with the same Forge SMP server
(Forge 1.20.1, port 25565, 2048 MB, running for Settings), the same
selections and the same framing as before. The new World Type and the
Normal difficulty default show at their defaults.
@WillTDA
WillTDA merged commit ebd665b into master Sep 28, 2026
9 checks passed
@WillTDA
WillTDA deleted the 1.2.2 branch September 28, 2026 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant