mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Fix missing ignore textures (#7326)
This commit is contained in:
parent
6d6b894c7a
commit
22df02d25b
3 changed files with 9 additions and 18 deletions
|
@ -536,11 +536,16 @@ int ModApiItemMod::l_register_item_raw(lua_State *L)
|
|||
idef->registerItem(def);
|
||||
|
||||
// Read the node definition (content features) and register it
|
||||
if(def.type == ITEM_NODE){
|
||||
if (def.type == ITEM_NODE) {
|
||||
ContentFeatures f = read_content_features(L, table);
|
||||
// when a mod reregisters ignore, only texture changes and such should
|
||||
// be done
|
||||
if (f.name == "ignore")
|
||||
return 0;
|
||||
|
||||
content_t id = ndef->set(f.name, f);
|
||||
|
||||
if(id > MAX_REGISTERED_CONTENT){
|
||||
if (id > MAX_REGISTERED_CONTENT) {
|
||||
throw LuaError("Number of registerable nodes ("
|
||||
+ itos(MAX_REGISTERED_CONTENT+1)
|
||||
+ ") exceeded (" + name + ")");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue