<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://modiki.civfanatics.com/index.php?action=history&amp;feed=atom&amp;title=Map.Rand_%28Civ5_API%29</id>
	<title>Map.Rand (Civ5 API) - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://modiki.civfanatics.com/index.php?action=history&amp;feed=atom&amp;title=Map.Rand_%28Civ5_API%29"/>
	<link rel="alternate" type="text/html" href="https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;action=history"/>
	<updated>2026-04-21T12:14:19Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.1</generator>
	<entry>
		<id>https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;diff=16445&amp;oldid=prev</id>
		<title>Slserpent: more information</title>
		<link rel="alternate" type="text/html" href="https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;diff=16445&amp;oldid=prev"/>
		<updated>2014-02-05T09:19:02Z</updated>

		<summary type="html">&lt;p&gt;more information&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 09:19, 5 February 2014&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-l23&quot;&gt;Line 23:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 23:&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;|-&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;|-&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;|valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-right:6px;&amp;quot;|logEntry:&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;|valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-right:6px;&amp;quot;|logEntry:&lt;/div&gt;&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;|valign=&quot;top&quot;| &#039;&#039;Not optional, but in what log does this appear?&#039;&#039;&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;|valign=&quot;top&quot;| &#039;&#039;Not optional, but in what log does this appear? &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;May need to set RandLog = 1 in config.ini.&lt;/ins&gt;&#039;&#039;&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;|}&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;|}&lt;/div&gt;&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; &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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&#039;&#039;&#039;Wrapper&#039;&#039;&#039;&amp;lt;br/&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;This is a wrapper function for working with Map.Rand which makes it much easier to use. Returns a random number between lower and upper and including both.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;syntaxhighlight lang=&quot;lua&quot; class=&quot;civ5-example&quot;&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;function GetRandom(lower, upper)&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;	return Map.Rand((upper + 1) - lower, &quot;&quot;) + lower&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;end&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/ins&gt;&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;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;=Source code samples=&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;=Source code samples=&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Slserpent</name></author>
	</entry>
	<entry>
		<id>https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;diff=16434&amp;oldid=prev</id>
		<title>Slserpent: not your typical rand function</title>
		<link rel="alternate" type="text/html" href="https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;diff=16434&amp;oldid=prev"/>
		<updated>2014-01-25T04:44:21Z</updated>

		<summary type="html">&lt;p&gt;not your typical rand function&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 04:44, 25 January 2014&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-l5&quot;&gt;Line 5:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 5:&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;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;{{TypeInfos5|Function.png|This function is a member of {{Type5|Map}}.&amp;lt;br/&amp;gt;&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;{{TypeInfos5|Function.png|This function is a member of {{Type5|Map}}.&amp;lt;br/&amp;gt;&lt;/div&gt;&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;This is a static method, invoke it with a dot.&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;This is a static method, invoke it with a dot&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;.&amp;lt;br/&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Generates a random number&lt;/ins&gt;.&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;}}&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;}}&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;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;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;=Usage=&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;=Usage=&lt;/div&gt;&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;&amp;lt;code&amp;gt;&#039;&#039;&#039;int&#039;&#039;&#039; Map.Rand&amp;lt;b&amp;gt;(&amp;lt;/b&amp;gt;&#039;&#039;&#039;int&#039;&#039;&#039; &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;upperExclusive&lt;/del&gt;, &#039;&#039;&#039;string&#039;&#039;&#039; logEntry &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;= nil&lt;/del&gt;&amp;lt;b&amp;gt;)&amp;lt;/b&amp;gt;&amp;lt;/code&amp;gt;&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;&amp;lt;code&amp;gt;&#039;&#039;&#039;int&#039;&#039;&#039; Map.Rand&amp;lt;b&amp;gt;(&amp;lt;/b&amp;gt;&#039;&#039;&#039;int&#039;&#039;&#039; &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;maxValues&lt;/ins&gt;, &#039;&#039;&#039;string&#039;&#039;&#039; logEntry&amp;lt;b&amp;gt;)&amp;lt;/b&amp;gt;&amp;lt;/code&amp;gt;&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;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;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;&amp;#039;&amp;#039;&amp;#039;Returned Value&amp;#039;&amp;#039;&amp;#039;&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;&amp;#039;&amp;#039;&amp;#039;Returned Value&amp;#039;&amp;#039;&amp;#039;&lt;/div&gt;&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;:&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;No description available&lt;/del&gt;.&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;:&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;A random number between 0 and maxValues - 1&lt;/ins&gt;.&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;&amp;#039;&amp;#039;&amp;#039;Parameters&amp;#039;&amp;#039;&amp;#039;&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;&amp;#039;&amp;#039;&amp;#039;Parameters&amp;#039;&amp;#039;&amp;#039;&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;:{|&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;:{|&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;|-&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;|-&lt;/div&gt;&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;|valign=&quot;top&quot; style=&quot;padding-right:6px;&quot;|&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;upperExclusive&lt;/del&gt;:&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;|valign=&quot;top&quot; style=&quot;padding-right:6px;&quot;|&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;maxValues&lt;/ins&gt;:&lt;/div&gt;&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;|valign=&quot;top&quot;| &#039;&#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;No description available&lt;/del&gt;.&#039;&#039;&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;|valign=&quot;top&quot;| &#039;&#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;The number of possible random values to make&lt;/ins&gt;.&#039;&#039;&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;|-&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;|-&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;|valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-right:6px;&amp;quot;|logEntry:&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;|valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-right:6px;&amp;quot;|logEntry:&lt;/div&gt;&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;|valign=&quot;top&quot;| &#039;&#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;No description available.&lt;/del&gt;&#039;&#039;&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;|valign=&quot;top&quot;| &#039;&#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Not optional, but in what log does this appear?&lt;/ins&gt;&#039;&#039;&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;|}&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;|}&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>Slserpent</name></author>
	</entry>
	<entry>
		<id>https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;diff=11446&amp;oldid=prev</id>
		<title>DonQuich: Bot update</title>
		<link rel="alternate" type="text/html" href="https://modiki.civfanatics.com/index.php?title=Map.Rand_(Civ5_API)&amp;diff=11446&amp;oldid=prev"/>
		<updated>2012-09-19T20:51:23Z</updated>

		<summary type="html">&lt;p&gt;Bot update&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Civ5 API Beta Banner}}&lt;br /&gt;
&amp;#039;&amp;#039;This page is a part of the [[Lua and UI Reference (Civ5)]].&amp;#039;&amp;#039;&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{TypeInfos5|Function.png|This function is a member of {{Type5|Map}}.&amp;lt;br/&amp;gt;&lt;br /&gt;
This is a static method, invoke it with a dot.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Usage=&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;#039;&amp;#039;&amp;#039;int&amp;#039;&amp;#039;&amp;#039; Map.Rand&amp;lt;b&amp;gt;(&amp;lt;/b&amp;gt;&amp;#039;&amp;#039;&amp;#039;int&amp;#039;&amp;#039;&amp;#039; upperExclusive, &amp;#039;&amp;#039;&amp;#039;string&amp;#039;&amp;#039;&amp;#039; logEntry = nil&amp;lt;b&amp;gt;)&amp;lt;/b&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Returned Value&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
:No description available.&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Parameters&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
:{|&lt;br /&gt;
|-&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-right:6px;&amp;quot;|upperExclusive:&lt;br /&gt;
|valign=&amp;quot;top&amp;quot;| &amp;#039;&amp;#039;No description available.&amp;#039;&amp;#039;&lt;br /&gt;
|-&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-right:6px;&amp;quot;|logEntry:&lt;br /&gt;
|valign=&amp;quot;top&amp;quot;| &amp;#039;&amp;#039;No description available.&amp;#039;&amp;#039;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Source code samples=&lt;br /&gt;
&amp;#039;&amp;#039;Too many occurences. Only 50 out of 668 are listed.&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Amazon_XP.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Maps/Amazon_XP.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|1134}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local diceroll = Map.Rand(10000, &amp;quot;Choose resource type - Assign Luxury To Region - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|1390}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local diceroll = Map.Rand(3, &amp;quot;Resource selection - Place Small Quantities LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|1417}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local strat_radius = Map.Rand(4, &amp;quot;Resource Radius - Place Small Quantities LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Arborea.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Maps/Arborea.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0115}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;sea_level = 1 + Map.Rand(3, &amp;quot;Random Sea Level - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0529}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local grain_dice = Map.Rand(7, &amp;quot;Continental Grain roll - LUA Continents&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0535}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local rift_dice = Map.Rand(3, &amp;quot;Rift Grain roll - LUA Continents&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0679}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;age = 1 + Map.Rand(3, &amp;quot;Random World Age - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0721}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;temp = 1 + Map.Rand(3, &amp;quot;Random Temperature - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|AssignStartingPlots.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Gameplay/Lua/AssignStartingPlots.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|4291}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local diceroll = 1 + Map.Rand(iNumConversionCandidates, &amp;quot;Choosing plot to convert to Grass near food-poor Plains start - LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|4971}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local diceroll = 1 + Map.Rand(table.maxn(candidate_regions), &amp;quot;Choosing from among Candidate Regions for start bias - LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|7671}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;res_addition = Map.Rand(1 + (max_radius - min_radius), &amp;quot;Resource Radius - Place Resource LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Boreal.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Maps/Boreal.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0532}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;x_target = math.floor(iW / 5 + Map.Rand((iW * 0.6), &amp;quot;River Target - Lua&amp;quot;));&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Europe.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Maps/Europe.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0074}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;west_edge[y] = math.ceil(iW * 0.08) - 1 + Map.Rand(4, &amp;quot;Roughen coastline - Mediterranean LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|FeatureGenerator.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Gameplay/Lua/FeatureGenerator.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0340}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local atoll_number = atoll_target + Map.Rand(atoll_target, &amp;quot;Number of Atolls to place - LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0435}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local diceroll = 1 + Map.Rand(100, &amp;quot;Atoll Placement Type - LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|FractalWorld.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Gameplay/Lua/FractalWorld.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0341}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local segmentLength = Map.Rand(primaryMaxLength + 1, &amp;quot;FractalWorld Center Rift Segment Length - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0346}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local dice = Map.Rand(2, &amp;quot;FractalWorld Center Rift Direction - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Great_Plains.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Maps/Great_Plains.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0179}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;rightSeed = Map.Rand(5, &amp;quot;Ozarks Shape - Great Plains Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0517}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;if Map.Rand(100, &amp;quot;Add Oasis Lua&amp;quot;) &amp;lt;= 5 then&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Hemispheres.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Maps/Hemispheres.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0172}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;island_setting = 1 + Map.Rand(4, &amp;quot;Random Temperature - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0389}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local x_shrinkage = Map.Rand(8, &amp;quot;Cell Width adjustment - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0435}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local die_1 = Map.Rand(4, &amp;quot;Diceroll - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0547}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local y_shrinkage = Map.Rand(9, &amp;quot;Cell Height adjustment - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0561}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;fTilt = 70 + Map.Rand(41, &amp;quot;Angle for island chain axis - LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0580}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local iInnerSouth2 = iCellHeight + 2 + Map.Rand(iCellHeight - 3, &amp;quot;Shift for sub island group - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0615}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local iInnerWest1 = 3 + Map.Rand(iCellWidth - 2, &amp;quot;Shift for sub island group - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeLine5|0616}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local iInnerSouth1 = 3 + Map.Rand(iCellHeight - 2, &amp;quot;Shift for sub island group - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0683}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local iInnerWest2 = 4 + Map.Rand(iCellWidth + 2, &amp;quot;Shift for sub island group - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0687}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local die_2 = Map.Rand(7, &amp;quot;Diceroll - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Highlands.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Maps/Highlands.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0093}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local shiftRoll = Map.Rand(2, &amp;quot;North or South climate shift - Highlands LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0127}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;userInputLakes = 1 + Map.Rand(3, &amp;quot;Highlands Random Lake Size - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|IslandMaker.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Gameplay/Lua/IslandMaker.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0136}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local diceroll = Map.Rand(5, &amp;quot;Island Making - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0202}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local randomX = westX + Map.Rand(iInnerWidth, &amp;quot;Random X coord for Dot - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0259}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local randomY = iInnerSouth2 + Map.Rand(iInnerHeight2, &amp;quot;Random Y coord for Dot - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|MapGenerator.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Gameplay/Lua/MapGenerator.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0207}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;if(plot:IsAdjacentToShallowWater() and Map.Rand(iExpansionDiceroll, &amp;quot;add shallows&amp;quot;) == 0) then&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|MapmakerUtilities.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Gameplay/Lua/MapmakerUtilities.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0563}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local random_index = 1 + Map.Rand(left_to_do, &amp;quot;Shuffling table entry - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|MultilayeredFractal.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Gameplay/Lua/MultilayeredFractal.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0866}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local scRoll = Map.Rand((regiononeWidth - scLargeWidth), &amp;quot;Large Subcontinent Placement - Map_Script_Name LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Ring.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Maps/Ring.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0132}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;dominant_terrain = 1 + Map.Rand(4, &amp;quot;Random Type of Dominant Terrain - Ring LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0140}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bridge_width = 2 + Map.Rand(3, &amp;quot;Random Bridge Width - Ring LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Shuffle.lua (G&amp;amp;K)}}&lt;br /&gt;
:&amp;lt;code&amp;gt;DLC/Expansion/Maps/Shuffle.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0076}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local world_age =  1 + Map.Rand(3, &amp;quot;Random World Age - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0581}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;userInputLandmass = 1 + Map.Rand(4, &amp;quot;Random Landmass Type - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0668}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local rain = 1 + Map.Rand(3, &amp;quot;Random Rainfall - Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Skirmish.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Maps/Skirmish.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0355}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local random_factor = Map.Rand(3, &amp;quot;River direction random factor - Skirmish LUA&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|Terra.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Maps/Terra.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0083}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local roll1 = Map.Rand(2, &amp;quot;Eurasian Hemisphere N/S - Terra Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0329}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local nwcRoll = Map.Rand(2, &amp;quot;Central America and Carribean Placement - Terra Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0432}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local scsRoll = Map.Rand((eurasiaWidth - scSmallWidth), &amp;quot;Small Subcontinent Placement - Terra Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0477}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local extras = 2 + Map.Rand(3, &amp;quot;Number of Minor Regions - Terra Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0483}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local twRoll = Map.Rand((eurasiaWidth - twWidth), &amp;quot;Minor Region Placement - Terra Lua&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PseudoH4|WorldBuilderRandomItems.lua}}&lt;br /&gt;
:&amp;lt;code&amp;gt;Gameplay/Lua/WorldBuilderRandomItems.lua&amp;lt;/code&amp;gt;&lt;br /&gt;
:{{CodeBegin5}}&lt;br /&gt;
{{CodeLine5|0018}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local rand1 = Map.Rand(resource.RandApp1, &amp;quot;MapGenerator CalculateNumResourcesToAdd-1&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeBreak5}}&lt;br /&gt;
{{CodeLine5|0021}}&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;local rand4 = Map.Rand(resource.RandApp4, &amp;quot;MapGenerator CalculateNumResourcesToAdd-4&amp;quot;);&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{CodeEnd5}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Civ5 API Footer}}&lt;br /&gt;
[[Category:Civ5 Methods and Functions|Rand]]&lt;/div&gt;</summary>
		<author><name>DonQuich</name></author>
	</entry>
</feed>