Repository navigation
feat(merge): remap switch and variable ids the mods share - #8
Merged
Merged
Conversation
Plan switch and variable ids against vanilla's System.json scan, rewrite every command row that names one, and report an id two mods use as a StateIdOverlap with a move offer. Names the sharing mods give fold into that overlap; a mod's new id on its own recorded target moves on as a new entry, or warns. Operand rows hold for any designation but 0, as the engine reads them; 203 and 301 keep 1. A test interpreter checks a padded database file loads.
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.
Slice 2r step 3 of the merge engine: switch and variable ids.
What it does
VanillaStateIds.Scanreads every vanilla data file once and lists the switch and variable ids vanilla names or uses. Lane A caches it per vanilla version (seam R-12). Without it, nothing is shared and recorded entries still apply.StateIdOverlapon its name inSystem.json. It is a warning that defaults toAccept, since mods may share an id on purpose. A move is only offered, as one run of consecutive free ids for every range it takes along (GR-R14).""padding no longer clashes with another mod's name.Review first
RPGModder.Core/Merge/IdRemapPlanner.States.cs: shared ids, runs, offers, own targets.RPGModder.Core/Merge/Composer.cs:StateOverlap,FoldSharedNames, padding.RPGModder.Core/Merge/IdRemapper.cs: name slots andKeepOwnNames.Out of scope
Command tree and sequence merge (slice 2b) is the next PR.
Checks
dotnet format --verify-no-changesclean, LF onlyRPGModder.Tests/Support/TestInterpreter.cs) loads padded database files for all twelve kinds on MZ and MV