Add shared village storage and ambient sightings - #54
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add persistent shared knowledge for village chest/barrel contents and the rare runtime-generated horizon sighting system.
Villagers now remember observed village storage globally through server SavedData, consult it before budgeted local scans, refresh it when relevant containers change, and always revalidate the physical container before using it. The same knowledge path serves communal food, Farmer deposits, livestock feed, and golem emeralds.
The atmosphere subsystem schedules rare player-specific sightings near the render-distance fog in every dimension. The client renders a non-interactive player-like figure using an approved skin reconstructed at runtime, with ordinary model lighting and shadow; it vanishes after sustained observation or a render-distance-scaled approach.
Player or developer impact
Validation
./gradlew build./gradlew runGameTestServer, when relevantPassed locally:
./gradlew test --tests 'cz.xefensor.retold.ambient.RetoldHorizonScheduleTest'./gradlew runGameTestServer --args="net.neoforged.fml.startup.GameTestServer --tests retold:villagers_share_persistent_knowledge_of_village_storage"./gradlew runGameTestServer --args="net.neoforged.fml.startup.GameTestServer --tests retold:villager_paths_to_communal_food_storage"./gradlew runGameTestServer --args="net.neoforged.fml.startup.GameTestServer --tests retold:farmer_communal_supply_paths_to_storage"./gradlew runGameTestServer --args="net.neoforged.fml.startup.GameTestServer --tests retold:village_animal_reputation_consumes_two_storage_items"./gradlew runGameTestServer --args="net.neoforged.fml.startup.GameTestServer --tests retold:golem_construction_stages_and_conserves_village_emerald"The Farmer route test failed once at a randomized distant GameTest coordinate because navigation did not begin, then passed unchanged on the immediate rerun at a different randomized coordinate. This is recorded as a coordinate-sensitive pathfinding flake rather than a deterministic failure.
The runtime figure's appearance, fog placement, lighting, shadow, and dismissal behavior still require the developer's ongoing visual playtesting. Dedicated-server, multiplayer, and long-session behavior were not manually tested in this pass.
AI assistance
Codex materially assisted with implementation, tests, documentation, validation, and PR preparation. The result was reviewed against the subsystem documentation, compiled with the full build, and exercised with the focused JUnit and GameTests listed above.
Documentation and release notes
CHANGELOG.mdfor player-facing or notable technical changesVisual evidence
No screenshot is attached. The developer supplied and approved the visual source and will verify the runtime reconstruction and in-world presentation during normal play.
Licensing
LICENSE-CODE.md.ASSET_CREDITS.mdrecords the developer-supplied and approved visual source used by the runtime-generated skin.