Attempt to fix some errors reported by @singalen

This commit is contained in:
Charles Dang 2017-02-27 18:52:10 +11:00
parent 897c242ca5
commit f81392893d
2 changed files with 2 additions and 1 deletions

View file

@ -34,7 +34,7 @@ local function add_animation(anim, cfg)
)
end
if unit and not wesnoth.is_fogged(wesnoth.current.side, u.loc) then
if unit and not wesnoth.is_fogged(wesnoth.current.side, unit.loc) then
local primary = helper.get_child(cfg, "primary_attack")
local secondary = helper.get_child(cfg, "secondary_attack")
local get_attack = get_real_attack

View file

@ -463,6 +463,7 @@ static int intf_create_animator(lua_State* L)
{"add", impl_add_animation},
{"run", impl_run_animation},
{"clear", impl_clear_animation},
{nullptr, nullptr},
};
luaL_setfuncs(L, metafuncs, 0);
lua_pushstring(L, "__metatable");