Repository navigation
Read the Georama's tables from documents a datapack can change - #253
Open
SirFancyBacon wants to merge 1 commit into
Open
SirFancyBacon wants to merge 1 commit into
SirFancyBacon wants to merge 1 commit into
Conversation
gameplay/georama/parts.json (kind georama_parts) holds each town's parts and elements, EditPartsData and EditElementData, and gameplay/georama/atla.json (kind georama_atla) the Atla each dungeon hands out, AtraAppearData, each one a part or an element on a fixed floor or on either half of the dungeon. They are read at start-up into the tables the game reads, so nothing that reads them changes; a town or dungeon a document leaves out keeps its compiled table, and --export-gameplay writes both as compiled. A document the game could not use is reported and the compiled tables stay: one naming a town, dungeon, part, element or floor that does not exist, giving one twice, or giving a dungeon more Atla than the save holds or more on a half than its floors can take, which would have the placement look for room forever. dungeonparts.cpp says which floors take Atla for that check.
This branch has not been deployed
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.
The Georama's compiled tables become gameplay documents in ChronicleTwo's style (
schema_version2 pluskind), read like the item documents. Without a pack, the game plays exactly as before.The documents
kindgameplay/georama/parts.jsongeorama_partsEditPartsData,EditElementDatagameplay/georama/atla.jsongeorama_atlaAtraAppearDatapartor anelementon a fixedfloor, or on the dungeon'sfirst_halforsecond_halfasBtAtraListMakedivides it, with itscount.--export-gameplaywrites both documents as compiled, as a starting point for a pack.The code is in
port/src/georama/tables.cpp, documented indocs/GEORAMA.md.What is refused
A refused document is reported (
config: <path>: <reason>) and the compiled tables stay. Refused:BtAtraListMakewould otherwise loop forever looking for room. For this check,dungeonparts.cppnow exposes each dungeon's midpoint floor, its floor count, and whether a floor takes Atla.Notes
""as in the compiled table, and each town's 25th record (never read as a part) stays as compiled.stackableis exported as retail has it (5 or 10). The game only checks that it's above zero and adds 5 per Atla, as before.Testing
GeoramaTables(5 tests):ctest -j4passes on Linux, apart from the five Kazarov GPU tests that fail on lavapipe.