quilt-mappings
quilt-mappings copied to clipboard
Feature Flag Mapping
Maps feature flag related code - FeatureFlag
, FeatureFlagBitSet
, FeatureGroup
, and friends. Also maps the sync packet, a number of usages of feature flags, and some creative tab code that interacts with them.
Marking as draft because I'm not confident in some names (like FeatureFlagBitSet
) and because the creative tab mappings might be unnecessary for this PR.
🚨 Target branch is already set to 22w42a
Some reasoning on the names:
-
FeatureFlagGroup
is tricky. In strings and mojmap, it's a "universe", but this is a non-descriptive name that has already caused confusion in conversations. Since these are groups of feature flags stored together, I call them groups, but there might be a better way of writing that. -
FeatureFlagBitSet
is a set of flags from a particular group, stored using their bitmasks. This could have been called aFeatureFlagSet
directly, but that's literally a synonym of group, and usingBitSet
(hopefully) emphasises their role as a modifiable/copyable collection of flags, rather than part of the flags' definition/configuration like groups are. -
FeatureAndDataSettings
is hard. It's a collection of feature flags and their associated datapacks; this needs to be distinct from both worldgen features while also somehow indicating the datapacks included. The mojmap name is (subjectively) worse. -
FeatureAndDataSettings.MINIMAL
,FeatureFlags.VANILLA
,MAIN_REGISTRY
could maybe all use one term. Also idk what the difference is betweenDEFAULT_SET
andVANILLA_SET
-
ItemCollector
collects item stacks without considering size;GatedItemCollector
implements that while considering feature flag. Here we diverge from #256, which usesItemStackCollector
(better) andSplitStackCollector
, which is misleading because all collectors are split, but only this one is feature-gated. -
UnsizedItemStackSet
is wordy, and implies that the set itself is unsized, but I couldn't think of a better way of indicating "stack size doesn't matter" that doesn't have the same issue. Feedback appreciated
🚀 Target branch has been updated to 22w43a
🚨 Please fix merge conflicts before this can be merged
🚀 Target branch has been updated to 22w44a
🚨 Please fix merge conflicts before this can be merged
🚀 Target branch has been updated to 22w45a
🚨 Please fix merge conflicts before this can be merged
🚀 Target branch has been updated to 22w46a
🚨 Please fix merge conflicts before this can be merged
Superceeded by #271