Bazaar developer reference

CvLuaPlot::lGetRevealedOwner(lua_State *)

Defined in
Lua/CvLuaPlot.cpp, line 1736
Class
CvLuaPlot
Hook name
CivHooks::CvLuaPlot_lGetRevealedOwner

Hooks

static bool BeforeCvLuaPlot_lGetRevealedOwner(lua_State* L, int& result);static void AfterCvLuaPlot_lGetRevealedOwner(lua_State* L, int& result);static int ReplaceCvLuaPlot_lGetRevealedOwner(int (*original)(lua_State*), lua_State* L);CivRegisterBefore<CivHooks::CvLuaPlot_lGetRevealedOwner>(host, &BeforeCvLuaPlot_lGetRevealedOwner);CivRegisterAfter<CivHooks::CvLuaPlot_lGetRevealedOwner>(host, &AfterCvLuaPlot_lGetRevealedOwner);CivRegisterReplace<CivHooks::CvLuaPlot_lGetRevealedOwner>(host, &ReplaceCvLuaPlot_lGetRevealedOwner);

Code

1735//PlayerTypes getRevealedOwner(TeamTypes eTeam, bool bDebug);1736int CvLuaPlot::lGetRevealedOwner(lua_State* L)1737{1738	CvPlot* pkPlot = GetInstance(L);1739	const TeamTypes eTeam = (TeamTypes)lua_tointeger(L, 2);1740	const bool bDebug = luaL_optbool(L, 3, false);17411742	if (!bDebug)1743		lua_pushinteger(L, pkPlot->getRevealedOwner(eTeam));1744	else1745		lua_pushinteger(L, pkPlot->getRevealedOwner(eTeam, true));17461747	return 1;1748}

Calls

Called by