<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://oxeyegames.com/wiki/skins/common/feed.css?270"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://oxeyegames.com/wiki/index.php?action=history&amp;feed=atom&amp;title=DefineUpgradeButton_%28Harvest%29</id>
		<title>DefineUpgradeButton (Harvest) - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://oxeyegames.com/wiki/index.php?action=history&amp;feed=atom&amp;title=DefineUpgradeButton_%28Harvest%29"/>
		<link rel="alternate" type="text/html" href="http://oxeyegames.com/wiki/index.php?title=DefineUpgradeButton_(Harvest)&amp;action=history"/>
		<updated>2026-05-07T10:19:09Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.16.0</generator>

	<entry>
		<id>http://oxeyegames.com/wiki/index.php?title=DefineUpgradeButton_(Harvest)&amp;diff=251&amp;oldid=prev</id>
		<title>166 MMX at 19:27, 2 December 2009</title>
		<link rel="alternate" type="text/html" href="http://oxeyegames.com/wiki/index.php?title=DefineUpgradeButton_(Harvest)&amp;diff=251&amp;oldid=prev"/>
				<updated>2009-12-02T19:27:45Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
		&lt;tr valign='top'&gt;
		&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;← Older revision&lt;/td&gt;
		&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 19:27, 2 December 2009&lt;/td&gt;
		&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 6:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 6:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;|&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;|&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;{{MethodParam|oldBuilding|String|The building identifier name of the building that is upgradable.}}&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;{{MethodParam|oldBuilding|String|The building identifier name of the building that is upgradable.}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;{{MethodParam|&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;newBuildingu&lt;/del&gt;|String|The building identifier name of the building that it will be upgraded to.}}&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;{{MethodParam|&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;newBuilding&lt;/ins&gt;|String|The building identifier name of the building that it will be upgraded to.}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;|&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;|&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;Returns nothing.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;Returns nothing.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>166 MMX</name></author>	</entry>

	<entry>
		<id>http://oxeyegames.com/wiki/index.php?title=DefineUpgradeButton_(Harvest)&amp;diff=250&amp;oldid=prev</id>
		<title>166 MMX: Created page with '{{HarvestMethod | defineUpgradeButton(oldBuilding, newBuilding) | Defines an upgrade button for 'upgradeBuildingId'. | {{MethodParam|oldBuilding|String|The building identifier na...'</title>
		<link rel="alternate" type="text/html" href="http://oxeyegames.com/wiki/index.php?title=DefineUpgradeButton_(Harvest)&amp;diff=250&amp;oldid=prev"/>
				<updated>2009-12-02T19:25:51Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;#39;{{HarvestMethod | defineUpgradeButton(oldBuilding, newBuilding) | Defines an upgrade button for &amp;#39;upgradeBuildingId&amp;#39;. | {{MethodParam|oldBuilding|String|The building identifier na...&amp;#39;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{HarvestMethod&lt;br /&gt;
|&lt;br /&gt;
defineUpgradeButton(oldBuilding, newBuilding)&lt;br /&gt;
|&lt;br /&gt;
Defines an upgrade button for 'upgradeBuildingId'.&lt;br /&gt;
|&lt;br /&gt;
{{MethodParam|oldBuilding|String|The building identifier name of the building that is upgradable.}}&lt;br /&gt;
{{MethodParam|newBuildingu|String|The building identifier name of the building that it will be upgraded to.}}&lt;br /&gt;
|&lt;br /&gt;
Returns nothing.&lt;br /&gt;
}}&lt;br /&gt;
=== Example ===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
harvest.defineUpgrade(&amp;quot;SUPERSOLARPLANT&amp;quot;, &amp;quot;Super-duper Solar Plant&amp;quot;, &amp;quot;This is a really good solar plant.&amp;quot;, 300, 100, 30.0, &amp;quot;SparkProducer&amp;quot;)&lt;br /&gt;
harvest.defineUpgradeButton(&amp;quot;SPARKPRODUCER&amp;quot;, &amp;quot;SUPERSOLARPLANT&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
local function runSuperSolarPlant(entity, params, deltaTime)&lt;br /&gt;
   params.timer = params.timer or 0&lt;br /&gt;
   params.timer = params.timer + deltaTime&lt;br /&gt;
   if params.timer &amp;gt; 0.5 then&lt;br /&gt;
      params.timer = params.timer - 0.5&lt;br /&gt;
      local id = entity:getId()&lt;br /&gt;
      harvest.spawnEnergySpark(id)&lt;br /&gt;
   end&lt;br /&gt;
end&lt;br /&gt;
hook.add(&amp;quot;SUPERSOLARPLANT_Update&amp;quot;, runSuperSolarPlant)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Resources ===&lt;br /&gt;
*[http://www.oxeyegames.com/forum/viewtopic.php?p=1523#p1523 Oxeye Game Studio Forum - Harvest Functions]&lt;/div&gt;</summary>
		<author><name>166 MMX</name></author>	</entry>

	</feed>