Lua Game Objects/Player: Difference between revisions

From Civilization Modding Wiki
Jump to navigationJump to search
No edit summary
No edit summary
Line 3: Line 3:


==Methods==
==Methods==
*[[AcquireCity]]
*[[AddCityName]]
*[[AddFreeUnit]]
*[[AddNotification]]
*[[AI_foundValue]]
*[[AI_updateFoundValues]]
*[[CalculateGoldRate]]
*[[CalculateGoldRateTimes100]]
*[[CalculateGrossGold]]
*[[CalculateGrossGoldTimes100]]
*[[CalculateInflatedCosts]]
*[[CalculateResearchModifier]]
*[[CalculateTotalYield]]
*[[CalculateUnitCost]]
*[[CalculateUnitSupply]]
*[[CanAdoptPolicy]]
*[[CanBuild]]
*[[CanConstruct]]
*[[CanContact]]
*[[CanCreate]]
*[[CanEverResearch]]
*[[CanFound]]
*[[CanMaintain]]
*[[CanPrepare]]
*[[CanRaze]]
*[[CanReceiveGoody]]
*[[CanResearch]]
*[[CanStopTradingWithTeam]]
*[[CanTradeWith]]
*[[CanTrain]]
*[[CanUnlockPolicyBranch]]
*[[ChangeAdvancedStartPoints]]
*[[ChangeAlwaysSeeBarbCampsCount]]
*[[ChangeAnarchyNumTurns]]
*[[ChangeBarbarianCombatBonus]]
*[[ChangeBaseBuildingGoldMaintenance]]
*[[ChangeCombatExperience]]
*[[ChangeConscriptCount]]
*[[ChangeExtraHappinessPerCity]]
*[[ChangeGold]]
*[[ChangeGoldenAgeProgressMeter]]
*[[ChangeGoldenAgeTurns]]
*[[ChangeGoldPerUnitTimes100]]
*[[ChangeHappinessFromBuildings]]
*[[ChangeHappinessFromGarrisonedUnits]]
*[[ChangeHappinessPerGarrisonedUnit]]
*[[ChangeHappinessPerTradeRoute]]
*[[ChangeJONSCulture]]
*[[ChangeJONSCulturePerTurnForFree]]
*[[ChangeJONSCulturePerTurnFromMinorCivs]]
*[[ChangeMinorCivFriendshipWithMajor]]
*[[ChangeNumFreePolicies]]
*[[ChangeNumGoldenAges]]
*[[ChangeNumPlotsBought]]
*[[ChangeNumResourceTotal]]
*[[ChangeNumUnitGoldenAges]]
*[[ChangeUnhappinessFromUnits]]
*[[ChooseTech]]
*[[Cities]]
*[[ClearResearchQueue]]
*[[Contact]]
*[[CountCityFeatures]]
*[[CountNumBuildings]]
*[[CreateGreatGeneral]]
*[[Disband]]
*[[DisbandUnit]]
*[[DoAdoptPolicy]]
*[[DoBeginDiploWithHuman]]
*[[DoForceDenounce]]
*[[DoForceDoF]]
*[[DoGoody]]
*[[DoGreatPersonChoice]]
*[[DoMinorLiberationByMajor]]
*[[DoTradeScreenClosed]]
*[[DoTradeScreenOpened]]
*[[DoUpdateProximityToPlayer]]
*[[FindNewCapital]]
*[[FindPathLength]]
*[[ForcePeace]]
*[[Found]]
*[[GetActiveQuestForPlayer]]
*[[GetAdvancedStartBuildingCost]]
*[[GetAdvancedStartCityCost]]
*[[GetAdvancedStartImprovementCost]]
*[[GetAdvancedStartPoints]]
*[[GetAdvancedStartPopCost]]
*[[GetAdvancedStartRouteCost]]
*[[GetAdvancedStartTechCost]]
*[[GetAdvancedStartUnitCost]]
*[[GetAdvancedStartVisibilityCost]]
*[[GetAgricultureHistory]]
*[[GetAlly]]
*[[GetAnarchyNumTurns]]
*[[GetAnyUnitHasOrderToGoody]]
*[[GetApproachTowardsUsGuess]]
*[[GetArtStyleType]]
*[[GetAttackBonusTurns]]
*[[GetAveragePopulation]]
*[[GetBarbarianCombatBonus]]
*[[GetBestRoute]]
*[[GetBranchPicked1]]
*[[GetBranchPicked2]]
*[[GetBranchPicked3]]
*[[GetBuildingClassCount]]
*[[GetBuildingClassCountPlusMaking]]
*[[GetBuildingClassMaking]]
*[[GetBuildingClassPrereqBuilding]]
*[[GetBuildingGoldMaintenance]]
*[[GetBuildingProductionNeeded]]
*[[GetBuyPlotCost]]
*[[GetCapitalCity]]
*[[GetCapitalUnhappinessMod]]
*[[GetCapitalYieldRateModifier]]
*[[GetCitiesLost]]
*[[GetCityByID]]
*[[GetCityConnectionGold]]
*[[GetCityConnectionGoldTimes100]]
*[[GetCityCountUnhappinessMod]]
*[[GetCityDefenseModifier]]
*[[GetCityName]]
*[[GetCivilizationAdjective]]
*[[GetCivilizationAdjectiveKey]]
*[[GetCivilizationDescription]]
*[[GetCivilizationDescriptionKey]]
*[[GetCivilizationShortDescription]]
*[[GetCivilizationShortDescriptionKey]]
*[[GetCivilizationType]]
*[[GetClosestGoodyPlot]]
*[[GetCombatExperience]]
*[[GetConscriptCount]]
*[[GetConversionTimer]]
*[[GetCoopWarAcceptedState]]
*[[GetCultureBombTimer]]
*[[GetCultureCityModifier]]
*[[GetCultureWonderMultiplier]]
*[[GetCurrentCapitalFoodBonus]]
*[[GetCurrentCultureBonus]]
*[[GetCurrentEra]]
*[[GetCurrentOtherCityFoodBonus]]
*[[GetCurrentResearch]]
*[[GetCurrentScienceFriendshipBonusTimes100]]
*[[GetCurrentSpawnEstimate]]
*[[GetDomesticGreatGeneralRateModifier]]
*[[GetDominantPolicyBranchForTitle]]
*[[GetEconomyHistory]]
*[[GetEndTurnBlockingNotificationIndex]]
*[[GetEndTurnBlockingType]]
*[[GetEverPoppedGoody]]
*[[GetEverTrainedBuilder]]
*[[GetExcessHappiness]]
*[[GetExpInBorderModifier]]
*[[GetExtraHappinessPerCity]]
*[[GetExtraHappinessPerLuxury]]
*[[GetExtraUnitCost]]
*[[GetExtraYieldThreshold]]
*[[GetFeatureProductionModifier]]
*[[GetFirstReadyUnit]]
*[[GetFirstReadyUnitPlot]]
*[[GetFreeExperience]]
*[[GetFriendshipChangePerTurnTimes100]]
*[[GetFriendshipFromGoldGift]]
*[[GetFriendshipNeededForNextLevel]]
*[[GetGold]]
*[[GetGoldenAgeLength]]
*[[GetGoldenAgeModifier]]
*[[GetGoldenAgeProgressMeter]]
*[[GetGoldenAgeProgressThreshold]]
*[[GetGoldenAgeTurns]]
*[[GetGoldFromCitiesTimes100]]
*[[GetGoldPerMilitaryUnit]]
*[[GetGoldPerTurnFromDiplomacy]]
*[[GetGoldPerUnit]]
*[[GetGreatGeneralRateModifier]]
*[[GetGreatGeneralsCreated]]
*[[GetGreatGeneralsThresholdModifier]]
*[[GetGreatPeopleCreated]]
*[[GetGreatPeopleRateModifier]]
*[[GetGreatPeopleThresholdModifier]]
*[[GetHandicapType]]
*[[GetHappiness]]
*[[GetHappinessFromBuildings]]
*[[GetHappinessFromGarrisonedUnits]]
*[[GetHappinessFromMinor]]
*[[GetHappinessFromNaturalWonders]]
*[[GetHappinessFromPolicies]]
*[[GetHappinessFromReligion]]
*[[GetHappinessFromResources]]
*[[GetHappinessFromResourceVariety]]
*[[GetHappinessFromTradeRoutes]]
*[[GetHappinessPerGarrisonedUnit]]
*[[GetHappinessPerTradeRoute]]
*[[GetHappyPerMilitaryUnit]]
*[[GetHighestUnitLevel]]
*[[GetHurryCount]]
*[[GetHurryGoldCost]]
*[[GetHurryModifier]]
*[[GetID]]
*[[GetImprovementCount]]
*[[GetImprovementGoldMaintenance]]
*[[GetImprovementUpgradeRate]]
*[[GetImprovementUpgradeRateModifier]]
*[[GetIndustryHistory]]
*[[GetJONSCulture]]
*[[GetJONSCulturePerTurnForFree]]
*[[GetJONSCulturePerTurnFromCities]]
*[[GetJONSCulturePerTurnFromExcessHappiness]]
*[[GetJONSCulturePerTurnFromMinorCivs]]
*[[GetLandDisputeLevel]]
*[[GetLandScore]]
*[[GetLeaderType]]
*[[GetLengthResearchQueue]]
*[[GetLevelExperienceModifier]]
*[[GetMaxConscript]]
*[[GetMaxGlobalBuildingProductionModifier]]
*[[GetMaxPlayerBuildingProductionModifier]]
*[[GetMaxTeamBuildingProductionModifier]]
*[[GetMilitaryMight]]
*[[GetMilitaryProductionModifier]]
*[[GetMinorCivCultureFriendshipBonus]]
*[[GetMinorCivDisputeLevel]]
*[[GetMinorCivFavoriteMajor]]
*[[GetMinorCivFriendshipLevelWithMajor]]
*[[GetMinorCivFriendshipWithMajor]]
*[[GetMinorCivHappinessFriendshipBonus]]
*[[GetMinorCivScienceFriendshipBonus]]
*[[GetMinorCivTrait]]
*[[GetMinorCivType]]
*[[GetMinorWarQuestWithMajorRemainingCount]]
*[[GetName]]
*[[GetNameKey]]
*[[GetNewCityName]]
*[[GetNextCity]]
*[[GetNextPolicyCost]]
*[[GetNickName]]
*[[GetNotificationDismissed]]
*[[GetNotificationIndex]]
*[[GetNotificationStr]]
*[[GetNotificationSummaryStr]]
*[[GetNotificationTurn]]
*[[GetNumCities]] - returns number of cities
*[[GetNumCityNames]]
*[[GetNumCiviliansReturned]]
*[[GetNumFreePolicies]]
*[[GetNumFreeTechs]]
*[[GetNumGoldenAges]]
*[[GetNumMaintenanceFreeUnits]]
*[[GetNumMilitaryUnits]]
*[[GetNumMinorCivsMet]]
*[[GetNumNotifications]]
*[[GetNumNukeUnits]]
*[[GetNumOutsideUnits]]
*[[GetNumPlots]]
*[[GetNumPlotsBought]]
*[[GetNumPolicies]]
*[[GetNumPolicyBranchesAllowed]]
*[[GetNumPolicyBranchesFinished]]
*[[GetNumPolicyBranchesUnlocked]]
*[[GetNumResourceAvailable]]
*[[GetNumResourceTotal]]
*[[GetNumResourceUsed]]
*[[GetNumTimesCultureBombed]]
*[[GetNumTradeResourceImports]]
*[[GetNumUnitGoldenAges]]
*[[GetNumUnits]]
*[[GetNumUnitsOutOfSupply]]
*[[GetNumUnitsSupplied]]
*[[GetNumUnitsSuppliedByCities]]
*[[GetNumUnitsSuppliedByHandicap]]
*[[GetNumUnitsSuppliedByPopulation]]
*[[GetNumWorldWonders]]
*[[GetOccupiedPopulationUnhappinessMod]]
*[[GetOtherPlayerNumProtectedMinorsKilled]]
*[[GetOverflowResearch]]
*[[GetPersonality]]
*[[GetPersonalityType]]
*[[GetPlayerColor]]
*[[GetPlayerColors]]
*[[GetPlayerVisiblePlot]]
*[[GetPlotDanger]]
*[[GetPlotHasOrder]]
*[[GetPolicyBranchChosen]]
*[[GetPopScore]]
*[[GetPower]]
*[[GetPowerHistory]]
*[[GetPrevCity]]
*[[GetProductionModifier]]
*[[GetProjectProductionNeeded]]
*[[GetProximityToPlayer]]
*[[GetQuestData1]]
*[[GetQuestData2]]
*[[GetQueuePosition]]
*[[GetRealPopulation]]
*[[GetRecommendedFoundCityPlots]]
*[[GetRecommendedWorkerPlots]]
*[[GetResearchTurnsLeft]]
*[[GetResourceExport]]
*[[GetResourceFromMinors]]
*[[GetResourceImport]]
*[[GetRouteGoldTimes100]]
*[[GetScience]]
*[[GetScienceFromBudgetDeficitTimes100]]
*[[GetScienceFromCitiesTimes100]]
*[[GetScienceFromHappinessTimes100]]
*[[GetScienceFromOtherPlayersTimes100]]
*[[GetScienceFromResearchAgreementsTimes100]]
*[[GetScienceTimes100]]
*[[GetScore]]
*[[GetScoreFromCities]]
*[[GetScoreFromFutureTech]]
*[[GetScoreFromLand]]
*[[GetScoreFromPopulation]]
*[[GetScoreFromTechs]]
*[[GetScoreFromWonders]]
*[[GetScoreHistory]]
*[[GetScriptData]]
*[[GetSeaPlotYield]]
*[[GetSettlerProductionModifier]]
*[[GetSpaceProductionModifier]]
*[[GetSpecialistExtraYield]]
*[[GetStartingPlot]]
*[[GetStateReligionKey]]
*[[GetStateReligionName]]
*[[GetStrikeTurns]]
*[[GetTeam]]
*[[GetTechScore]]
*[[GetTotalJONSCulturePerTurn]]
*[[GetTotalLand]]
*[[GetTotalLandScored]]
*[[GetTotalPopulation]]
*[[GetTotalTimePlayed]]
*[[GetTraitCityStateCombatModifier]]
*[[GetTraitCityUnhappinessMod]]
*[[GetTraitGoldenAgeCombatModifier]]
*[[GetTraitGreatGeneralExtraBonus]]
*[[GetTraitGreatScientistRateModifier]]
*[[GetTraitPopUnhappinessMod]]
*[[GetTurnsSinceThreatenedByBarbarians]]
*[[GetUnhappiness]]
*[[GetUnhappinessForecast]]
*[[GetUnhappinessFromCapturedCityCount]]
*[[GetUnhappinessFromCityCount]]
*[[GetUnhappinessFromCityForUI]]
*[[GetUnhappinessFromCityPopulation]]
*[[GetUnhappinessFromOccupiedCities]]
*[[GetUnhappinessFromUnits]]
*[[GetUnhappinessMod]]
*[[GetUnimprovedAvailableLuxuryResource]]
*[[GetUnitByID]]
*[[GetUnitClassCount]]
*[[GetUnitClassCountPlusMaking]]
*[[GetUnitClassMaking]]
*[[GetUnitProductionMaintenanceMod]]
*[[GetUnitProductionNeeded]]
*[[GetVictoryDisputeLevel]]
*[[GetVotes]]
*[[GetWarmongerThreat]]
*[[GetWonderDisputeLevel]]
*[[GetWonderProductionModifier]]
*[[GetWondersScore]]
*[[GetWorkerSpeedModifier]]
*[[GetWorstEnemyName]]
*[[GetYieldRateModifier]]
*[[GreatGeneralThreshold]]
*[[HasBusyMovingUnit]]
*[[HasBusyUnit]]
*[[HasPolicy]]
*[[HasReadyUnit]]
*[[HasReceivedNetTurnComplete]]
*[[InitCity]]
*[[InitUnit]]
*[[IsAlive]]
*[[IsAllies]]
*[[IsAlwaysSeeBarbCamps]]
*[[IsAnarchy]]
*[[IsAnyGoodyPlotAccessible]]
*[[IsAnyPlotImproved]]
*[[IsBarbarian]]
*[[IsBuildBlockedByFeature]]
*[[IsBuildingClassMaxedOut]]
*[[IsBuildingFree]]
*[[IsCanHurry]]
*[[IsCapitalConnectedToCity]]
*[[IsCurrentResearchRepeat]]
*[[IsDemandEverMade]]
*[[IsDenouncedPlayer]]
*[[IsDontSettleMessageTooSoon]]
*[[IsEmpireUnhappy]]
*[[IsEmpireVeryUnhappy]]
*[[IsEverAlive]]
*[[IsExtendedGame]]
*[[IsFoundedFirstCity]]
*[[IsFriends]]
*[[IsFullMember]]
*[[IsGoldenAge]]
*[[IsHalfSpecialistUnhappiness]]
*[[IsHasAccessToHurry]]
*[[IsHasLostCapital]]
*[[IsHuman]]
*[[IsLoyalMember]]
*[[IsMilitaryFoodProduction]]
*[[IsMinorCiv]] - returns true if this player is a city-state.
*[[IsMinorCivRouteEstablishedWithMajor]]
*[[IsMinorCivUnitSpawningDisabled]]
*[[IsMinorPermanentWar]]
*[[IsMinorWarQuestWithMajorActive]]
*[[IsNoResearchAvailable]]
*[[IsOption]]
*[[IsPeaceBlocked]]
*[[IsPlayable]]
*[[IsPlayerBrokenBorderPromise]]
*[[IsPlayerBrokenCityStatePromise]]
*[[IsPlayerBrokenCoopWarPromise]]
*[[IsPlayerBrokenExpansionPromise]]
*[[IsPlayerBrokenMilitaryPromise]]
*[[IsPlayerHasOpenBorders]]
*[[IsPlayerHasOpenBordersAutomatically]]
*[[IsPlayerIgnoredBorderPromise]]
*[[IsPlayerIgnoredCityStatePromise]]
*[[IsPlayerIgnoredExpansionPromise]]
*[[IsPlayerIgnoredMilitaryPromise]]
*[[IsPlayerNoSettleRequestEverAsked]]
*[[IsPlayerRecklessExpander]]
*[[IsPolicyBlocked]]
*[[IsPolicyBranchBlocked]]
*[[IsPolicyBranchFinished]]
*[[IsPolicyBranchUnlocked]]
*[[IsProductionMaxedBuildingClass]]
*[[IsProductionMaxedProject]]
*[[IsProductionMaxedUnitClass]]
*[[IsProtectingMinor]]
*[[IsResearch]]
*[[IsResearchingTech]]
*[[IsStrike]]
*[[IsTurnActive]]
*[[IsUnitClassMaxedOut]]
*[[IsVotingMember]]
*[[IsWhiteFlag]]
*[[IsWillAcceptPeaceWithPlayer]]
*[[IsWorkingAgainstPlayerAccepted]]
*[[IsWorkingWithPlayer]]
*[[IsWorkingWithPlayerMessageTooSoon]]
*[[KillCities]]
*[[KillUnits]]
*[[PopResearch]]
*[[PushResearch]]
*[[Raze]]
*[[ReceiveGoody]]
*[[RemoveBuildingClass]]
*[[SetAdvancedStartPoints]]
*[[SetAlwaysSeeBarbCampsCount]]
*[[SetAnarchyNumTurns]]
*[[SetBarbarianCombatBonus]]
*[[SetBaseBuildingGoldMaintenance]]
*[[SetCombatExperience]]
*[[SetConscriptCount]]
*[[SetGold]]
*[[SetGoldenAgeProgressMeter]]
*[[SetHappiness|SetHappiness ( iHappiness )]] - supposed to set player's happiness, '''does not work'''
*[[SetHappiness|SetHappiness ( iHappiness )]] - supposed to set player's happiness, '''does not work'''
*[[SetHappinessPerGarrisonedUnit]]
*[[SetHappinessPerTradeRoute]]
*[[SetHasPolicy]]
*[[SetJONSCulture]]
*[[SetLoyalMember]]
*[[SetNumFreePolicies]]
*[[SetNumFreeTechs]]
*[[SetNumGoldenAges]]
*[[SetNumPlotsBought]]
*[[SetOption]]
*[[SetPersonalityType]]
*[[SetPlayable]]
*[[SetPolicyBranchUnlocked]]
*[[SetResearchingTech]]
*[[SetScriptData]]
*[[SetStartingPlot]]
*[[SpecialistYield]]
*[[StopTradingWithTeam]]
*[[Units]]
*[[UnitsGoldenAgeCapable]]
*[[UnitsGoldenAgeReady]]
*[[UnitsRequiredForGoldenAge]]





Revision as of 13:31, 14 February 2012

Up: Lua Game Objects


Methods


Complete list in official wiki: http://wiki.2kgames.com/civ5/index.php/Lua_Game_Objects/Player


Related Events