diff options
author | ANAND <ClobberXD@gmail.com> | 2019-04-07 15:30:57 +0530 |
---|---|---|
committer | SmallJoker <SmallJoker@users.noreply.github.com> | 2019-04-07 12:00:57 +0200 |
commit | 3deaa7cf57f174a224b433710429b7a9abdbce71 (patch) | |
tree | 9364778ac6810ced571127d45199a6a8348098b5 /src | |
parent | 5b8363af0084786a7e949ae8fa16bde046f8ffda (diff) | |
download | minetest-3deaa7cf57f174a224b433710429b7a9abdbce71.tar.gz minetest-3deaa7cf57f174a224b433710429b7a9abdbce71.tar.bz2 minetest-3deaa7cf57f174a224b433710429b7a9abdbce71.zip |
Add deprecation warnings for ObjectRef:get/set_attribute (#8443)
Diffstat (limited to 'src')
-rw-r--r-- | src/script/lua_api/l_object.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/script/lua_api/l_object.cpp b/src/script/lua_api/l_object.cpp index b3ed39c7c..597cb84a8 100644 --- a/src/script/lua_api/l_object.cpp +++ b/src/script/lua_api/l_object.cpp @@ -1239,6 +1239,9 @@ int ObjectRef::l_get_breath(lua_State *L) // set_attribute(self, attribute, value) int ObjectRef::l_set_attribute(lua_State *L) { + log_deprecated(L, + "Deprecated call to set_attribute, use MetaDataRef methods instead."); + ObjectRef *ref = checkobject(L, 1); PlayerSAO* co = getplayersao(ref); if (co == NULL) @@ -1257,6 +1260,9 @@ int ObjectRef::l_set_attribute(lua_State *L) // get_attribute(self, attribute) int ObjectRef::l_get_attribute(lua_State *L) { + log_deprecated(L, + "Deprecated call to get_attribute, use MetaDataRef methods instead."); + ObjectRef *ref = checkobject(L, 1); PlayerSAO* co = getplayersao(ref); if (co == NULL) |