mirror of
https://github.com/minetest/minetest.git
synced 2025-03-06 20:48:40 +01:00
set_nametag_attributes: don't reset nametags if text param is not touched
fixes #12901
This commit is contained in:
parent
8de9e2ac84
commit
6bf662cb9e
1 changed files with 1 additions and 2 deletions
|
@ -721,8 +721,7 @@ int ObjectRef::l_set_nametag_attributes(lua_State *L)
|
|||
}
|
||||
lua_pop(L, 1);
|
||||
|
||||
std::string nametag = getstringfield_default(L, 2, "text", "");
|
||||
prop->nametag = nametag;
|
||||
prop->nametag = getstringfield_default(L, 2, "text", prop->nametag);
|
||||
|
||||
prop->validate();
|
||||
sao->notifyObjectPropertiesModified();
|
||||
|
|
Loading…
Add table
Reference in a new issue