summaryrefslogtreecommitdiff
path: root/src/script/common/c_content.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/script/common/c_content.cpp')
-rw-r--r--src/script/common/c_content.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/script/common/c_content.cpp b/src/script/common/c_content.cpp
index 6fb9080bc..f20a65903 100644
--- a/src/script/common/c_content.cpp
+++ b/src/script/common/c_content.cpp
@@ -1063,8 +1063,7 @@ void push_flags_string(lua_State *L, FlagDesc *flagdesc, u32 flags, u32 flagmask
/******************************************************************************/
/******************************************************************************/
-void read_groups(lua_State *L, int index,
- std::map<std::string, int> &result)
+void read_groups(lua_State *L, int index, ItemGroupList &result)
{
if (!lua_istable(L,index))
return;
@@ -1083,11 +1082,10 @@ void read_groups(lua_State *L, int index,
}
/******************************************************************************/
-void push_groups(lua_State *L, const std::map<std::string, int> &groups)
+void push_groups(lua_State *L, const ItemGroupList &groups)
{
lua_newtable(L);
- std::map<std::string, int>::const_iterator it;
- for (it = groups.begin(); it != groups.end(); ++it) {
+ for (ItemGroupList::const_iterator it = groups.begin(); it != groups.end(); ++it) {
lua_pushnumber(L, it->second);
lua_setfield(L, -2, it->first.c_str());
}