summaryrefslogtreecommitdiff
path: root/api.lua
AgeCommit message (Collapse)Author
2017-02-06Replace exclude_from_craft_guide with not_in_craft_guideWuzzy
2016-11-18Fix bug in usages. Closes #82Foz
2016-10-08Fail gracefully for invalid drop tables.Diego Martínez
Notified by user `photon` on IRC.
2016-08-07Merge pull request #65 from Wuzzy2/digging_chanceVanessa Ezekowitz
Add partial support for complex (table-based) node drops
2016-08-07Consider max_items in complex drop analysisWuzzy
2016-08-07Properly seperate chance digs from normal digsWuzzy
2016-08-07Take count into account for complex node dropsWuzzy
2016-08-07Reduce redundancy in chance-based dropsWuzzy
2016-08-07Add crafting type: digging by chanceWuzzy
2016-08-06Ensure formspec escaping for translated stringsWuzzy
2016-08-06Collect more missing strings for translationWuzzy
2016-03-31Allow items to exclude their recipes from the recipes listPedro Gimeno
Certain mods add many recipes that take smaller blocks and output a bigger block. This clutters the recipes list. Case in point: the circular saw from the moreblocks mod. This patch allows mods to tell the craft guide to not include recipes that contain certain items, by setting the group exclude_from_craft_guide = 1 in the items.
2015-08-16disallow repairing tools using the 'to craft grid', allow it to put items of ↵HybridDog
specific groups and (maybe) make it keep the meta of items, remove unused elseif, change a bit translation and use table.concat at one place because I read somewhere that it's faster than ..
2015-07-30Don't add a recipe to the main list if it contains any unknown items/groupsVanessa Ezekowitz
2015-04-18Round home positionsShadowNinja
2015-03-11Display conversion method symbolically and textually next to arrowRogier
2015-02-05reduce table lookups during initializationTim
2015-02-05supress intllib check warning, this fixes #19Tim
2014-06-21Add intllib support.RealBadAngel
Some polish and german translations. Start adding tooltips.
2014-06-13Show item usages in craft guideZefram
When the craft guide is showing a craft, the output slot is now a button, which causes the craft guide to show ways in which that output can be used. This mirrors the way input slots are buttons that show recipes for the selected ingredient. Usages of an item can be iterated through in the same way as recipes for the item. This incidentally offers some ability to retrace one's steps through a crafting chain, without storing actual history.
2014-06-13Fix and enhance grid shapes in craft guideZefram
Commit 043f6081452365daaa033c58e0738527ccb64c3d made shaped crafting recipes display in a grid of the recipe's minimum bounding box, but broke the use of a fixed 1x1 grid shape for cooking recipes. This commit generalises the dynamic-grid-shape facility, putting the craft type registration in charge. This restores the correct shape for cooking recipes. Also change the logic for dynamic grid sizes for regular shaped and shapeless crafting. We'd like to always use a grid shape that is reminiscent of a regular crafting grid, as a visual cue to the crafting method. But it's also nice to show smaller recipes in a smaller grid. In the expectation that crafting grids will always be square, show the recipe in the smallest square grid that will accommodate it.
2014-05-11Move around some group code and make the craftguide render well without a recipeShadowNinja
This also keeps recipes aligned to the right, close to the arrow. It also calculates the craft's height.
2014-05-02Show group ingredients visually in craft guideZefram
Where a recipe specifies an ingredient by group, show a typical group item pictorially, with a label flag to indicate that it's a group rather than the single item. This is the inverse of the previous arrangement, which identified the group by label and dipicted groupiness pictorially. The new arrangement is easier to interpret, and if the labels are ignored it actually shows a correct input to the crafting grid.
2014-04-30Use appropriate grid shape for each craft typeZefram
New system of registration of craft types, recording for each a display description and the appropriate grid shape. Recipes of a registered type are shown in the correct grid. Recipes of unregistered craft types are still displayed as before, using the default 3x3 grid.
2014-04-29Show non-identity digging results in craft guideZefram
2014-04-29Don't overwrite registered craftsZefram
The crafts_table was being initialised to contain only core-registered crafts, but this would overwrite any non-core craft types that had already been registered via unified_inventory.register_craft(). This was especially likely because the crafts_table initialisation runs on a delay, following all normal initialisation. Instead, feed the core-registered crafts into unified_inventory.register_craft().
2014-04-22Look for recipes under an item's aliasesZefram
get_all_craft_recipes() returns the recipes that were registered under the specified name, so asking about an item's canonical name won't see recipes registered under an alias, and vice versa. Several mods register recipes under aliases, so the craft guide was missing that handful of recipes. To work around it, invert the aliases table and ask explicitly about each alias.
2014-01-19Remove unnecessary recipe table copyingShadowNinja
2014-01-19Remove trailing whitespaceShadowNinja
2013-10-07Fix the bug clearing other than default crafting methods.RealBadAngel
2013-09-28UpdateShadowNinja
2013-09-21Update modRealBadAngel