Bazaar developer reference

CvLuaGame::RegisterMembers(lua_State *)

Defined in
Lua/CvLuaGame.cpp, line 50
Class
CvLuaGame
Hook name
CivHooks::CvLuaGame_RegisterMembers
Changed in
0.5.0

Hooks

static bool BeforeCvLuaGame_RegisterMembers(lua_State* L);static void AfterCvLuaGame_RegisterMembers(lua_State* L);static void ReplaceCvLuaGame_RegisterMembers(void (*original)(lua_State*), lua_State* L);CivRegisterBefore<CivHooks::CvLuaGame_RegisterMembers>(host, &BeforeCvLuaGame_RegisterMembers);CivRegisterAfter<CivHooks::CvLuaGame_RegisterMembers>(host, &AfterCvLuaGame_RegisterMembers);CivRegisterReplace<CivHooks::CvLuaGame_RegisterMembers>(host, &ReplaceCvLuaGame_RegisterMembers);

Code

50void CvLuaGame::RegisterMembers(lua_State* L)51{52	Method(CanHandleAction);53	Method(HandleAction);54	Method(UpdateScore);55	Method(CycleCities);56	Method(CycleUnits);57	Method(CyclePlotUnits);5859	Method(SelectionListMove);60	Method(SelectionListGameNetMessage);61	Method(SelectedCitiesGameNetMessage);62	Method(CityPushOrder);63	Method(CityPurchaseUnit);64	Method(CityPurchaseBuilding);65	Method(CityPurchaseProject);6667	Method(GetProductionPerPopulation);6869	Method(GetAdjustedPopulationPercent);70	Method(GetAdjustedLandPercent);7172	Method(GetUnitedNationsCountdown);73	Method(SetUnitedNationsCountdown);7475	Method(CountCivPlayersAlive);76	Method(CountCivPlayersEverAlive);77	Method(CountCivTeamsAlive);78	Method(CountCivTeamsEverAlive);79	Method(CountHumanPlayersAlive);80	Method(CountHumanPlayersEverAlive);8182	Method(CountTotalCivPower);83	Method(CountTotalNukeUnits);84	Method(CountKnownTechNumTeams);8586	Method(GoldenAgeLength);87	Method(VictoryDelay);88	Method(GetImprovementUpgradeTime);89	Method(CanTrainNukes);9091	Method(GetCurrentEra);9293	Method(GetDiploResponse);9495	Method(GetActiveTeam);96	Method(GetActiveCivilizationType);97	Method(IsNetworkMultiPlayer);98	Method(IsGameMultiPlayer);99	Method(IsTeamGame);100101	Method(ReviveActivePlayer);102103	Method(GetNumHumanPlayers);104	Method(GetNumSequentialHumans);105	Method(GetGameTurn);106	Method(SetGameTurn);107	Method(GetTurnYear);108	Method(GetGameTurnYear);109	Method(GetTurnString);110#if defined(MOD_API_LUA_EXTENSIONS)111	Method(GetDateString);112#endif113114	Method(GetElapsedGameTurns);115	Method(GetMaxTurns);116	Method(SetMaxTurns);117	Method(ChangeMaxTurns);118	Method(GetMaxCityElimination);119	Method(SetMaxCityElimination);120	Method(GetNumAdvancedStartPoints);121	Method(SetNumAdvancedStartPoints);122	Method(GetStartTurn);123	Method(GetWinningTurn);124	Method(GetStartYear);125	Method(SetStartYear);126	Method(GetEstimateEndTurn);127	Method(SetEstimateEndTurn);128	Method(GetTurnSlice);129	Method(GetMinutesPlayed);130	Method(GetTargetScore);131	Method(SetTargetScore);132133	Method(IsStaticTutorialActive);134	Method(SetStaticTutorialActive);135	Method(IsEverRightClickMoved);136	Method(SetEverRightClickMoved);137138	Method(IsTutorialLogging);139	Method(IsTutorialDebugging);140	Method(GetTutorialLevel);141142	Method(HasAdvisorMessageBeenSeen);143	Method(SetAdvisorMessageHasBeenSeen);144145	Method(SetAdvisorBadAttackInterrupt);146	Method(SetAdvisorCityAttackInterrupt);147148	Method(GetAllowRClickMovementWhileScrolling);149150	Method(GetNumGameTurnActive);151	Method(CountNumHumanGameTurnActive);152	Method(GetNumCities);153	Method(GetNumCivCities);154	Method(GetTotalPopulation);155156	Method(GetNoNukesCount);157	Method(IsNoNukes);158	Method(ChangeNoNukesCount);159	Method(GetNukesExploded);160	Method(ChangeNukesExploded);161162	Method(GetMaxPopulation);163	Method(GetInitPopulation);164	Method(GetInitLand);165	Method(GetInitTech);166	Method(GetInitWonders);167	Method(GetNumWorldWonders);168169	Method(GetAIAutoPlay);170	Method(SetAIAutoPlay);171172	Method(IsScoreDirty);173	Method(SetScoreDirty);174	Method(IsCircumnavigated);175	Method(MakeCircumnavigated);176177	Method(DoFromUIDiploEvent);178179	Method(IsDebugMode);180	Method(SetDebugMode);181	Method(ToggleDebugMode);182	Method(UpdateFOW);183184	Method(GetPitbossTurnTime);185	Method(SetPitbossTurnTime);186	Method(IsHotSeat);187	Method(IsPbem);188	Method(IsPitboss);189	Method(IsSimultaneousTeamTurns);190191	Method(IsFinalInitialized);192193	Method(GetActivePlayer);194	Method(SetActivePlayer);195	Method(GetPausePlayer);196	Method(SetPausePlayer);197	Method(IsPaused);198	Method(GetBestLandUnit);199	Method(GetBestLandUnitCombat);200201	Method(GetFaithCost);202203	Method(GetWinner);204	Method(GetVictory);205	Method(SetWinner);206	Method(GetGameState);207	Method(SetGameState);208209	Method(GetVotesNeededForDiploVictory);210	Method(IsUnitedNationsActive);211212	Method(GetNumVictoryVotesTallied);213	Method(GetVoteCast);214	Method(GetPreviousVoteCast);215	Method(GetNumVotesForTeam);216	Method(SetNumVotesForTeam);217	Method(ChangeNumVotesForTeam);218219	Method(GetHandicapType);220	Method(GetCalendar);221	Method(GetStartEra);222	Method(GetGameSpeedType);223	Method(GetRankPlayer);224	Method(GetPlayerRank);225	Method(GetPlayerScore);226	Method(GetRankTeam);227	Method(GetTeamRank);228	Method(GetTeamScore);229	Method(IsOption);230	Method(SetOption);231	Method(IsMPOption);232	Method(GetUnitCreatedCount);233	Method(GetUnitClassCreatedCount);234	Method(IsUnitClassMaxedOut);235	Method(GetBuildingClassCreatedCount);236	Method(IsBuildingClassMaxedOut);237238	Method(GetProjectCreatedCount);239	Method(IsProjectMaxedOut);240241	Method(IsVictoryValid);242	Method(SetVictoryValid);243	Method(IsSpecialUnitValid);244	Method(MakeSpecialUnitValid);245	Method(IsNukesValid);246	Method(MakeNukesValid);247	Method(IsInAdvancedStart);248249	Method(SetName);250	Method(GetName);251	Method(Rand);252	Method(CalculateSyncChecksum);253	Method(CalculateOptionsChecksum);254255	Method(GetReplayMessage);256	Method(GetReplayMessages);257	Method(GetNumReplayMessages);258	Method(GetReplayInfo);259260	Method(SaveReplay);261262	Method(AddPlayer);263264	Method(SetPlotExtraYield);265	Method(ChangePlotExtraCost);266267	Method(IsCivEverActive);268	Method(IsLeaderEverActive);269	Method(IsUnitEverActive);270	Method(IsBuildingEverActive);271272	Method(CanDoControl);273	Method(DoControl);274275	Method(DoMinorPledgeProtection);276	Method(DoMinorGoldGift);277	Method(DoMinorGiftGold);278	Method(DoMinorGiftTileImprovement);279	Method(DoMinorBullyGold);280	Method(DoMinorBullyUnit);281	Method(DoMinorBuyout);282283	Method(GetBestWondersPlayer);284	Method(GetBestPoliciesPlayer);285	Method(GetBestGreatPeoplePlayer);286287	Method(IsEverAttackedTutorial);288289	Method(GameplayDiplomacyAILeaderMessage);290291	Method(GetResourceUsageType);292293	Method(GetNumResourceRequiredForUnit);294	Method(GetNumResourceRequiredForBuilding);295296	Method(IsCombatWarned);297	Method(SetCombatWarned);298299	Method(GetAdvisorCounsel);300	Method(SetAdvisorRecommenderCity);301302	Method(IsUnitRecommended);303	Method(IsBuildingRecommended);304	Method(IsProjectRecommended);305306	Method(SetAdvisorRecommenderTech);307	Method(IsTechRecommended);308309	Method(GetVariableCitySizeFromPopulation);310311	Method(GetResearchAgreementCost);312313	Method(GetCustomOption);314315	Method(GetNumCitiesPolicyCostMod);316	Method(GetNumCitiesTechCostMod);317318	Method(GetBuildingYieldChange);319	Method(GetBuildingYieldModifier);320321	Method(GetWorldNumCitiesUnhappinessPercent);322323	Method(GetDealDuration);324	Method(GetPeaceDuration);325326	Method(GetUnitUpgradesTo);327328	Method(GetCombatPrediction);329330	Method(GetTimeString);331332	Method(GetMinimumFaithNextPantheon);333	Method(SetMinimumFaithNextPantheon);334335#if defined(MOD_API_LUA_EXTENSIONS) && defined(MOD_API_RELIGION)336	Method(IsInSomeReligion);337#endif338	Method(GetAvailablePantheonBeliefs);339	Method(GetAvailableFounderBeliefs);340	Method(GetAvailableFollowerBeliefs);341	Method(GetAvailableEnhancerBeliefs);342	Method(GetAvailableBonusBeliefs);343	Method(GetAvailableReformationBeliefs);344345	Method(GetNumFollowers);346	Method(GetNumCitiesFollowing);347348	Method(GetBeliefsInReligion);349	Method(GetNumReligionsStillToFound);350	Method(GetNumReligionsFounded);351	Method(GetHolyCityForReligion);352	Method(GetReligionName);353	Method(GetFounderBenefitsReligion);354355	Method(FoundPantheon);356#if defined(MOD_API_LUA_EXTENSIONS) && defined(MOD_API_RELIGION)357	Method(EnhancePantheon);358#endif359	Method(FoundReligion);360	Method(EnhanceReligion);361#if defined(MOD_API_LUA_EXTENSIONS)362	Method(AddReformation);363#endif364	Method(SetHolyCity);365	Method(GetFounder);366	Method(SetFounder);367368	Method(GetTurnsBetweenMinorCivElections);369	Method(GetTurnsUntilMinorCivElection);370371	Method(GetNumActiveLeagues);372	Method(GetNumLeaguesEverFounded);373	Method(GetLeague);374	Method(GetActiveLeague);375376#if defined(MOD_API_LUA_EXTENSIONS)377	Method(IsAchievementUnlocked);378	Method(GetSteamStat);379#endif380381	Method(IsProcessingMessages);382383#if defined(MOD_API_LUA_EXTENSIONS)384	Method(CreateGreatWork);385#endif386	Method(GetGreatWorkTooltip);387	Method(GetGreatWorkName);388	Method(GetGreatWorkType);389	Method(GetGreatWorkClass);390	Method(GetGreatWorkArtist);391	Method(GetGreatWorkEra);392	Method(GetGreatWorkEraAbbreviation);393	Method(GetGreatWorkEraShort);394	Method(GetGreatWorkCreator);395	Method(GetGreatWorkController);396	Method(GetGreatWorkCurrentThemingBonus);397	Method(GetArtifactName);398399	Method(GetNumFreePolicies);400401	Method(GetLongestCityConnectionPlots);402403#if defined(MOD_API_LUA_EXTENSIONS) && defined(MOD_API_TRADEROUTES)404	Method(GetTradeRoute);405#endif406	Method(SelectedUnit_SpeculativePopupTradeRoute_Display);407	Method(SelectedUnit_SpeculativePopupTradeRoute_Hide);408	Method(MouseoverUnit);409410	Method(GetNumArchaeologySites);411	Method(GetNumHiddenArchaeologySites);412413#if defined(MOD_API_LUA_EXTENSIONS) && defined(MOD_API_EXTENSIONS)414	Method(ExitLeaderScreen);415#endif416417#if defined(MOD_API_LUA_EXTENSIONS)418	Method(GetDllGuid);419	Method(ReloadGameDataDefines);420	Method(ReloadCustomModOptions);421	Method(IsCustomModOption);422	Method(GetCustomModOption);423	Method(SpewTestEvents);424#endif425426#if defined(MOD_API_LUA_EXTENSIONS)427	Method(AnyoneHasBelief);428	Method(AnyoneHasBuilding);429	Method(AnyoneHasBuildingClass);430	Method(AnyoneHasAnyWonder);431	Method(AnyoneHasWonder);432	Method(GetCivilizationPlayer);433	Method(AnyoneIsInEra);434	Method(AnyoneHasReachedEra);435	Method(AnyoneHasAnyNaturalWonder);436	Method(AnyoneHasNaturalWonder);437	Method(AnyoneHasPolicy);438	Method(AnyoneHasTenet);439	Method(AnyoneHasPolicyBranch);440	Method(AnyoneHasIdeology);441	Method(AnyoneHasProject);442	Method(AnyoneHasPantheon);443	Method(AnyoneHasAnyReligion);444	Method(AnyoneHasReligion);445	Method(IsResolutionPassed);446	Method(AnyoneHasTech);447	Method(AnyoneHasUnit);448	Method(AnyoneHasUnitClass);449#endif450#if defined(CIV_HOST_API)451	RegisterMethod(L, &CivHostLuaGetPluginValue, "GetPluginValue");452#endif453}

Calls