<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://sleague.civfanatics.com/index.php?action=history&amp;feed=atom&amp;title=The_city_object</id>
	<title>The city object - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://sleague.civfanatics.com/index.php?action=history&amp;feed=atom&amp;title=The_city_object"/>
	<link rel="alternate" type="text/html" href="https://sleague.civfanatics.com/index.php?title=The_city_object&amp;action=history"/>
	<updated>2026-04-19T00:16:48Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.1</generator>
	<entry>
		<id>https://sleague.civfanatics.com/index.php?title=The_city_object&amp;diff=5098&amp;oldid=prev</id>
		<title>Prof. Garfield: Added to category lua resources</title>
		<link rel="alternate" type="text/html" href="https://sleague.civfanatics.com/index.php?title=The_city_object&amp;diff=5098&amp;oldid=prev"/>
		<updated>2019-01-26T20:09:44Z</updated>

		<summary type="html">&lt;p&gt;Added to category lua resources&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 20:09, 26 January 2019&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category: Resources]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Lua &lt;/ins&gt;Resources]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Back To [[TOTPP Functions]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Back To [[TOTPP Functions]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Prof. Garfield</name></author>
	</entry>
	<entry>
		<id>https://sleague.civfanatics.com/index.php?title=The_city_object&amp;diff=4994&amp;oldid=prev</id>
		<title>Prof. Garfield: Created City Object Page</title>
		<link rel="alternate" type="text/html" href="https://sleague.civfanatics.com/index.php?title=The_city_object&amp;diff=4994&amp;oldid=prev"/>
		<updated>2019-01-01T22:13:03Z</updated>

		<summary type="html">&lt;p&gt;Created City Object Page&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;[[Category: Resources]]&lt;br /&gt;
Back To [[TOTPP Functions]]&lt;br /&gt;
&lt;br /&gt;
[[city.id|id]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.id -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s id.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.name|name]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.name -&amp;gt; string&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s name.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.location|location]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.location -&amp;gt; tile&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s location. See the `relocate` method for a way to set this.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.size|size]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.size -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s size.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.attributes|attributes]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.attributes -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s attributes (bitmask).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.owner|owner]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.owner -&amp;gt; tribe&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s owner.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.originalOwner|originalOwner]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.originalOwner -&amp;gt; tribe&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s original owner. This can be different from `owner` if the city was captured in the past.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.turnsSinceCapture|turnsSinceCapture]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.turnsSinceCapture -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the number of turns since the city was last captured.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.knownTo|knownTo]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.knownTo -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns a bitmask indicating the tribes that have knowledge of this city.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.specialists|specialists]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.specialists -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the city&amp;#039;s specialists as a integer, 16 x 2 bits per specialist (0 - No specialist, 1 - Entertainer, 2 - Taxman, 3 - Scientist)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.food|food]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.food -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the quantity of food in store.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.shields|shields]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.shields -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the number of shields towards the current item in production.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.baseTrade|baseTrade]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.baseTrade -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the number of trade arrows before trade routes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.workers|workers]] (get/set)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.workers -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns a bitmask with the workers and specialists of the city.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.numTradeRoutes|numTradeRoutes]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.numTradeRoutes -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the number of trade routes of the city.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.science|science]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.science -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the amount of science the city produces.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.tax|tax]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.tax -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the amount of tax the city produces.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.totalTrade|totalTrade]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.totalTrade -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the total amount of trade arrows the city produces (including trade routes).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.totalFood|totalFood]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.totalFood -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the total amount of food the city produces.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.totalShield|totalShield]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.totalShield -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the total amount of shields the city produces.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.numHappy|numHappy]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.numHappy -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the number of happy citizens.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.numUnhappy|numUnhappy]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.numUnhappy -&amp;gt; integer&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the number of unhappy citizens.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city.coastal|coastal]] (get)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city.coastal -&amp;gt; boolean&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns whether or not the city is on a coast (can build coastal improvements).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city|addImprovement]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city:addImprovement(improvement)&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alias for `civ.addImprovement(city, improvement)`.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city|hasImprovement]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city:hasImprovement(improvement) -&amp;gt; boolean&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alias for `civ.hasImprovement(city, improvement)`.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city|removeImprovement]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city:removeImprovement(improvement)&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alias for `civ.removeImprovement(city, improvement)`.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city|relocate]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city:relocate(tile) -&amp;gt; boolean&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Relocates the city to the location given by `tile`. Returns `true` if successful, `false` otherwise (if a city is already present for example).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[city|canBuild]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;city:canBuild(item) -&amp;gt; boolean&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns whether or not `item` can currently be built in the city. `item` can be a unittype, improvement or wonder.&lt;/div&gt;</summary>
		<author><name>Prof. Garfield</name></author>
	</entry>
</feed>