Commit Graph
5357 Commits
Author SHA1 Message Date
piexel 6c4e4ef6f7 List a pack's modules grouped by host and pack, wrapped 2026-11-10 17:06:31 +01:00
piexel bedaac5155 Count host modules in the pack load summary instead of listing them 2026-11-10 16:53:11 +01:00
piexel 22b193e70a Offer the pack option when module completion has no pack to resolve 2026-11-10 16:53:11 +01:00
piexel a00e4bbdf0 Find the Iris generator behind other plugins' generator wrappers
CraftEngine wraps the active chunk generator during WorldInitEvent, after
Iris injected its own. Every identity check against the active generator
then failed: studio open threw while scoping structures, and native
structure creation, references and locating silently did nothing.
2026-11-10 16:53:11 +01:00
piexel 3c6dc52b8e Refresh pack listings before building workspace schemas
IrisData.get hands back a shared instance whose file listings outlive edits, so a
studio update or datapack ingest regenerated schemas that still offered removed keys
and missed new ones.
2026-11-10 16:32:55 +01:00
piexel aaa5e05cf0 Give the surface biome where a region lists no cave biomes
The cave biome stream answers such a region with a placeholder biome that has no pack key. It reached the cave depth lookup and the terrain sampler, which both key by the pack name, and every chunk failed with a NullPointerException.
2026-11-10 16:03:55 +01:00
piexel cb9103c4d9 Expose the platform's Gson to pack modules in the Bukkit jar
The Bukkit jar relocates Iris's own Gson, and the relocation rewrote the package name in the exposed list, so modules were shown Iris's copy and every reference to com.google.gson failed the pack load. The name is now assembled at run time.
2026-11-10 15:35:26 +01:00
piexel 2889274291 Merge feat/structure-jigsaw-modules into port/v3-features
Structure placement and jigsaw now live in the built-in modules jar, on top of the port's weighted picking, studio tooling
and procedural object work.

api/CONTRACTS.md keeps both sides' rows: the weighted entries and the studio bake and scene creation types from the port,
and VanillaStructureContext.world, Argument.reading, PlatformStructures, tool worlds and the services lookup from the
structure move.

PackModuleResourceKindTest installs the built-in modules jar into its castle pack, as the structure move requires, and
writes the dimension and region lists as weighted entries, as the port requires.

StructurePlacing takes the structure move's version. Its int sentinel for a sampled height is replaced by an explicit
sampledHeight flag that calls ObjectRun.automatic, and explicit pieces pass their world Y minus the world's minimum, so an
explicit world Y below zero stays a height (e3dd61c17).

StructureOutputPinTest.everyScenarioPlacesThePinnedStructures is re-baselined for the underground scenario's writes hash
only (9176f55f60410c117cdd9d5e to 1025f82c04539d4881a0e92b): pieces at world Y -1 are now placed there instead of on the
surface. The start count, the piece hash and every other scenario are unchanged.
2026-11-10 14:33:49 +01:00
piexel 6b2b0ec7f0 Carry the editor dimension default into the Spanish and French strings 2026-11-10 13:57:59 +01:00
piexel 1dea1b098d Move the pack weight converter's command line out of production code
Core production code may not write to the process streams; the entry point now lives in the test sources.
2026-11-10 13:57:59 +01:00
piexel 1e44f45a34 Merge branch 'v3/lane-engine' into v3/lane-studio 2026-11-10 13:51:55 +01:00
piexel bcbabc8f60 Look up and colour plugin blocks in saved worlds by the state they borrow
Plugins such as CraftEngine save their blocks as the vanilla state players see, so saved worlds showed a tripwire where a custom block stands. A saved block now maps back to its plugin name through the providers' looks, counts as ground by the shape of the block it borrows, and its models and textures come from the plugin's resource pack.

No terrain, pin, golden or digest moved; saved worlds are only read.

v3: 002aab06e
2026-11-10 13:51:37 +01:00
piexel 3c03bba7e7 Create and delete procedural objects from the studio's entry list
A view's entries can now be created from a starter tree in a chosen folder and deleted from the browser. Deleting lists the pack files that still name the entry, then moves it to the desktop trash, or the pack's .iris/trash where there is none. An EditableSceneView opts in with SceneCreation; the host does the writing.

v3: d6e6fc3ef
2026-11-10 13:42:30 +01:00
piexel 7eb45cebf6 Edit node values as curves, folded sections and suggestions in the studio
Nested settings fold into sections and lists of objects into items. Curve
values show a sparkline and open a points or shape editor, and a number or
range can be made a curve. Blocks, resources and roles are suggested while
typing, and string lists are typed as a, b. The studio asks the bridge for
the platform and pack lists (suggestions endpoint).

No terrain, pin, golden or digest moved; the files written are the same JSON.

v3: db53f834a
2026-11-10 13:34:32 +01:00
piexel dbfc1d0c34 Duplicate, fit and deselect nodes from the keyboard in the node editor
The node editor only took Delete; Ctrl+D, F (also Home) and Esc now duplicate, show every node and clear the choice, and Backspace deletes. The keys are rebindable studio shortcuts, shown beside Duplicate and Delete in the node menu, and take precedence over the map's F while the editor is shown.

v3: 1c8af6484
2026-11-10 13:08:05 +01:00
piexel e2ebc7fe8a Show reading progress for saved worlds and read a region's chunks in parallel
The saved-world view only said "Reading" with no sense of how far along it was, and the first look at a region read its 1024 chunks one after another. The status bar now shows a bar measured against the most tiles pending since the last idle, and the region's start read uses all cores.

v3: 3b899b8d1
2026-11-10 13:02:17 +01:00
piexel 80ecd143da Sample terrain height noise tiles on a world-fixed lattice
Asking the world's height at every pixel of a noise tile is too slow for the 3D view. Tiles of
the terrain height source now sample a power-of-two lattice fixed in the world and fill in between
along a Catmull-Rom curve, so tiles meet without a seam. Other noise sources are still sampled at
every pixel, and no pins moved.

v3: 1622f6dee 58382a46d bdea50e75
2026-11-10 12:54:37 +01:00
piexel 2366c87659 Add a terrain height source to the noise view
The noise view could not show the terrain the world generates. It now lists
"Terrain height", in blocks above the fluid with the world's seed, so the 2D
colours and the 3D water line match the world. The native map Height view is
kept as it is.

v3: adb9de089
2026-11-10 12:48:48 +01:00
piexel 8136fa857f Pick procedural parts by clicking blocks in the studio scene view
Authors could not tell which part of a procedural object placed a block. A click on a block in the Procedural view now finds its part and chooses the node that draws it; choosing a node lights up its blocks and draws everything else faintly. SceneView gains hasParts and parts (BlockParts), served as scene-parts, aligned with the scene's blocks. No pins moved: the trace bakes with its own builder and generation is untouched, ProceduralObjectsGoldenTest digests are unchanged.

v3: ff0190384
2026-11-10 12:44:27 +01:00
piexel a8aaa3c3cf Rebind the studio's keys from a settings dialog
The studio's keys were a fixed table, so the views, map toggles, zoom and node editor undo and redo could not be changed. The keys now come from a store the user rebinds in a settings dialog, saved to studio.json in the app's user data folder; tooltips, the view list, the hover card and the help dialog read the live keys, and a new key that another shortcut already uses is warned about.

v3: 8930afbb3
2026-11-10 12:32:42 +01:00
piexel eb2113b835 Preview pack expressions in the Noise view with the world's seed
The Noise view evaluated every pack expression with its seed field, so a preview did not line up with the terrain the expression shapes. Expressions reached from the region style and the land, sea, shore and cave biome styles now keep the random the world samples them with.

v3: c60f244ca
2026-11-10 12:24:45 +01:00
piexel d33d29be51 Open the editor on the open studio
The editor command now opens the open studio's pack when no dimension is given, else the default world type, and reports a missing pack instead of creating an empty one.

v3: 3d5042f0d
2026-11-10 12:19:22 +01:00
piexel 4950cf1969 Show far leaves in the studio scene view
The engine makes leaves with no wood in reach persistent, but the studio
gave no sign of which ones they are. The block list of a scene now counts
the leaves too far from wood and can draw only them. The rule is kept in
step with IrisProceduralBlocks.isLeafTooFarFromWood by a comment on both.

v3: eb3bae72d
2026-11-10 12:15:21 +01:00
piexel 7042538b89 Draw block textures on saved-world columns in the studio 3D view
The Blocks colouring of the saved-world view showed one flat average colour per block. Columns a block wide now show their top block's real textures: the top, the side of the top block, and the side of the blocks under it (dirt under grass), tinted as the client tints them. Coarser tiles keep the flat colours.
Textures go in one growing atlas; textured faces are one quad per block, and sides deeper than 16 blocks under a column's top stay a single flat quad.

v3: 950aca969
2026-11-10 12:12:19 +01:00
piexel df80f2a99d Sink studio 3D ground under water toward a deep colour by depth
The 3D terrain only laid one flat blue sheet over the sea floor, so depth and every water line were hard to read. Ground under water now sinks toward a deep colour the further down it lies, with a lighter sheet over it.

Studio only: no pack, seed or Java pin moved. Not run in the app.

v3: 23182951f
2026-11-10 12:04:13 +01:00
piexel 69b0303148 Show noise pick charts and a height legend beside the studio 3D world
The 3D world view had no side panel. Biomes and Regions colourings now show how the noise picks what the camera sees, measured over the box around the ground in view; Height shows how much of that ground lies in each height band, highest first.

v3: e5c4b0958 a223dd603
2026-11-10 12:00:58 +01:00
piexel 6d4d14606c Stream endless level-of-detail terrain into the studio 3D views
The world, noise and saved-world 3D views drew one fixed square. They now draw tiles of block columns around whatever the camera looks at, coarse backdrop first and then finer down to about a column per pixel, fetched through a byte-budgeted cache with cancellation. Coarser tiles stand in with holes where finer ones are ready, and ground drawn before a layer changes stays until its tiles are sampled anew. Pack, server and seed output are untouched; no pin or golden moved.

v3: 9ee539ee0 4bd06dbcc c3913e8f4 cc2caf8fa 0b9cb6156 23b98e5ff 2006e6ba8 de1e06f88
2026-11-10 11:55:34 +01:00
piexel 7b907cfdc9 Say weight in the map's pick inspection titles
Regions, biomes and children are picked by weight now, and the three inspection titles still said rarity.
2026-11-10 11:49:47 +01:00
piexel 08f4bffca9 Add a pack converter from rarity to weighted entries
A pack written with rarity needs its dimension regions, region biome lists, biome children and carving children rewritten to weighted entries. Lists that picked by 1 / rarity get the integer weights proportional to it (the least common multiple of the rarities over each, reduced by the greatest common divisor) and a list that would need a weight above 1000 stops the conversion; children keep their old rounded slots as half-slot weights with the parent listed among them. Files are edited as text so comments and formatting stay, and the conversion is all or nothing per pack. Next to the other pack tooling in core, run as PackWeightConverter [--dry-run] <pack folder>.

The converter's test checks the fixture packs are already what it would write.

v3: 96beb86e0
2026-11-10 11:46:25 +01:00
piexel 3d55236f97 Pick regions, biomes and children by weight
Rarity gave every list entry a share of 1 / rarity and children rounded slots; a weight on the list entry says what a pack author means. Dimension regions, region biome lists, biome children and carving children are now entries with a weight (1 to 1000), picked along the list in the order written, region and biome lists giving the edge to the earlier entry and children to the later. A biome keeps itself among its children only where it lists itself. PackBiome and PackRegion carry the weighted lists, and the carving module picks with the API's Weighted.pick. Rarity is gone from biomes and regions, and the three fixture packs are rewritten to the entry format.

No pin or golden moved: the changed generator seed only touches biomes of rarity other than 1, and no pinned world reads one. The fixture packs now have weights where their regions had rarities: pack-before-the-port forests 15, magnetics 1; pack-before-loot-and-spawn hot 10, terralost 6, mushroom 2, swamp 15, the rest 1.

v3: 0fbce6ba2 a598b4323 96beb86e0
2026-11-10 11:46:19 +01:00
piexel d705dee379 Add a weighted list pick to the API
Biome, region and child lists are about to count entries by weight. The pick walks such a list with a noise from 0 to 1 and takes an edge rule, so a module that picks from a pack's lists lands on the entry the host does.

v3: 96beb86e0
2026-11-10 11:46:07 +01:00
piexel 30c063853d Draw studio 3D terrain as one-block columns
The studio's 3D views drew a smooth mesh; they now draw block columns sampled one block per
pixel, 512 blocks a side, with neighbouring faces of one height and colour merged, sides only
where a column stands above its neighbour, and flat Minecraft-style face shading. Pack and
server are untouched.

v3: 1e8c47918 030ee0604 4eb7da0ce
2026-11-10 11:39:47 +01:00
piexel 6f772a2808 Orbit studio 3D views around the surface in the middle
Turning the camera now pivots on the ground or object at the centre of the view instead of a point in the air. Right-drag and middle-drag pan, and scrolling zooms toward the cursor. Terrain finds its pivot by marching the height grid, so a pick does not test every triangle.

v3: e53ca3b72
2026-11-10 11:34:22 +01:00
piexel 723764a782 Show server CPU and heap use in the studio status bar
The bridge sends a usage event every second and when a studio connects: CPU with 100 per busy thread, like top, and the Java heap in use. The status bar shows both beside the cursor and turns each warning-coloured at 80%.

v3: e1e158364 11e4ba0b1 268e72b9c 275b5965b
2026-11-10 11:31:27 +01:00
piexel d28b9d13cc Draw players as facing arrows on the map
The studio map showed players as plain dots. A blue arrow with a white edge and dark outline now points where the player looks, with the name in a pill above, readable on any terrain. Markers carry a yaw (rounded to 5 degrees so head turns do not flood the players event); entities keep their dot.

v3: 3914c4667
2026-11-10 11:26:49 +01:00
piexel 76dcab175b Time procedural bakes in the studio with a median-of-five meter
Authors could not see what a procedural object costs generation. The Procedural view now bakes the chosen entry five times in the background, keeps the median run, and rates it Light, Moderate or Heavy against a server tick, with each stage's time in the tooltip. SceneView gains isBaked and timeBake (one run, a BakeRun); the studio asks five times so a newer choice stops the rest. No pins moved: generation bakes with BakeProfile.NONE and nothing in packs changed.

v3: 9e30508e3 7d240ddf8
2026-11-10 11:22:51 +01:00
piexel f3bf0aea4b Zoom continents like regions and biomes
continentZoom rescaled the baked style noise instead of zooming its input, so fractures kept their unzoomed size. No pins moved: none use a fractured continent style with continentZoom other than 1.

v3: 98bc84fc5
2026-11-10 11:14:16 +01:00
piexel fc3ea69d74 Reload Zed schemas after they are regenerated
Zed's JSON server caches schema files until its configuration changes and never reports schema file edits. Schema files are now written through one writer that hands back the text, and a hash of those texts goes into the Zed settings as irisSchemaHash, so regenerated schemas reach the editor.

v3: f31d41a9f
2026-11-10 11:11:14 +01:00
piexel ffbd0db03a Let snippets hold several entries
A list that references a snippet file holding a JSON array now takes all of its entries in place, in both the pack Gson and the module settings decoder. A single-value reference to such a file logs an error and loads null in the pack Gson, and is a settings error in the module decoder. Snippet-file schemas accept one entry or a list, and the decorator-snippet validator checks each entry of an array file. No pins or goldens moved.

v3: 8ba8c7b2d
2026-11-10 11:04:18 +01:00
piexel 3eb8566ef9 Drive overlay noise from generators
overlayNoise now links generator files with a min and max, like biome generators, so overlays get composites, exponent, cliffs and cells. Heights come from link.getHeight with seed heightSeed + 571093, in the main and upper dimensions; exported packs now include overlay generators. Inline styles are no longer read, and the unused IrisShapedGeneratorStyle is removed.

No pin, golden or digest moved: no test pack uses overlayNoise, and worlds without it generate identically. Worlds with overlay noise change, since the noise now comes from a different seed.

v3: ef77fc5a8
2026-11-10 10:59:05 +01:00
piexel c2183bc470 Add a combined-value exponent curve to generators
Lets a pack curve the combined composite value of an IrisGenerator before opacity, so the final height can be shaped instead of each layer. Defaults to 1, which leaves existing generators and pinned values untouched.

v3: 1fe588837
2026-11-10 10:55:04 +01:00
piexel 843dcf702f Stop pack loading from looping on bad list entries
The snippet-type adapter fell back to defaults without consuming the broken value, so a list retried the same entry forever. Read the whole JSON value first, then convert it, and name the type, path and exception message in the error.

v3: 4b437207c
2026-11-10 10:52:22 +01:00
piexel 23bed57728 Let the server's placement rules reset on reload and stop post from removing foliage
The remembered "plant survives on ground" answers went stale when the server or CraftEngine reloaded resources, so they are now cleared on both events. The post-stage foliage removal second-guessed the server rule and deleted foliage that is not a decoration, so it is gone.

Pins: none moved; the only changed test is SurfaceSmoothingTest, which now expects the fern to stay.

v3: af333cc93
2026-11-10 10:49:00 +01:00
piexel 0b5aa54df7 Skip hotloads while a touched pack JSON does not parse
A bad save still hotloaded: the loaders return null for unparseable files, so the pack lost those biomes or regions. The new PackHotloadGuard keeps files that fail to parse until they parse, skips the hotload, logs it and sends a failed studio hotload message. Both the Bukkit generator and the modded studio hotload service gate on it, and the callback returns normally so the watcher does not retry.

v3: fe825040a
2026-11-10 10:43:34 +01:00
piexel 5efffcd0b2 Keep the .zed editor settings folder out of pack hotload watchers
ZedProjectSettings writes <pack>/.zed/settings.json, a .json file inside the watched pack, so hand edits reloaded the studio engine. Both watchers now share one PackHotloadFolder factory that ignores the folder. The chunk/hotload exclusion is already covered by the engine transition seal.

v3: 28968673a
2026-11-10 10:39:20 +01:00
piexel 7053224ba5 Keep 2D expression samples 2D
Expression noise always received three coordinates from CNG, so a 2D sample read z as 0 instead of the 2D form. CNG now passes the dimension count through noiseOf and noiseSignedOf, and ExpressionNoise evaluates 2D samples with the 2-argument expression. Other generators use the defaults and are unchanged, so no pin moved.

v3: a38d7e5d7
2026-11-10 10:31:32 +01:00
piexel 88ee0e89f7 Close Iris GUI windows on the Swing thread when the plugin shuts down
Windows otherwise outlive the plugin and keep drawing with threads its shutdown has stopped. GuiHost.closeWindows disposes every managed frame on the Swing thread and waits at most 5 s, in case that thread is itself waiting on the server. The Bukkit plugin runs it with its post-shutdown cleanup and the modded stop sequence runs it before clearing the GUI host.

v3: 6793e34d8
2026-11-10 10:28:12 +01:00
piexel 7e4c159039 Restore the Spigot and Paper timeouts Iris raised when auto-configuration is off
Iris rewrote spigot.yml timeout-time and paper-global.yml early-warning-delay without keeping the old values, so turning the setting off never undid it. The originals are now recorded in server-timeouts.json before the raise and restored on later starts unless the operator has changed the value since. Writes are atomic and go through symbolic links to the real file. The recovery bookkeeping reads server YAML through a small interface that ServerConfigurator implements, so the new class carries no Bukkit coupling.

Upstream: b357eee18
2026-11-10 10:10:58 +01:00
piexel 041e11f4a9 Gate mavenLocal behind -PuseMavenLocal and resolve ItemsAdder remotely
A stale ~/.m2 artifact could shadow the composite VolmLib or published artifacts, and ItemsAdder only resolved through mavenLocal. mavenLocal() is now added only with -PuseMavenLocal=true or when the composite VolmLib is off, and ItemsAdder uses beer.devs:itemsadder-api 4.0.17 from maven.devs.beer.

Upstream: c83d6964f
2026-11-10 10:08:31 +01:00
piexel 7b2a232a42 Give cave ceiling layers their own thickness noise
Ceiling layers borrowed the thickness noise of the surface layer at the same index, so ceiling layers beyond the surface layer count were dropped and the validator rejected such packs. Each ceiling layer now has its own cached noise, seeded as before, every declared layer is generated, and the validator accepts any count.

TerrainLayersPinTest re-baselined (length 143112 -> 147047, hash 149645537 -> 216639495). Only the MEADOW ceiling output changed, in both the plain and the exploded runs; surface, sea and smoothing output of every biome is identical, and the biomes without ceiling layers are untouched:
- MEADOW ceiling, plain: 5724 -> 7400 characters. Its fourth layer (basalt) is now emitted instead of cut off at the three surface layers.
- MEADOW ceiling, exploded: 13788 -> 16047 characters. Same fourth layer, plus the barrier separators around it.
- Layers 0 to 2 of MEADOW's ceiling now take thickness from their own style and zoom instead of the surface layers' (SIMPLEX zoom 0.3 against the default style for layer 0, the default style against CELLULAR zoom 0.25 for layer 1), so their block counts change at most columns, e.g. column -400,-400 went from "clay tuff deepslate calcite" to "clay clay tuff deepslate tuff calcite basalt".

Upstream: 23bad0e1a
2026-11-10 10:07:29 +01:00