<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.perfecttower2.com/wiki/index.php?action=history&amp;feed=atom&amp;title=AI_Script_Repository</id>
	<title>AI Script Repository - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.perfecttower2.com/wiki/index.php?action=history&amp;feed=atom&amp;title=AI_Script_Repository"/>
	<link rel="alternate" type="text/html" href="https://www.perfecttower2.com/wiki/index.php?title=AI_Script_Repository&amp;action=history"/>
	<updated>2026-05-04T16:26:12Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.33.1</generator>
	<entry>
		<id>https://www.perfecttower2.com/wiki/index.php?title=AI_Script_Repository&amp;diff=3104&amp;oldid=prev</id>
		<title>Dbugz: Marking as Historical.</title>
		<link rel="alternate" type="text/html" href="https://www.perfecttower2.com/wiki/index.php?title=AI_Script_Repository&amp;diff=3104&amp;oldid=prev"/>
		<updated>2023-08-24T18:14:24Z</updated>

		<summary type="html">&lt;p&gt;Marking as Historical.&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&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: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 18:14, 24 August 2023&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 colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; 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;{{Historical}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; 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;&lt;/ins&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-color: #f8f9fa; color: #222; 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;== Overview ==&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; 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;== Overview ==&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-color: #f8f9fa; color: #222; 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;This is a collection of AI scripts that you can use to enhance your game.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; 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;This is a collection of AI scripts that you can use to enhance your game.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key tpt2_wiki:diff::1.12:old-793:rev-3104 --&gt;
&lt;/table&gt;</summary>
		<author><name>Dbugz</name></author>
		
	</entry>
	<entry>
		<id>https://www.perfecttower2.com/wiki/index.php?title=AI_Script_Repository&amp;diff=793&amp;oldid=prev</id>
		<title>Troylaurin: Created the page, including auto-skills and auto-miner (nearly)</title>
		<link rel="alternate" type="text/html" href="https://www.perfecttower2.com/wiki/index.php?title=AI_Script_Repository&amp;diff=793&amp;oldid=prev"/>
		<updated>2021-01-27T05:18:00Z</updated>

		<summary type="html">&lt;p&gt;Created the page, including auto-skills and auto-miner (nearly)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Overview ==&lt;br /&gt;
This is a collection of AI scripts that you can use to enhance your game.&lt;br /&gt;
&lt;br /&gt;
After importing each script, you will probably have to add an impulse to be able to trigger it.&lt;br /&gt;
&lt;br /&gt;
== Early game ==&lt;br /&gt;
Simple scripts to automate or enhance regular game functions.&lt;br /&gt;
&lt;br /&gt;
=== Tower Testing ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+A very simple loop to use the tower's active skills in combat.&lt;br /&gt;
Note that the AI cannot active a targeted skill by clicking, so modules such as Firestorm will not be activated by this script.&lt;br /&gt;
&lt;br /&gt;
You can add or delete rows as necessary depending on how many active skill modules you have equipped.&lt;br /&gt;
!Name&lt;br /&gt;
!Code&lt;br /&gt;
|-&lt;br /&gt;
|tower auto-use skills&lt;br /&gt;
(8 lines)&lt;br /&gt;
|{{AIScript&lt;br /&gt;
| code = FXRvd2VyIGF1dG8tdXNlIHNraWxscwAAAAAAAAAACAAAABd0b3dlci5tb2R1bGUudXNlaW5zdGFudAhj&lt;br /&gt;
b25zdGFudAIBAAAAF3Rvd2VyLm1vZHVsZS51c2VpbnN0YW50CGNvbnN0YW50AgIAAAAXdG93ZXIubW9k&lt;br /&gt;
dWxlLnVzZWluc3RhbnQIY29uc3RhbnQCAwAAABd0b3dlci5tb2R1bGUudXNlaW5zdGFudAhjb25zdGFu&lt;br /&gt;
dAIEAAAAF3Rvd2VyLm1vZHVsZS51c2VpbnN0YW50CGNvbnN0YW50AgUAAAAXdG93ZXIubW9kdWxlLnVz&lt;br /&gt;
ZWluc3RhbnQIY29uc3RhbnQCBgAAABd0b3dlci5tb2R1bGUudXNlaW5zdGFudAhjb25zdGFudAIHAAAA&lt;br /&gt;
DGdlbmVyaWMuZ290bwhjb25zdGFudAIBAAAA&lt;br /&gt;
| src = loop: useinstant(1)&lt;br /&gt;
  useinstant(2)&lt;br /&gt;
  useinstant(3)&lt;br /&gt;
  useinstant(4)&lt;br /&gt;
  useinstant(5)&lt;br /&gt;
  useinstant(6)&lt;br /&gt;
  useinstant(7)&lt;br /&gt;
  goto(loop)&lt;br /&gt;
}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Mine ===&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+The canonical auto-miner.  By default it triggers on impulse '0' when the mine screen is open.&lt;br /&gt;
This version of the script is resolution-independent and should not require any editing.&lt;br /&gt;
!Name&lt;br /&gt;
!Code&lt;br /&gt;
|-&lt;br /&gt;
|ATR_MINER&lt;br /&gt;
(11 lines)&lt;br /&gt;
|{{AIScript&lt;br /&gt;
| code = TODO&lt;br /&gt;
| src = TODO&lt;br /&gt;
}}&lt;br /&gt;
|-&lt;br /&gt;
|auto_tiler_recursive&lt;br /&gt;
(11 lines)&lt;br /&gt;
|{{AIScript&lt;br /&gt;
| code = FGF1dG9fdGlsZXJfcmVjdXJzaXZlAAAAAAAAAAALAAAADWxvY2FsLmludC5zZXQIY29uc3RhbnQEBWlu&lt;br /&gt;
ZGV4Dmdsb2JhbC5pbnQuZ2V0CGNvbnN0YW50BAlhdHJfaW5kZXgOZ2xvYmFsLmludC5zZXQIY29uc3Rh&lt;br /&gt;
bnQECWF0cl9pbmRleA5hcml0aG1ldGljLmludA5nbG9iYWwuaW50LmdldAhjb25zdGFudAQJYXRyX2lu&lt;br /&gt;
ZGV4CGNvbnN0YW50BAErCGNvbnN0YW50AgEAAAAOZ2VuZXJpYy5nb3RvaWYIY29uc3RhbnQCBwAAAA5j&lt;br /&gt;
b21wYXJpc29uLmludA5nbG9iYWwuaW50LmdldAhjb25zdGFudAQJYXRyX2luZGV4CGNvbnN0YW50BAI9&lt;br /&gt;
PQhjb25zdGFudAIRAAAAD2dlbmVyaWMuZXhlY3V0ZQhjb25zdGFudAQUYXV0b190aWxlcl9yZWN1cnNp&lt;br /&gt;
dmUIbWluZS5kaWcOYXJpdGhtZXRpYy5pbnQNbG9jYWwuaW50LmdldAhjb25zdGFudAQFaW5kZXgIY29u&lt;br /&gt;
c3RhbnQEA21vZAhjb25zdGFudAIEAAAADmFyaXRobWV0aWMuaW50DWxvY2FsLmludC5nZXQIY29uc3Rh&lt;br /&gt;
bnQEBWluZGV4CGNvbnN0YW50BAEvCGNvbnN0YW50AgQAAAAMZ2VuZXJpYy5nb3RvCGNvbnN0YW50AgUA&lt;br /&gt;
AAARZ2VuZXJpYy53YWl0dW50aWwOY29tcGFyaXNvbi5pbnQOZ2xvYmFsLmludC5nZXQIY29uc3RhbnQE&lt;br /&gt;
CWF0cl9sYXllcghjb25zdGFudAQBPghjb25zdGFudAIAAAAADW1pbmUubmV3bGF5ZXIOZ2xvYmFsLmlu&lt;br /&gt;
dC5zZXQIY29uc3RhbnQECWF0cl9sYXllcg5hcml0aG1ldGljLmludA5nbG9iYWwuaW50LmdldAhjb25z&lt;br /&gt;
dGFudAQJYXRyX2xheWVyCGNvbnN0YW50BAEtCGNvbnN0YW50AgEAAAAOZ2VuZXJpYy5nb3RvaWYIY29u&lt;br /&gt;
c3RhbnQCCAAAAA5jb21wYXJpc29uLmludA5nbG9iYWwuaW50LmdldAhjb25zdGFudAQJYXRyX2xheWVy&lt;br /&gt;
CGNvbnN0YW50BAE+CGNvbnN0YW50AgAAAAAMZ2VuZXJpYy5nb3RvCGNvbnN0YW50AgcAAAA=&lt;br /&gt;
| src = :global int atr_layer&lt;br /&gt;
:global int atr_index&lt;br /&gt;
:local int index&lt;br /&gt;
&lt;br /&gt;
  index = atr_index&lt;br /&gt;
  atr_index = atr_index + 1&lt;br /&gt;
  gotoif(7, atr_index == 17)&lt;br /&gt;
  execute(&amp;quot;auto_tiler_recursive&amp;quot;)&lt;br /&gt;
5: dig(index % 4, index / 4)&lt;br /&gt;
  goto(5)&lt;br /&gt;
7: waituntil(atr_layer &amp;gt; 0)&lt;br /&gt;
8: newlayer()&lt;br /&gt;
  atr_layer = atr_layer - 1&lt;br /&gt;
  gotoif(8, atr_layer &amp;gt; 0)&lt;br /&gt;
  goto(7)&lt;br /&gt;
}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Factory ===&lt;br /&gt;
Craft chips&lt;br /&gt;
&lt;br /&gt;
Dust tiering&lt;br /&gt;
&lt;br /&gt;
=== Laboratory ===&lt;br /&gt;
Nature experiment&lt;br /&gt;
&lt;br /&gt;
Electricity experiment&lt;br /&gt;
&lt;br /&gt;
=== Museum ===&lt;br /&gt;
Auto-combine gems&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== More advanced scripts ==&lt;br /&gt;
These scripts should generally be considered game-changing in some way.&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contributing ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{PerfectNavigation}}&lt;/div&gt;</summary>
		<author><name>Troylaurin</name></author>
		
	</entry>
</feed>