mirror of
https://github.com/minetest-mods/craftguide.git
synced 2024-11-26 04:23:44 +01:00
Only search in translated item description
This commit is contained in:
parent
bfa7f4d631
commit
c008f5097d
7
init.lua
7
init.lua
@ -1386,10 +1386,9 @@ local function search(data)
|
|||||||
|
|
||||||
for i = 1, #data.items_raw do
|
for i = 1, #data.items_raw do
|
||||||
local item = data.items_raw[i]
|
local item = data.items_raw[i]
|
||||||
local def = reg_items[item]
|
local def = reg_items[item]
|
||||||
local desc = (def and def.description) and lower(def.description) or ""
|
local desc = lower(translate(data.lang_code, def and def.description)) or ""
|
||||||
local loc_desc = lower(translate(data.lang_code, def and def.description)) or ""
|
local search_in = fmt("%s %s", item, desc)
|
||||||
local search_in = fmt("%s %s %s", item, desc, loc_desc)
|
|
||||||
local to_add
|
local to_add
|
||||||
|
|
||||||
if search_filter then
|
if search_filter then
|
||||||
|
Loading…
Reference in New Issue
Block a user