diff options
-rw-r--r-- | src/scripting/lua.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/scripting/lua.cpp b/src/scripting/lua.cpp index ae9ba936..a07b287c 100644 --- a/src/scripting/lua.cpp +++ b/src/scripting/lua.cpp @@ -1791,9 +1791,9 @@ static int chr_get_hair_color(lua_State *s) static int chr_get_kill_count(lua_State *s) { Character *c = checkCharacter(s, 1); - const int id = luaL_checkint(s, 2); + MonsterClass *monster = checkMonsterClass(s, 2); - lua_pushinteger(s, c->getKillCount(id)); + lua_pushinteger(s, c->getKillCount(monster->getId())); return 1; } |