Comments (9)
Since 92cf230 the
inv_items
table is used for all progressive implementations that is not always right.
No, wrong: a076e10. Though I'm not satisfied with this patch, I'm waiting @pauloue to take a look.
from craftguide.
Line 263 is still item_in_inv(item, data.inv_items)). The data.inv_items is used by the default progressive implementation and managed by poll_new_items chain.
Hm, there is no way to disable the poll_new_items chain for custom implementation.
from craftguide.
If you read the code correctly you'd see this is not used by all progressive implementations but the default one.
from craftguide.
The function get_filtered_items is used for all progressive implementations. Therefore since 92cf230 the data.inv_items is used partially (check if item revealed to be shown with usages) for all implementations.
from craftguide.
data.inv_items
and poll_new_items
are used only for the default filter. They are not used if you disable progressive mode. The use of data.inv_items
in get_filtered_items
was to fix #68 and the proposed API would be necessary to make this fix apply to other recipe filters, but I'm not sure if #68 is really a big enough issue to add a new API.
from craftguide.
I am about the case the progressive mode is enabled, but the default implementation is replaced trough craftguide.set_recipe_filter().
The Use-case is my craftguide_reveal mod. The mod does the same as the default one, but uses the reveal-tracking table from doc_items mod instead of data.inv_items. I search for a way to replace the data.inv_items in line 262 by the doc_items table. And the way to disable the poll_new_items chain since the polling is done in doc_items.
from craftguide.
If you don't want to use the default progressive mode you should disable it and use craftguide.add_recipe_filter
so that poll_new_items
doesn't get called and data.inv_items
doesn't get saved. Progressive mode doesn't have to be enabled to use recipe filters.
from craftguide.
You are rigt, I see there are a lot of changes in code since I get the deeper look last time. If I disable the progressive mode I get the issue #68 with my implementation. In #74 is my proposal to finally fix the issue. Just pass all needed informations to the filter function, the filter function can handle the crafting/usage difference.
from craftguide.
The reason for this issue is solved in #75.
Therefore this issue can be closed if the #75 is merged.
The initially proposed "Item filter" would be still useful, but not a must-have.
If interessted I can implement the "Item filter" API functions, I just don't want to start coding in assumption it will be rejected from the beginning.
from craftguide.
Related Issues (20)
- Craftguide inventory graphical issue HOT 8
- Searching the craftguide based on category HOT 2
- Runtime error on first run on new map HOT 4
- Server crashes on logout when mod is active. HOT 4
- Switch between Progressive and Complete mode within Game HOT 1
- Multiple crashes while trying to use craftguide for the first time HOT 1
- Invalid command: craft HOT 1
- Attempt to index local 'meta' (a nil value) HOT 4
- Mod crashes HOT 2
- Allegedly greatly increased load times HOT 2
- crash with latest version HOT 3
- Deal with items that have no recipe HOT 1
- Some recipes not being shown HOT 5
- mesecons_materials + basic_materials - Silicon lump recipe not shown HOT 10
- core.register_alias and core.register_alias_force should not be redefined HOT 9
- Misplaced 3x3 recipes HOT 1
- sfinv mode recipe out of border and other issues HOT 2
- sfinv_only mode does not work with progressive_mode HOT 1
- Craftguide data caching is not persistent HOT 26
- Inventory_plus support
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 craftguide.