Bazaar developer reference

CvLuaUnit::lIsDead(lua_State *)

Defined in
Lua/CvLuaUnit.cpp, line 2348
Class
CvLuaUnit
Hook name
CivHooks::CvLuaUnit_lIsDead

Hooks

static bool BeforeCvLuaUnit_lIsDead(lua_State* L, int& result);static void AfterCvLuaUnit_lIsDead(lua_State* L, int& result);static int ReplaceCvLuaUnit_lIsDead(int (*original)(lua_State*), lua_State* L);CivRegisterBefore<CivHooks::CvLuaUnit_lIsDead>(host, &BeforeCvLuaUnit_lIsDead);CivRegisterAfter<CivHooks::CvLuaUnit_lIsDead>(host, &AfterCvLuaUnit_lIsDead);CivRegisterReplace<CivHooks::CvLuaUnit_lIsDead>(host, &ReplaceCvLuaUnit_lIsDead);

Code

2347//bool isDead();2348int CvLuaUnit::lIsDead(lua_State* L)2349{2350	CvUnit* pkUnit = GetInstance(L);2351	const bool bResult = pkUnit->IsDead();23522353	lua_pushboolean(L, bResult);2354	return 1;2355}

Calls

Called by