Comments (4)
It appears in the unified_inventory's crafting guide, but I can confirm it's not appearing in my version of the crafting table mod for me either.
I don't see anything unusual just looking at the code for the crafting recipe or node definition, I'll need to do some more in-depth debugging when I get home. May be a few hours.
Which craft guide is it also not appearing in, this one? Given that it appears in the unified_inventory craft guide but not the crafting table I bet there's some weird trick to reading craft recipes that I've overlooked, if nothing else I should be able to compare how they're doing it and find out what's different.
from hopper.
Okay, got home and I figured it out. The problem is due to a quirk of Lua, and the bug lies in the crafting table (and the crafting guide) rather than in hopper.
The default minetest crafting recipe format records the three-by-three crafting grid as a linear array of nine entries, laid out like so:
1 2 3
4 5 6
7 8 9
which in Lua terms is {[1] = "item1", [2] = "item2", [3] = "item3"} and so forth.
The problem is that Lua assumes an array has members in every slot. So if there's a Lua array that goes:
{[1] = "item1", [2] = "item2", [3] = nil, [4] = "item3"}
and you ask Lua how long that array is, it will say it is only two entries long. It reads index 1, then index 2, then sees that index 3 is empty and assumes that's the end.
The recipe for the hopper sorter is:
"" "mese crystal" ""
"steel" "chest" "steel"
"" "steel" ""
As you can see, this would translate into an array with entry [1] having nil in it. So ask Lua how long that array is and it'll think it's an empty array. There was a check in the crafting system code that was seeing a recipe with no inputs and was throwing that away as invalid. This means that any recipe out there that has nothing in the upper left corner was being missed by the crafting table.
So, I can fix this in the crafting system easily enough, I'll have that checked in shortly (I'm going to take a few minutes hunting for further instances where this might come up). The crafting guide that you've found with this problem is a separate issue, it's probably got a similar bug in its code.
from hopper.
Fix is in for the crafting table with this commit.
from hopper.
Huh, interesting bug! Just assumed the problem lied in how the specific crafting recipe of the sorter hopper was constructed, because that's what have been the issue with disappearing craft guide recipes in the past in my experience. I'm glad it could be traced back to the other mods. Thank you for also explaining why the bug occured as I learnt something new.
from hopper.
Related Issues (16)
- Inclusion of the languages "pt" and "pt_BR" HOT 1
- [Translating] Dutch HOT 3
- New German Translation HOT 1
- Feature request: lower log verbosity from ACTION to DEBUG HOT 2
- Hopper mode on/off textures should be language agnostic
- French translation has missing placeholders HOT 1
- Ejecting HOT 2
- API: Add seconds argument, after how many seconds an item should be taken out of a container
- Inconsistent placing of nodes against chute/filter output end
- [Bug] `default` is not really an optional dependency
- [Feature request] Add support for MineClone's `container` groups. HOT 1
- [Feature Request] Expand the API to add specific nodes instead of all nodes with that name
- [Feature Request] API: Alternatively use callbacks as pipeworks HOT 7
- Sorter item duplication bug HOT 1
- Request Weblate free hosting HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hopper.