Stained Glass Survival Integration & Crafting UI Fix#1195
Open
LordCambionGaming wants to merge 3 commits intosmartcmd:mainfrom
Open
Stained Glass Survival Integration & Crafting UI Fix#1195LordCambionGaming wants to merge 3 commits intosmartcmd:mainfrom
LordCambionGaming wants to merge 3 commits intosmartcmd:mainfrom
Conversation
i found out that stained glass was not accessible in survival, then i saw they disabled it in the code
I removed the #if/endif from the ClothDyeRecipes.cpp and added a different one in StructureRecipies.cpp also changed the Tile definition giving it the same setBaseItemTypeAndMaterial of stained glass to group it correctly inside the crafting table UI. also aincremented the Vertical Slot for crafting table to include many more craftings in the same group
|
I would have removed the #if 0 instead of replacing it with 1 |
Author
i commented it |
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.
Description
This PR restores survival access to stained glass and stained glass panes by implementing a custom crafting logic and fixing a UI constraint in the crafting menu.
Changes
Previous Behavior
Stained glass and panes were only accessible in Creative mode. Their recipes in "ClothDyeRecipes.cpp" were disabled via preprocessor directives. Adding new recipes to the crafting grid would cause layout issues, creating new columns that overlapped or deleted existing columns (like the Rockets column).
Root Cause
Stained glass recipes were wrapped in an "#if 0" block in "ClothDyeRecipes.cpp", the vertical slot size for the crafting grid was hardcoded to 17, which limited the number of displayable categories and "thinGlass" (glass panes) lacked the same base item type and material definitions as stained variants, causing them to be categorized separately.
New Behavior
Stained glass and panes are now fully craftable in Survival. The crafting UI remains stable and organized, with all glass variants grouped into the same column:

Fix Implementation
I Removed the disabled code from "ClothDyeRecipes.cpp" and implemented the new crafting logic within "StructureRecipes.cpp " for a better organization.
I also increased the vertical slot height in the crafting UI from 17 to 99. This allows for more recipes without breaking the column layout.
Then I updated "thinGlass" using "setBaseItemTypeAndMaterial" to match the stained glass variants. This ensures they are grouped correctly in the same crafting column.
AI Use Disclosure
I didn't use artificial intelligence; I did my own research and modified and read the code myself, without any outside help.
I apologize if I made any spelling mistakes, but English isn't my first language.
Related Issues