Commit Graph

423 Commits

Author SHA1 Message Date
Jean-Patrick Guerrero
55f919ab8f Minor fix 2019-12-17 01:51:55 +01:00
Jean-Patrick Guerrero
937b40aae4 Remove recipe from caches after calling clear_craft() 2019-12-17 01:46:22 +01:00
Jean-Patrick Guerrero
97036d9f9a New formspec style 2019-12-17 01:33:40 +01:00
Jean-Patrick Guerrero
17a8c5ddd8 Merge branch 'master' of https://github.com/minetest-mods/craftguide 2019-12-09 21:16:47 +01:00
Jean-Patrick Guerrero
9fb5a93b2b Style 2019-12-09 21:16:41 +01:00
bell07
00a79d26e5 Fix comparing items with their aliases (#95) 2019-12-03 13:54:56 +01:00
Jean-Patrick Guerrero
303aa3ef91 Style cleaning 2019-11-27 13:36:06 +01:00
Jean-Patrick Guerrero
89059f20b6 Reorder formspec elements 2019-11-10 16:11:29 +01:00
Jean-Patrick Guerrero
7a7bb8dc51 Remove brackets 2019-11-03 19:16:29 +01:00
Jean-Patrick Guerrero
4241c89c17 http_post_data -> export_url 2019-11-01 02:04:35 +01:00
Jean-Patrick Guerrero
70d38d1c63 Minor cleaning 2019-11-01 01:56:35 +01:00
Jean-Patrick Guerrero
92c5b1ab8e Add progress bar info 2019-10-31 23:39:20 +01:00
Jean-Patrick Guerrero
62d2b302ed Add more accurate caching information 2019-10-25 13:41:56 +02:00
Jean-Patrick Guerrero
8b4ef8a4b7 Improve search filter accuracy 2019-10-25 01:43:40 +02:00
Jean-Patrick Guerrero
35b2ecfdc1 Implement visual feedbacks on nav buttons 2019-10-25 01:15:51 +02:00
Jean-Patrick Guerrero
edbed14d9b Fix non-shown recipes 2019-10-22 12:53:47 +02:00
Jean-Patrick Guerrero
77dbe040b8 Fix tooltip 2019-10-15 15:30:52 +02:00
Jean-Patrick Guerrero
b12502a7da Small fixes 2019-10-13 18:31:46 +02:00
Jean-Patrick Guerrero
e707db9ab9 Fix sfinv grid positioning 2019-10-13 00:27:31 +02:00
Jean-Patrick Guerrero
270dc19ec1 Fix crash with groups_to_items() 2019-10-12 13:21:46 +02:00
Jean-Patrick Guerrero
c9c2bf03de Small precisions 2019-10-11 02:45:51 +02:00
Jean-Patrick Guerrero
ee1eac039e Minor cleaning 2019-10-10 17:50:29 +02:00
Jean-Patrick Guerrero
4fb4fe1763 Add support for dropped items + support for URL fetched recipes +
bugfixes
2019-10-10 17:34:43 +02:00
Jean-Patrick Guerrero
98a652259b test 2019-10-09 00:16:42 +02:00
Jean-Patrick Guerrero
a8ad0435fa Add test file 2019-10-09 00:11:23 +02:00
Jean-Patrick Guerrero
41021895ce Minor cleaning 2019-10-08 14:56:45 +02:00
Jean-Patrick Guerrero
abd9274798 Fix crash in progressive mode + refacto 2019-10-08 00:39:28 +02:00
Jean-Patrick Guerrero
e16c23c29c Minor refactoring 2019-10-05 00:53:33 +02:00
Jean-Patrick Guerrero
90adfb42c1 Minor refactoring 2019-10-05 00:32:48 +02:00
Jean-Patrick Guerrero
c32feb44fc Update template 2019-10-05 00:23:46 +02:00
Jean-Patrick Guerrero
36878ce9a0 Show item drops 2019-10-05 00:09:29 +02:00
Jean-Patrick Guerrero
8b5de4f7f7 Minor refactoring 2019-10-04 23:11:07 +02:00
Jean-Patrick Guerrero
9e3997c689 Remove infos from info panel 2019-10-04 22:54:41 +02:00
Jean-Patrick Guerrero
ce74f49773 Add prev/next buttons for recipes/usages 2019-10-04 22:40:23 +02:00
Jean-Patrick Guerrero
fb4805ccf0 Add button background only if engine >= 5.1 2019-10-04 21:50:32 +02:00
Jean-Patrick Guerrero
2d332913c5 Fix messages in craft command 2019-10-04 01:10:55 +02:00
Jean-Patrick Guerrero
5446e0dbdd Update README + API 2019-10-04 00:45:49 +02:00
Jean-Patrick Guerrero
16ceea1aaf Fix message 2019-10-04 00:25:10 +02:00
Jean-Patrick Guerrero
c570fa2337 Tune fs style 2019-10-04 00:20:20 +02:00
Jean-Patrick Guerrero
5d7bb6de53 Update locale template + fix craft command 2019-10-04 00:17:15 +02:00
Jean-Patrick Guerrero
502318fb66 Major Interface Overhaul 2019-10-03 23:54:15 +02:00
Jean-Patrick Guerrero
937f5f0918 Fix aliased items once and for all(?) 2019-10-03 17:02:19 +02:00
Jean-Patrick Guerrero
b09870a5b2 Fix aliased items 2019-10-01 13:05:53 +02:00
Jean-Patrick Guerrero
9e48e9ea3e Fix missing recipes (again) 2019-09-30 18:04:50 +02:00
Jean-Patrick Guerrero
94637c624e Do not override alias func 2019-09-30 16:33:15 +02:00
Jean-Patrick Guerrero
bb6b3a4ee5 Show recipes for force-alised items 2019-09-30 11:17:01 +02:00
Jean-Patrick Guerrero
a50a99836a Fix version number check 2019-09-29 21:17:16 +02:00
Jean-Patrick Guerrero
3320fbdd6b Full backward compat with MT 0.4.17 2019-09-29 20:30:47 +02:00
Jean-Patrick Guerrero
19fb5e2691 Check compat for background[] 2019-09-29 17:23:03 +02:00
Jean-Patrick Guerrero
9dd63cd83a Fixed comment 2019-09-29 15:28:53 +02:00
Jean-Patrick Guerrero
07820fa37c Re-add accidentally removed 2019-09-29 15:24:04 +02:00
Jean-Patrick Guerrero
29f87f2607 Put the page number color back 2019-09-29 15:20:21 +02:00
Jean-Patrick Guerrero
aef1fe0dc6 Fix non-shown aliased recipes 2019-09-29 15:16:41 +02:00
Jean-Patrick Guerrero
f184341663 String checking 2019-09-25 16:22:38 +02:00
Jean-Patrick Guerrero
3f9d7bc12d Table check 2019-09-25 12:44:49 +02:00
Jean-Patrick Guerrero
60b09a27f7 Ensure that no fuel usages are not shown 2019-09-19 13:38:07 +02:00
Jean-Patrick Guerrero
a936452e21 Fix non-shown recipes 2019-09-18 20:09:03 +02:00
Jean-Patrick Guerrero
768e06e2d0 why the hell the page number not colorized anymore? 2019-09-16 12:56:04 +02:00
Jean-Patrick Guerrero
732535c9da Another attempt to fix nil crash 2019-09-16 12:33:28 +02:00
Jean-Patrick Guerrero
7a8b8d19df Fix possible nil crash 2019-09-15 22:39:08 +02:00
Jean-Patrick Guerrero
9dcccadfc2 Minor fix 2019-09-12 13:10:31 +02:00
Jean-Patrick Guerrero
7c891ff2b6 Small fix for custom recipe 2019-09-11 19:39:49 +02:00
Jean-Patrick Guerrero
06bef9777a Minor cleaning 2019-09-11 17:25:29 +02:00
Jean-Patrick Guerrero
738c2140a7 Show itemstring for unknown item 2019-09-11 16:35:56 +02:00
Jean-Patrick Guerrero
2ffef6794a Do not require to specify width in custom recipes 2019-09-11 16:28:37 +02:00
Jean-Patrick Guerrero
fb1b0cf869 Notification success: do not depend on dtime 2019-09-11 13:43:13 +02:00
Jean-Patrick Guerrero
59b806c9c4 Progressive: Update items in sfinv without page change 2019-09-11 12:25:28 +02:00
Jean-Patrick Guerrero
db626eaece Small cleaning 2019-09-10 17:27:59 +02:00
Jean-Patrick Guerrero
3b3da66a0d Improve tooltip for toolrepair 2019-09-10 16:01:00 +02:00
Jean-Patrick Guerrero
84795a6523 Fix tooltip for replacements 2019-09-10 12:37:39 +02:00
Jean-Patrick Guerrero
fc3f1fece2 Code cleaning 2019-09-10 12:29:32 +02:00
Jean-Patrick Guerrero
00a88a320a craftguide can show repairable tools 2019-09-10 00:05:55 +02:00
Jean-Patrick Guerrero
19b8e28afb Code cleaning 2019-09-09 21:56:37 +02:00
Jean-Patrick Guerrero
12e35f80f0 Fix replace tooltip 2019-09-09 19:30:44 +02:00
Jean-Patrick Guerrero
11da33ca76 Add comment 2019-09-09 19:10:33 +02:00
Jean-Patrick Guerrero
08e758aca5 Fix shapeless width bounds 2019-09-09 19:02:09 +02:00
Jean-Patrick Guerrero
727758b816 craftguide can read replacements! 2019-09-09 19:01:52 +02:00
Jean-Patrick Guerrero
b026e94d6e Fix custom recipe icon position 2019-09-08 12:48:46 +02:00
Jean-Patrick Guerrero
742627aa8c Add more doc to custom recipes 2019-09-08 12:28:30 +02:00
Jean-Patrick Guerrero
bf616f5d21 Add fallback background is not -dev version 2019-09-07 13:02:42 +02:00
Jean-Patrick Guerrero
22787e41e3 Change sign texture 2019-09-06 21:19:40 +02:00
Jean-Patrick Guerrero
6b76c8c10f API to set a custom background 2019-09-06 17:56:41 +02:00
Jean-Patrick Guerrero
5f68d2de11 Improve the interface 2019-09-06 17:06:23 +02:00
Jean-Patrick Guerrero
3d77ec58b4 Ability to register custom crafts dynamically 2019-09-06 15:51:30 +02:00
Jean-Patrick Guerrero
83151cb394 More interface fine-tuning 2019-09-06 13:31:50 +02:00
Jean-Patrick Guerrero
337ac898cd Fine-tune items positioning + Remove zoom in/out features 2019-09-05 21:04:27 +02:00
Jean-Patrick Guerrero
cb0200a222 Small cleanup 2019-09-05 15:02:38 +02:00
Jean-Patrick Guerrero
ae4b15a748 Improve grid display 2019-09-05 14:42:35 +02:00
Jean-Patrick Guerrero
2fa14ae146 Code cleaning 2019-08-31 13:34:54 +02:00
Jean-Patrick Guerrero
8b86dfc857 Fine-tune HUD 2019-08-30 18:36:34 +02:00
Jean-Patrick Guerrero
d324c5f1e5 Progressive mode: Add a Steam-like HUD success + remove useless API functions 2019-08-30 17:05:03 +02:00
Jean-Patrick Guerrero
dfa45789e2 Style cleaning 2019-08-29 15:41:32 +02:00
Jean-Patrick Guerrero
80a0d67f15 Ability to register recipes in MC-like way 2019-08-29 14:56:53 +02:00
Beha
22c5c9444e Interpret group value 0 as "not in group".
This fixes instances where items are counted as part of a group by
craftguide but not by the engine.
2019-08-29 14:47:19 +02:00
Jean-Patrick Guerrero
97676d094e Fix possible crash 2019-06-30 19:42:32 +02:00
Jean-Patrick Guerrero
ca18ae0e3a Fix nil item crash in get_tooltip() - Fixes #84, regression caused by d950c71db (@pauloue) 2019-06-30 16:37:09 +02:00
Jean-Patrick Guerrero
e710fcd483 Small optimization 2019-06-23 01:42:12 +02:00
Jean-Patrick Guerrero
a2e4f20791 Items with no recipes but with usages are shown 2019-06-23 01:25:18 +02:00
Jean-Patrick Guerrero
22a85f50c1 Sugar 2019-05-08 20:57:45 +02:00
Jean-Patrick Guerrero
0271f61fc2 Change tooltip format 2019-03-21 17:44:32 +01:00
Jean-Patrick Guerrero
84756af3a1 Opens the stereotypes to the API 2019-03-21 17:34:20 +01:00
Jean-Patrick Guerrero
9dc656d5a2 Fix broken assert() 2019-03-21 00:21:11 +01:00
Jean-Patrick Guerrero
4c0371c5cc Progressive mode: Fix crash on player leaving 2019-03-14 14:11:44 +01:00
Jean-Patrick Guerrero
b6181ebd7a Minor cleanup 2019-03-13 16:56:35 +01:00
Wuzzy2
eb7292da7a 2×2 for shapeless recipe w/ <= 4 items 2019-03-13 15:22:45 +01:00
Jean-Patrick Guerrero
9df355b899 Add more assert checks 2019-03-12 16:54:26 +01:00
Jean-Patrick Guerrero
a242f6c61c Revert some changes 2019-03-11 03:01:37 +01:00
Jean-Patrick Guerrero
c9ebd5c069 Cleanup 2019-03-10 16:27:36 +01:00
Jean-Patrick Guerrero
e0e57b45ea Quick fix 2019-03-04 01:19:13 +01:00
Jean-Patrick Guerrero
3f7ad71e00 Add an API for search filters 2019-03-03 17:11:02 +01:00
Jean-Patrick Guerrero
eb2a81b8b5 Allow special search filters by groups
Using <optional name>:groups=<group_name1,group_name2,...>
2019-03-01 19:14:43 +01:00
pauloue
92daae3e95 Replace group with item in item's usages 2019-03-01 17:48:51 +01:00
Jean-Patrick Guerrero
183a9ff7a1 Fix get_filtered_items again 2019-02-22 15:28:36 +01:00
Jean-Patrick Guerrero
cdc8e410b6 Add french translations, revise others 2019-02-21 16:59:07 +01:00
Jean-Patrick Guerrero
7219a6096b Minor cleanup 2019-02-21 15:31:28 +01:00
Jean-Patrick Guerrero
7f44517701 Fix alternate button not shown for too large recipes 2019-02-21 01:54:15 +01:00
Jean-Patrick Guerrero
5e4a362a15 Fix some crash 2019-02-21 01:44:09 +01:00
Jean-Patrick Guerrero
058cd05ed7 Separate custom_crafts tables from main table 2019-02-21 01:08:37 +01:00
Jean-Patrick Guerrero
fa30a0d076 Add an API for custom formspec elements 2019-02-21 01:02:59 +01:00
Jean-Patrick Guerrero
92cf2307db Progressive: do not show items that you didn't get 2019-02-20 18:11:59 +01:00
Jean-Patrick Guerrero
bfe99092db Cleanup and optimizations 2019-02-18 01:49:05 +01:00
Jean-Patrick Guerrero
97e6eceb75 Progressive: Poll new items every 0.5s 2019-02-16 01:52:54 +01:00
Jean-Patrick Guerrero
d6432f53bb Add a comment on the item polling 2019-02-13 14:32:36 +01:00
Jean-Patrick Guerrero
8f6f8dda7e Use engine translator, ditch intllib 2019-02-13 14:16:55 +01:00
Jean-Patrick Guerrero
40b5f8725a Fix some glitch 2019-02-13 14:06:33 +01:00
Jean-Patrick Guerrero
0956e86d73 Check also the 'craftpreview' list 2019-02-13 01:30:34 +01:00
Jean-Patrick Guerrero
07bc14e516 Track new discovered items all the time 2019-02-13 01:10:49 +01:00
pauloue
b3bba5c2ff Fix get_filtered_items() 2019-02-13 01:05:21 +01:00
Jean-Patrick Guerrero
4560457504 Mitigate the performance regression since fc2d2e5 2019-02-11 23:52:31 +01:00
Jean-Patrick Guerrero
3f44ae00d2 Remove demo custom recipe 2019-02-11 01:22:45 +01:00
Jean-Patrick Guerrero
1ba1e41dcd Progressive: Add a better error message for empty items list 2019-02-11 00:30:06 +01:00
Jean-Patrick Guerrero
3cf4bef83a Shorten function name 2019-02-11 00:22:00 +01:00
Wuzzy2
c4272d8d24 Add formspec escape, apply proper format strings 2019-02-11 00:18:37 +01:00
Jean-Patrick Guerrero
aac3e3f693 Add API call to open crafting guide (#59) 2019-02-11 00:01:32 +01:00
Jean-Patrick Guerrero
fc2d2e585c Fix issue #60 2019-02-10 23:07:28 +01:00
Jean-Patrick Guerrero
e37f1df6d3 Fix error message in progressive mode 2019-02-10 20:37:24 +01:00
Jean-Patrick Guerrero
6e744b44b1 Few minor optimizations 2019-02-07 16:08:50 +01:00
Paul Ouellette
a7dd13994f remove shapeless, minor refactors 2019-02-06 22:59:38 -05:00
Paul Ouellette
85ece2c8b9 filter /craft recipes, fix crash, fix sfinv form 2019-02-06 15:05:33 -05:00
Jean-Patrick Guerrero
65a8707a69 Repair the /craft command 2019-02-06 02:02:41 +01:00
Jean-Patrick Guerrero
3e9e16b661 Minor cleaning 2019-02-06 01:26:32 +01:00
pauloue
4289dea108 Separate recipe filters and progressive mode 2019-02-03 16:17:02 +01:00
Jean-Patrick Guerrero
5625a0cb1c Remove superfluous call 2019-01-31 01:10:09 +01:00
Jean-Patrick Guerrero
5e8079b2e8 Saving p_items not necessary 2019-01-30 02:14:11 +01:00
Jean-Patrick Guerrero
fd375c92b3 Init data when player joins 2019-01-30 02:02:09 +01:00
Jean-Patrick Guerrero
7fc2d3a96a Ensure sfinv is loaded 2019-01-27 16:32:48 +01:00
Jean-Patrick Guerrero
c1b1bef263 Progressive mode: Remember discovered recipes 2019-01-25 02:43:33 +01:00
Jean-Patrick Guerrero
e6268a395f Empty data when player leaves 2019-01-22 02:03:01 +01:00
Jean-Patrick Guerrero
5d73794096 Localize formspec string formats 2019-01-22 01:59:54 +01:00
pauloue
d950c71dbc Refactors, optimizations and fixes 2019-01-22 01:45:21 +01:00
Jean-Patrick Guerrero
5ee1bea4ce Progressive mode: Add a name to filters 2019-01-20 02:13:30 +01:00
Jean-Patrick Guerrero
61ae85a09c Progressive mode: Add functions in API to add/set/get filters 2019-01-18 17:39:10 +01:00
Jean-Patrick Guerrero
c4fe467e6f Remove wood group 2019-01-18 15:56:52 +01:00
Jean-Patrick Guerrero
ed11bf3281 Fix tooltip 2019-01-15 14:38:15 +01:00
Jean-Patrick Guerrero
18affcb00e Allow searching same string again in progressive mode 2019-01-13 18:30:21 +01:00
Jean-Patrick Guerrero
fa8d602a64 Fix sfinv mode bg 2019-01-13 02:40:18 +01:00
Jean-Patrick Guerrero
157c6e5004 get_formspec -> make_formspec 2019-01-13 01:48:14 +01:00
pauloue
50317cc20e Progressive: refactor, fix some bugs, add API function 2019-01-13 01:37:23 +01:00
Jean-Patrick Guerrero
1def071029 Fix background 2019-01-13 01:18:41 +01:00
Jean-Patrick Guerrero
134fbf382d Do not search again for same string 2019-01-11 01:54:17 +01:00
Jean-Patrick Guerrero
70682b230b Hardset button size to 1.1 2019-01-09 21:11:06 +01:00
Paul Ouellette
e0db5834b3 Separate player data 2019-01-08 14:28:53 -05:00
pauloue
7f6dd430ce Various fixes
- Include recipes with matching groups in usages
- Fix group_to_item()
- Fix custom recipes not showing in usages
2019-01-08 01:28:52 +01:00
Jean-Patrick Guerrero
d1ee125a1a Remove erroneous quotation marks 2019-01-04 02:19:29 +01:00
Jean-Patrick Guerrero
b980dccaee Use of string.format instead of concat 2019-01-02 18:57:35 +01:00
Paul Ouellette
f8b7a72635 Fix alternate button not working in some cases 2019-01-02 01:11:08 -05:00
Paul Ouellette
1034fd7c0e Fix repeated clicks of same item not toggling usages mode 2019-01-02 00:35:21 -05:00
Jean-Patrick Guerrero
4bca02f0db Add assertions 2018-12-30 21:52:13 +01:00
Jean-Patrick Guerrero
4b97b08aa7 Variable naming 2018-12-30 21:22:01 +01:00
Jean-Patrick Guerrero
7745ccd863 Not really important 2018-12-30 21:10:39 +01:00
Jean-Patrick Guerrero
65b51ad3e5 Do not alternate if X > 1 2018-12-30 21:00:04 +01:00
Jean-Patrick Guerrero
897fc3a21d Show usages for fuel-able items with no recipes 2018-12-30 20:43:26 +01:00
Jean-Patrick Guerrero
e1eedb69bb Minor optimization 2018-12-19 18:36:09 +01:00
Jean-Patrick Guerrero
f188580b8c Correct checking 2018-12-17 22:48:53 +01:00
Jean-Patrick Guerrero
783a84d3c6 Define custom recipe's width inside craft declaration 2018-12-17 19:17:43 +01:00
Jean-Patrick Guerrero
74a2750a4d Fix tooltip 2018-12-17 01:14:55 +01:00
Jean-Patrick Guerrero
9da500ce2c ... and make the other functions local 2018-12-17 01:02:51 +01:00
Jean-Patrick Guerrero
610117de08 Make craftguide a global var 2018-12-17 00:38:58 +01:00
Jean-Patrick Guerrero
53833af635 Add an API for custom recipes 2018-12-17 00:37:49 +01:00
Jean-Patrick Guerrero
b2a7f5430a Add a /craft command to show recipe of pointed node 2018-12-13 20:31:45 +01:00
Jean-Patrick Guerrero
0b4f202ffb New icons 2018-11-25 16:08:20 +01:00
Jean-Patrick Guerrero
eff2fa82f3 Fix custom recipes since latest commit 2018-11-18 20:52:00 +01:00
Jean-Patrick Guerrero
8630fccaea More alignment 2018-11-18 20:06:45 +01:00
Jean-Patrick Guerrero
4d4e8f7d50 Rotate arrow images 2018-11-18 18:40:58 +01:00
pauloue
6d3f8ce32a Fix cooktime tooltip 2018-11-18 18:26:09 +01:00
Jean-Patrick Guerrero
ed861ea1b9 Formspec improvements (fixes #39) 2018-11-17 18:24:12 +01:00
Jean-Patrick Guerrero
44ebb84e89 Fix the usage' tooltip again (thanks @Ezhh) 2018-11-13 20:15:34 +01:00
Jean-Patrick Guerrero
5fce8ddbda Minor edits 2018-11-12 23:56:11 +01:00
Jean-Patrick Guerrero
39ed2c2c45 Support for sfinv! 2018-11-11 22:58:26 +01:00
Jean-Patrick Guerrero
8b309106c3 Various fixes 2018-11-11 19:35:28 +01:00
pauloue
9625542468 Fix reverse mode + misc. things 2018-11-11 14:19:52 +01:00
Wuzzy
2b23a887cf Hide recipes for items with not_in_craft_guide=1 2018-05-29 19:08:03 +02:00
Jean-Patrick Guerrero
2ecd0543a9 Fix 2018-05-28 22:07:52 +02:00
Jean-Patrick Guerrero
dd268e065b Implement a reverse crafting guide (#30) 2018-05-28 19:07:05 +02:00
JP Guerrero
d95cdee33d Cache results only if searched 2 times (to avoid silly searches) 2018-04-27 23:01:03 +02:00
JP Guerrero
c630c90970 Add custom recipes test code 2018-04-27 22:30:41 +02:00
JP Guerrero
ee7c388681 Sugar 2018-04-17 13:30:51 +02:00
Eugen Wesseloh
95518c3725 Add Russian and German translations (using intllib) (#28) 2018-04-08 22:31:16 +02:00
JP Guerrero
f1e58084d1 Add a table memoizer to optimize things 2018-03-08 20:10:00 +01:00
JP Guerrero
2df3f9c02f Bigger item buttons 2018-03-08 17:06:53 +01:00