Conversation
|
b |
|
c |
|
d |
|
E |
|
f |
|
g |
|
h |
|
i |
|
j |
|
k |
|
L |
|
m |
|
n |
kulkanmalik
pushed a commit
to kulkanmalik/Stevever
that referenced
this pull request
Nov 11, 2025
This commit implements the full crafting system for Steve entities, enabling autonomous crafting of Minecraft items with recipe validation, ingredient checking, and crafting table management. ## Changes ### 1. SteveEntity (entity/SteveEntity.java) - Added ItemStackHandler inventory (36 slots, same as player) - Implemented NBT serialization for inventory persistence - Added getInventory() accessor method ### 2. InventoryHelper (util/InventoryHelper.java) - Complete implementation of inventory management utilities - Item query methods: hasItem(), getItemCount(), getInventoryFullness() - Item manipulation: addItem(), removeItem() - Tool management: findBestTool(), needsToolRepair(), hasRequiredTool() - Chest operations: findNearestChest(), transferToChest(), retrieveFromChest() - Helper methods: isInventoryFull(), getEmptySlotCount() ### 3. RecipeHelper (util/RecipeHelper.java) - Full Minecraft recipe system integration - Recipe lookup: hasRecipe(), findRecipe() - Ingredient extraction: getRequiredIngredients(), getMissingIngredients() - Crafting table detection: requiresCraftingTable() - Recursive crafting chain analysis: getFullCraftingChain() - Recipe validation: hasAllIngredients(), getRecipeResultCount() - Recipe metadata: isShapedRecipe(), getRecipeDimensions() ### 4. CraftItemAction (action/actions/CraftItemAction.java) - Complete crafting workflow implementation with 6 phases: 1. VALIDATING - Check recipe exists and ingredients available 2. FINDING_TABLE - Search for crafting table within 16 blocks 3. PLACING_TABLE - Place crafting table if not found 4. NAVIGATING_TO_TABLE - Navigate to crafting table location 5. CRAFTING - Execute crafting operations 6. COMPLETED - Finish action - Intelligent crafting table management (find, place, navigate) - Multi-quantity crafting support with progress tracking - Ingredient validation with detailed error messages - Inventory rollback on failure - Timeout handling (10 minutes max, 30s navigation) ### 5. Development Roadmap (DEVELOPMENT_ROADMAP.md) - Comprehensive 5-phase development plan - Detailed specifications for all future features - Implementation checklists and success criteria - Risk management and best practices documentation ## Features - ✅ Steve entities can now craft any Minecraft item with a recipe - ✅ Automatic ingredient checking before crafting - ✅ Intelligent crafting table finding and placement - ✅ Full inventory management (add, remove, transfer to chests) - ✅ Tool durability tracking and selection - ✅ Persistent inventory across world reloads - ✅ Support for both shaped and shapeless recipes - ✅ Multi-quantity crafting (e.g., "craft 10 sticks") - ✅ Detailed error messages for missing ingredients ## Technical Details - Uses Minecraft Forge 1.20.1 RecipeManager API - Leverages ItemStackHandler for robust inventory handling - Implements NBT serialization for data persistence - State machine pattern for crafting workflow - Comprehensive Javadoc documentation ## Testing Required Build the project locally: ```bash ./gradlew build ``` Test crafting in-game: ``` /steve spawn TestSteve /steve tell TestSteve "craft wooden_pickaxe" ``` ## Next Steps (Phase 1.2) - Implement advanced inventory management (auto-storage, sorting) - Add persistent memory system - Integrate real vector store for semantic memory - Implement async action execution --- Related to: DEVELOPMENT_ROADMAP.md Phase 1.1 Implements: Crafting System (YuvDwi#1 Priority Feature)
|
o |
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.
a