<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.commanderwars.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=MrDuck557</id>
	<title>Commander Wars - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.commanderwars.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=MrDuck557"/>
	<link rel="alternate" type="text/html" href="https://www.commanderwars.com/wiki/Special:Contributions/MrDuck557"/>
	<updated>2026-10-01T13:43:02Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.38.1</generator>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Main_Page&amp;diff=4697</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Main_Page&amp;diff=4697"/>
		<updated>2025-09-24T18:14:36Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Added Modded CO List to main page&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;strong&amp;gt;Welcome to Commander Wars Wiki&amp;lt;/strong&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The project is separated in three parts.&lt;br /&gt;
&lt;br /&gt;
*The core engine written in C++ using oxygine as a render and input engine and qt as an interpreter, language support etc. framework&lt;br /&gt;
*The resources folder containing the javascript default data and images and sounds or music&lt;br /&gt;
*The mods folder containing mods for the core engine&lt;br /&gt;
&lt;br /&gt;
Consult the [https://github.com/Robosturm/Commander_Wars Github page] for bug reports, feedback and feature requests.&lt;br /&gt;
&lt;br /&gt;
The releases page of the game can be found [https://github.com/Robosturm/Commander_Wars/releases here] . &lt;br /&gt;
&lt;br /&gt;
This is the [[F.A.Q.]]&lt;br /&gt;
&lt;br /&gt;
Join the [https://discord.gg/WKXFcXPmxz Discord Server] to discuss the game, and get more scripting help.&lt;br /&gt;
==Showcasing of the game==&lt;br /&gt;
This is a demonstration of the game capabilities, the CO powers of the [[Xanari Crew]] mod, by XnKradst&amp;lt;br/&amp;gt;&lt;br /&gt;
&amp;lt;youtube&amp;gt;https://www.youtube.com/watch?v=j8M-SqqOQOA &amp;lt;/youtube&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== A custom CO card generator ==&lt;br /&gt;
This simple tool was created to help you [https://www.commanderwars.com/front.php generate your CO]&lt;br /&gt;
&lt;br /&gt;
==Recent Pages==&lt;br /&gt;
{{Special:Newestpages/-/5}}&lt;br /&gt;
&lt;br /&gt;
== Content Categories ==&lt;br /&gt;
[[:Category:Modding_tutorials|Modding tutorials]] contain scripting reference for custom COs and Units.&lt;br /&gt;
&lt;br /&gt;
[[:Category:Technical| Technical guides]] contain guides intended for developers, they are technical in nature.&lt;br /&gt;
&lt;br /&gt;
[[:Category:Gameplay| Gameplay]] articles are intended to help players understand the game.&lt;br /&gt;
&lt;br /&gt;
[[List of Modded COs|Modded CO List]] List of custom COs created by COW Discord Community&lt;br /&gt;
&lt;br /&gt;
[[:Category:Mods| Mod list]] List of Mod created by COW Discord community&lt;br /&gt;
&lt;br /&gt;
[[:Category:Community Maps| Map list]] List of Map created by COW Discord community&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=List_of_Modded_COs&amp;diff=4177</id>
		<title>List of Modded COs</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=List_of_Modded_COs&amp;diff=4177"/>
		<updated>2024-04-19T02:18:39Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Added descriptions for Balsam, Osprey, and Seargent Quackers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==List of Modded and Playable Custom COs for Commander Wars==&lt;br /&gt;
Last Updated: April 18th, 2024&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! scope=&amp;quot;col&amp;quot; | Mod name  ||  scope=&amp;quot;col&amp;quot; | Mod Link || scope=&amp;quot;col&amp;quot; | Image / Dossier &lt;br /&gt;
!Description|| scope=&amp;quot;col&amp;quot; | Creator(s) || scope=&amp;quot;col&amp;quot; |Last Updated &lt;br /&gt;
|-&lt;br /&gt;
| Aaron || [https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| || KesalahanTeknis, Marmalad || April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Agnes || [https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| || KesalahanTeknis || December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Alek || [https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| || KesalahanTeknis || December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Alice || [https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Alps|| [https://drive.google.com/file/d/1YE6nmvXAw5c7RIDWG_dLRryplgUInFtv/view?usp=sharing Standalone release]||[https://i.imgur.com/3eD8iUW.png Image]&lt;br /&gt;
| ||Nanoka||December 22nd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Ambrose||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Amy||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]|| [https://i.imgur.com/aY3v126.png Image]&lt;br /&gt;
| ||F.C.M.C Memories 54||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1hYzWbfrMebRIAZQYNZWYdb8ydmmGzCIG/view?usp=sharing Standalone version]||[https://i.imgur.com/BWdMnQx.jpg Image]&lt;br /&gt;
| ||F.C.M.C Memories 54||October 9th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Andrea||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Aoi Kaze||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/mnRy6qu.png Image]&lt;br /&gt;
| || ruigio||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──|| [https://drive.google.com/file/d/1C-1LKLSCQUxcFLx1UdISgL6OSbKdH5L4/view?usp=sharing Standalone version]||[https://i.imgur.com/KSpp2PD.png Image]&lt;br /&gt;
| ||ruigio || January 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Apothema||[https://drive.google.com/file/d/1uOPewGS05etwCSMwaDwvWUp-89289n9q/view?usp=sharing Silver Horizon (Older version)]|| &lt;br /&gt;
| ||ChemAtDark||July 2nd, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Argent||[https://drive.google.com/file/d/1xL2u2VocZoDOjKP7y8ryH8cfC632WmKo/view?usp=sharing Battalion CoW]|| &lt;br /&gt;
| ||Hamplmann||June 20th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Bally||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis || December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Balsam||[https://drive.google.com/file/d/11gROTiA0SxNHiPIGzWLcClgjS3xJfOPO/view?usp=sharing Standalone release]||&lt;br /&gt;
| CO with a focus on ground vehicles and movement. Perfect movement in zone and canto ensure that not a single move point is wasted. Powers convert mobility into raw power, with COP giving more attack for each tile moved and SCOP allowing units to move and attack through multiple enemies.||MrDuck557|| April 18th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Bawke||[https://drive.google.com/file/d/18-FUmQxbaMsIuzZJONUT9McDoMsBFJCh/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Hog||June 24th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Bernstein||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Big Derp||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Ridiculously high firepower and defense that go down as his power meter (of 15 stars) charges, and it charges at a very fast rate. Superpower dealt 5 HP of damage to all of his own units. No regular CO power.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Blaze&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/UTJZRcz.png Image]&lt;br /&gt;
| Indirect units have no minimum range, direct units can attack indirectly with powers.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above but without the minimum range for indirect units.|| XnKradst || March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Bill||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/Ozb01FD.png Image]&lt;br /&gt;
| || Niklas||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1sLR2yLvN8HJKK7Snt_1fDZBvJayjzTYw/view?usp=sharing Standalone version]||[https://i.imgur.com/DS81Ryy.png Image]&lt;br /&gt;
| || Niklas||October 9th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Billy Gates||[https://drive.google.com/file/d/1eY3GLJqeHOBHXWcEaSEFkgXLpct_Lthq/view?usp=sharing Standalone release]|| &lt;br /&gt;
| || K&#039;Braid ||October 12th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Billy Gates||[https://drive.google.com/file/d/1iIAVQiJFMukT06flThtfR7aOzhZECE-J/view?usp=sharing SFW COs]|| &lt;br /&gt;
| ||Creed||October 14th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Binah||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Boris||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Air units can pass through enemy units at all times. Powers allow them to also damage the enemy units being passed through.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Braid||[https://drive.google.com/file/d/1zirDJbTfrTRJJQvHRfIU7BIeOV1lPtlR/view K&#039;Braid&#039;s COs]|| &lt;br /&gt;
| ||K&#039;Braid|| March 19th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Brashim||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/2h90Eys.png Image]&lt;br /&gt;
| ||brasmak||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|BunBun||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| BVin||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad|| April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Cadenza||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]|| [https://i.imgur.com/wbSpiM8.png Image]&lt;br /&gt;
| ||MegaTank||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1gCpDqFjIvvnbypaZDIuJ_-cMcR97zJwz/view?usp=sharing Standalone version]||[https://i.imgur.com/wqBbZfx.png Image]&lt;br /&gt;
| ||MegaTank || August 8th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Camber||[https://drive.google.com/file/d/1CQnuR6nRaM6wo82Ic9CroTStYxyeuhqt/view?usp=sharing Chinese Kanbei]||[https://i.imgur.com/3MA6rTx.png Image]&lt;br /&gt;
| ||Nin10doGMod|| October 25th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Caroline||[https://drive.google.com/file/d/1iIAVQiJFMukT06flThtfR7aOzhZECE-J/view?usp=sharing SFW COs]|| &lt;br /&gt;
| || Creed||October 14th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Cassandra||[https://drive.google.com/file/d/1jsQbZpdcurtbJnAPRAwOVTP7S3ZpURgQ/view?usp=sharing BattleTanx COs]|| &lt;br /&gt;
| ||Ellie|| January 30th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Cattleya||[https://drive.google.com/file/d/1Gamo6lgKgskdknL8pzU0WZCNFCjeKdVE/view?usp=sharing Standalone release]||[https://i.imgur.com/vzUC0KV.png Image]&lt;br /&gt;
| ||Nanoka||October 17th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Cheibriados || [https://drive.google.com/file/d/1W3fCF2HQfL0MoUk-5I4eXPWVTOhH8E14/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Brilliand||October 26th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Chelsen&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/lCEgZYD.png Image]&lt;br /&gt;
| Units gain a firepower buff and a defense debuff, or the other way around, depending on their map position&#039;s &amp;quot;parity&amp;quot; (think checkerboard pattern).||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but with slightly different CO powers and no visual indicators.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Chesed||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis || December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Chris||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Cindee&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/xMI9hSl.png Image]&lt;br /&gt;
| Units gain both firepower and defense the closer they are to her buildings. If near multiple buildings, the bonuses stack.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Units gain firepower and defense if within 10 spaces of her HQ(s), gaining more bonuses the closer they are to the HQ(s).||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Clone Andy||[https://www.mediafire.com/file/li8lzzekdrobf5g/Clone_Andy.zip/file Standalone release]||[https://i.imgur.com/Ich0y1F.png Image]&lt;br /&gt;
| ||Nin10doGMod||September 10th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Contessa&lt;br /&gt;
|[https://drive.google.com/file/d/1c4-WkTxJowPlfL_4dLzddqyxi4nUA50Q/view?usp=sharing Standalone release]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Brilliand&lt;br /&gt;
|April 18th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Cyphir&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/wjFRlCg.png Image]&lt;br /&gt;
| All units can capture properties, but non-foot soldiers capture at a slower pace. Non-foot soldiers also lose defense when capturing.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but with slightly different CO powers and penalties.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Cyrus||[https://drive.google.com/file/d/1e5EX9cO_6rj9_8dP4F-Mz7LCSEFaKxec/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||K&#039;Braid||February 12th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Daehyun||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Damaskas||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis ||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Damond||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Danial||[https://drive.google.com/file/d/1zirDJbTfrTRJJQvHRfIU7BIeOV1lPtlR/view K&#039;Braid&#039;s COs]|| &lt;br /&gt;
| ||K&#039;Braid||March 19th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Darjeeling||[https://drive.google.com/file/d/16BN7eoXjXVCY0gnBXAwTibinXg2TIf4V/view?usp=sharing Standalone release]||[https://i.imgur.com/1xEFvh8.png Image]&lt;br /&gt;
| || Namelessone|| September 15th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Dark Despair||[https://drive.google.com/file/d/1N1nU6U1g9KxFirZKBaklXCDXmgOZ_tRa/view?usp=sharing Imperial COs]|| &lt;br /&gt;
| ||DarkDespair||December 7th, 2021&lt;br /&gt;
|-&lt;br /&gt;
|DarkusRelling||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Deckard||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Dekkar&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/LfaM7ib.png Image]&lt;br /&gt;
| The fewer (other) units surrounding his units, the more defense they have. The fewer units surrounding the target, the more damage his units deal to them.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Units have high firepower and defense if they are &amp;quot;isolated&amp;quot; from his other units (at least two tiles away).|| XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Dekks||[https://drive.google.com/file/d/1yyph-Y52ByCoY3iAnkMZsv1YLhRvnMmm/view?usp=sharing Gin Co Mod]||[https://i.imgur.com/uLULGwb.png Image]&lt;br /&gt;
| ||gin_san ||October 24th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Dekks(Young version)||[https://drive.google.com/file/d/1yyph-Y52ByCoY3iAnkMZsv1YLhRvnMmm/view?usp=sharing Gin Co Mod]||[https://i.imgur.com/gEqgImg.png Image]&lt;br /&gt;
| ||gin_san||October 24th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Destin||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| All bases can build air units as long as he owns an airport somewhere on the map. Overpowered CO powers where with every attack, all enemy units of the same exact type (also belonging to the same opponent) as the target suffer collateral damage.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Drac&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/PhI4yi8.png Image]&lt;br /&gt;
| Units gain firepower for each round of ammunition and every 5 points of fuel missing from the target.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Units start weak, but gain firepower and defense over time, capping at Day 45.||XnKradst|| March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Drake / Drayke&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/IVfQdD1.png Image]&lt;br /&gt;
| Direct units deal more damage if they attack without moving. CO powers either allow direct units to attack again after attacking (only in the same position) or drop temporary Mechs that can immediately attack without moving.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but with entirely different CO powers: units with low HP deal massive damage.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Dread||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Foot soldiers are unhindered by mountains and rivers. CO powers reshuffle enemy positions in a meteor-like radius, and reduces enemy vision.||XnKradst ||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Duke || [https://drive.google.com/file/d/1CJeoPcZCeckhOecs5bX6dArgVytlsR_Q/view?usp=sharing AW Air Force Mod]|| &lt;br /&gt;
| ||Tesla_Trooper||August 21st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Durand||[https://drive.google.com/file/d/1xL2u2VocZoDOjKP7y8ryH8cfC632WmKo/view?usp=sharing Battalion CoW]|| &lt;br /&gt;
| ||Hamplmann||June 20th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Durand (Boss)||[https://drive.google.com/file/d/1xL2u2VocZoDOjKP7y8ryH8cfC632WmKo/view?usp=sharing Battalion CoW]|| &lt;br /&gt;
| || Hamplmann||June 20th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Eili||[https://drive.google.com/file/d/1zirDJbTfrTRJJQvHRfIU7BIeOV1lPtlR/view K&#039;Braid&#039;s COs]|| &lt;br /&gt;
| || K&#039;Braid ||March 19th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Elana||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/gAhIMa5.png Image]&lt;br /&gt;
| ||Captain Trek, Niklas||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Embrie&lt;br /&gt;
| [https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/P3OMiVM.png Image]&lt;br /&gt;
| Each consecutive/repeated attack against the same enemy unit on the same turn has more firepower than the last.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, only with slight differences.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Emilie||[https://drive.google.com/file/d/1dHk6qLYlQ-w5VWV1ZAXe1jghbaCx0T7v/view?usp=sharing Standalone release]||[https://i.imgur.com/hz5lHTY.png Image]&lt;br /&gt;
| ||Nanoka||October 11th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Enigma||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as below, but without a CO zone.|| XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1c1WMRrxyFV-MbQcW9di8D-7cWuyTxmto/view?usp=sharing Standalone version]|| [https://i.imgur.com/dNMezTV.png Image]&lt;br /&gt;
| Changes stats and powers to a randomly chosen CO out of the 28 AW trilogy COs at the start of every turn.||XnKradst||April 2nd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Eph ||[https://drive.google.com/file/d/16GSGcaVzW-YByqO77BnqNyhEFJUJ8qtQ/view?usp=sharing Advance Wars Whatever Mod]|| &lt;br /&gt;
| ||bajing_jalan_jalan||August 31st, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Eric Andre||[https://drive.google.com/file/d/1t-05kD2INgKtjZHj1TsDQdga0FFa6nkF/view?usp=sharing Standalone release]||[https://i.imgur.com/A13joqT.png Image]&lt;br /&gt;
| ||Thunderdoughnut||January 27th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Error||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Old version of Xanderbot (see below).&lt;br /&gt;
Changes stats and powers to a randomly chosen CO out of the 38 Xanari Crew COs (from the original mod) at the start of every turn.&lt;br /&gt;
|XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Eva||[https://drive.google.com/file/d/1zirDJbTfrTRJJQvHRfIU7BIeOV1lPtlR/view K&#039;Braid&#039;s COs]|| &lt;br /&gt;
| ||K&#039;Braid||March 19th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Evan||[https://drive.google.com/file/d/16GSGcaVzW-YByqO77BnqNyhEFJUJ8qtQ/view?usp=sharing Advance Wars Whatever Mod]|| &lt;br /&gt;
| ||bajing_jalan_jalan||August 31st, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Excella||[https://drive.google.com/file/d/1MPU0c59TjZ8naMvREE5gBBR4bW82OwYN/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||TheUberHunter||September 29th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Fioretto|| [https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/Wim0ByI.png Image]&lt;br /&gt;
| ||Hamplmann||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Frazone||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/ZwPR3w7.png Image]&lt;br /&gt;
| ||Captain Trek, Frazone ||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Frud||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Futo||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222 ||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Ganyu||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Gebura||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Gerald||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Gina||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/VxCjKiW.png Image]&lt;br /&gt;
| ||Nanoka||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1onEmoGsmOqzTZOtgDAJXL5f2YSRhWlfZ/view?usp=sharing Standalone version]||[https://i.imgur.com/gKvLn72.png Image]&lt;br /&gt;
| ||Nanoka||October 5th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Goomba Tower||[https://drive.google.com/file/d/1ZjOuRGNVhfrtKHA2joYBBkmEfpt49Atu/view?usp=sharing Standalone release]||[https://i.imgur.com/9Wvh9md.png Image]&lt;br /&gt;
| Infantry can &amp;quot;stack&amp;quot; onto each other by loading into each other. The more units an infantry unit is carrying, the more damage it deals and the less damage it receives.||XnKradst||December 12th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Great Minds&lt;br /&gt;
|[https://drive.google.com/file/d/13hGRsfP8NkT0y84uszDYt2uvdpFFt5j7/view?usp=sharing Standalone release]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Brilliand&lt;br /&gt;
|April 18th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Grendelle||[https://drive.google.com/file/d/1q6lLTyPJMBl5ztVp6k8At1UM-aunz1rJ/view?usp=sharing Standalone release]||[https://i.imgur.com/9Wvh9md.png Image]&lt;br /&gt;
| ||Nanoka||June 10th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Griffin Spade||[https://drive.google.com/file/d/1jsQbZpdcurtbJnAPRAwOVTP7S3ZpURgQ/view?usp=sharing BattleTanx COs]|| &lt;br /&gt;
| ||Ellie||January 30th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Grigori||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/nSS2XSz.png Image]&lt;br /&gt;
| Units deal more damage if they start in a position not covered by the entire enemy army&#039;s vision (even outside Fog of War). CO powers allow indirect units to fire multiple times without moving.|| XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above but with slight balance changes, and the superpower also dealt splash damage to everything in an indirect unit&#039;s fire range.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Gunter||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Haman||[https://drive.google.com/file/d/1L6-JmgLCmqCyrymFjXbJ4sWYoWpGLf9y/view?usp=sharing Standalone release]||[https://i.imgur.com/iH70UEY.png Image]&lt;br /&gt;
| ||Jsonic3000||February 14th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hanabi||[https://drive.google.com/file/d/1mGnHtI4VpAf-RZ9j4u9_EMlaidYKnpyn/view?usp=sharing Standalone release]||[https://i.imgur.com/GSb1fye.png Image]&lt;br /&gt;
| ||Nanoka||November 3rd, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Harbinger|| [https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/6uAJSNC.png Image]&lt;br /&gt;
| ||StarFlash||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Heck You||[https://drive.google.com/file/d/1P80UjX_z7TgHlNud31HKBXWAtkR63Gku/view?usp=sharing Heck You]||[https://i.imgur.com/A1txdBq.png Image]&lt;br /&gt;
| ||MrDuck557||December 23rd, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Helena||[https://drive.google.com/file/d/1p6XBx2XTwatkX23QcEiUSoN3VwkG7gb9/view?usp=sharing Standalone release]||[https://i.imgur.com/BFUj5Pl.png Image]&lt;br /&gt;
| ||Nanoka||September 6th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hibana ||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/mY35Yvu.png Image]&lt;br /&gt;
| ||Captain Trek, TenesCross||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hijiri||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Hod||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Hokma||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Huang ||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/4YCZCB7.png Image]&lt;br /&gt;
| ||Captain Trek, Lady Braixen||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hughes||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/C6X2Syy.png Image]&lt;br /&gt;
| ||Captain Trek, ???||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hutao||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Iyala ||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Each time she kills an enemy unit, the enemy loses power charge (unless they already have a portion of the power filled, so she cannot thwart CO powers). CO powers heal or damage every unit on the map depending on their remaining HP.||XnKradst ||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Izzy||[https://drive.google.com/file/d/1zmYetlek4O-j6Noe7F_hNsOjSBzhWeNp/view?usp=sharing Nanoka AW2 COs]|| &lt;br /&gt;
| ||Nanoka|| January 26th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Jaime||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Jessabelle ||[https://drive.google.com/file/d/1tbK1ypKQ-wXrtClOonw9OpHP46La3wPV/view?usp=sharing Standalone release]||[https://i.imgur.com/7DHhr1R.png Image]&lt;br /&gt;
| ||Nanoka||December 3rd, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Jiffy||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/WsHbgtj.png Image]&lt;br /&gt;
| ||Captain Trek, Tanman||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Jill||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/HbC3Rtj.png Image]&lt;br /&gt;
| All (directs and indirects alike) units gain firepower for each tile between its starting position and the target. CO powers either boost movement and fire range, or allow indirect units to move and fire on the same turn.|| XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above with slight mechanic changes, and both powers allow indirect units to fire and move on the same turn.||XnKradst || March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Joyce||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022 &lt;br /&gt;
|-&lt;br /&gt;
|Jun||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| || KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
| June||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/9adXZCr.png Image]&lt;br /&gt;
| Indirect units can counter enemy indirect attacks. Super CO power grants indirect units extra range depending on their terrain stars.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Indirect units deal more damage the further away the target is.||XnKradst||March 18th, 2022 &lt;br /&gt;
|-&lt;br /&gt;
|Kaga||[https://drive.google.com/file/d/15gwVMSd5_VTqXTB_DDwlT8Qho1CBsKU9/view?usp=sharing Standalone release]||[https://i.imgur.com/fMtVVrA.png Image]&lt;br /&gt;
| ||Nanoka||August 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Kairo||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/pAhw7Hi.png Image]&lt;br /&gt;
| Units deal more damage if they have more terrain stars than the target. Regular CO power causes enemy units to not benefit from terrain stars for a turn.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but with different CO powers; the superpower makes his units deal extra damage based on the enemy&#039;s terrain stars.||XnKradst ||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Katty ||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Keith||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Kidd||[https://drive.google.com/file/d/1zirDJbTfrTRJJQvHRfIU7BIeOV1lPtlR/view K&#039;Braid&#039;s COs]|| &lt;br /&gt;
| ||K&#039;Braid||March 19th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Kit||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Units cannot be killed in one hit. If a 10 HP unit suffers a one-hit kill, it instead survives with 1 HP left.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Koishi||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Kylie||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis|| December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Kyusoku||[https://drive.google.com/file/d/1uOPewGS05etwCSMwaDwvWUp-89289n9q/view?usp=sharing Silver Horizon (Older version)]|| &lt;br /&gt;
| ||ChemAtDark||July 2nd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Lazure||[https://drive.google.com/file/d/1GBSws0J81NuuzTNIQ6EcRfEMES--AG0W/view?usp=sharing Silver Horizon]||[https://i.imgur.com/QO9OJFD.png Image]&lt;br /&gt;
| ||ChemAtDark||May 5th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lee||[https://drive.google.com/file/d/1PcJkcvQwUOCrChR35enwqxG7ufKCXVyI/view?usp=sharing Standalone release]&lt;br /&gt;
| &lt;br /&gt;
| ||Brilliand||October 12th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Leona||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/YMOo2Mu.png Image]&lt;br /&gt;
| Damaged units deal 20% true damage if they have the same HP as the target, or they have exactly 7 HP left. If both conditions are met, deal 40% true damage.&lt;br /&gt;
CO powers hide her units&#039; HP for a turn, and also generally affects unit HP.&lt;br /&gt;
| XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Extremely high luck and misfortune, sometimes even healing the enemy when attacking. CO powers randomize all enemy units&#039; fuel, ammo and HP, the last of which is superpower-only.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Leopold||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/wuBRviU.png Image]&lt;br /&gt;
| ||Captain Trek||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lio||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/4DDPS0b.png Image]&lt;br /&gt;
| When an enemy unit destroys her units, that enemy unit is tagged with a special icon. All units deal more damage against tagged enemy units.|| XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but with different CO powers, and attacking a tagged unit untags them.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Lloyd Banning&lt;br /&gt;
|[https://drive.google.com/file/d/1jc8rITT_nQFrms4jNN2cpOXX8ndfFz93/view?usp=sharing Standalone release]&lt;br /&gt;
|[https://i.imgur.com/8ksuk3M.png Image]&lt;br /&gt;
|&lt;br /&gt;
|MrDuck557, ZERGRUSHER228&lt;br /&gt;
|Marth 27th 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Luce||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022 &lt;br /&gt;
|-&lt;br /&gt;
|Luke||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Lumi||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/Y79zD2w.png Image]&lt;br /&gt;
| Naval units, and everything else covered by their vision range, have increased firepower and defense. CO power spawns damaged submarines on her ports.&lt;br /&gt;
Naval units can also act immediately when built (one per port).&lt;br /&gt;
| XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Naval units can act immediately when built (one per port), but they have low firepower and defense. They are also cheaper.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Maelis||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Malkuth||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Man&amp;amp;ouml;ver||[https://drive.google.com/file/d/19bFp6UILiKDiZLY2725o69xRY7xeAZ2-/view?usp=sharing Epsilon COs]|| &lt;br /&gt;
| ||Eldritch||December 29th, 2021&lt;br /&gt;
|-&lt;br /&gt;
|Marie|| [https://drive.google.com/file/d/1fD7f_KHP8yAWGysd-J_23R41asgDPS4o/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Brilliand ||December 13th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Mario in a Kart||[https://drive.google.com/file/d/111SSJNKPbV-FuosKT31wZcdrr1N8tlKK/view?usp=sharing Mario Kart: The CO]||[https://i.imgur.com/XFGvHOZ.png Image]&lt;br /&gt;
| Based on Mario Kart. All units gain a random &amp;quot;item&amp;quot; at the start of his turn, which grants a variety of stats and effects.||XnKradst ||April 8th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Marisa ||[https://drive.google.com/file/d/1fr_dTx7f5P6Q7VCHwiCWOBwU5g4UZQTz/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Nanoka||November 4th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Maru||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Marysa L.||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/whxfxiG.png Image]&lt;br /&gt;
| ||SaMantaUwU||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──&lt;br /&gt;
|[https://drive.google.com/file/d/1JoYiTkUCI0dKvLqMQ40na9k0mSQ-Ao-C/view?usp=sharing Standalone version]||[https://i.imgur.com/yHfCEl1.png Image]&lt;br /&gt;
| ||SaMantaUwU||January 28th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mayden||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Units can over-promote to a fourth rank, granting 50% firepower and defense. CO zone and powers also promote her own units.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Mengsk||[https://drive.google.com/file/d/1jxGvpKJaJS1GAyWStFnBSWYvLajme6Ha/view?usp=sharing Standalone release]||[https://i.imgur.com/iKwCZvn.png Image]&lt;br /&gt;
| ||Nanoka||April 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mia||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Units have infinite ammo, but reduced fuel. Powers allow units to move again after attacking, but they cannot attack again.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Miho Nishizumi||[https://drive.google.com/file/d/1e-gkeDi26SXbqiXlz87byNqQl_HQQYXA/view?usp=sharing Standalone release]||[https://i.imgur.com/ClNMpLR.png Image]&lt;br /&gt;
| ||Nanoka||November 10th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mina||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/UwUAvfS.png Image]&lt;br /&gt;
| ||Sourdreemurr||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1_qS0TaGyws59_o-twJLR_ZhKnKOhLdxn/view?usp=sharing Standalone version]||[https://i.imgur.com/OJAsIK6.jpg Image]&lt;br /&gt;
| ||Sourdreemurr||August 2nd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Mizer||[https://drive.google.com/file/d/15dJwaSCzHO0XHVOcNbBlyT9T9s7a37A-/view?usp=sharing Standalone release]||[https://i.imgur.com/HqM6lkF.png Image]&lt;br /&gt;
| ||Nanoka||November 16th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Monarch||[https://drive.google.com/file/d/19bFp6UILiKDiZLY2725o69xRY7xeAZ2-/view?usp=sharing Epsilon COs]|| &lt;br /&gt;
| ||Eldritch||December 29th, 2021&lt;br /&gt;
|-&lt;br /&gt;
|Mr. Krabs||[https://drive.google.com/file/d/1nmLFvlR0ueWdrKXQnM-Zt37rE9tlX35W/view?usp=sharing Standalone release]||[https://i.imgur.com/sfGd5Ag.png Image]&lt;br /&gt;
| ||Hog||September 25th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mr. Yamamoto||[https://drive.google.com/file/d/1iIAVQiJFMukT06flThtfR7aOzhZECE-J/view?usp=sharing SFW COs]|| &lt;br /&gt;
| ||Creed||October 14th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Multiplier||[https://drive.google.com/file/d/18-FUmQxbaMsIuzZJONUT9McDoMsBFJCh/view?usp=sharing Standalone release]||[https://i.imgur.com/ylGOZlL.png Image]&lt;br /&gt;
| ||Hog ||June 24th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Myo||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Nadiyah||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/C81aG0I.png Image]&lt;br /&gt;
| ||Thae||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1BS6s4eH_ni3tklWiMRBdpZgUXxslZs5H/view?usp=sharing Standalone version]||[https://i.imgur.com/TjBHXDX.png Image]&lt;br /&gt;
| ||Thae||October 5th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Naked Squid||[https://drive.google.com/file/d/1z3ay_9mhM75RJi_Bf4rnEkhye3kcHvmb/view?usp=sharing Standalone release]||[https://i.imgur.com/2VXygOF.png Image]&lt;br /&gt;
| ||Nanoka||April 2nd, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Nana||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/9yNe7Il.png Image]&lt;br /&gt;
| Units paralyze the enemy if they are killed by counterattack. CO powers shot lasers from her buildings, which will paralyze the first enemy unit hit in each direction.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└── ||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but can only paralyze enemy units if inside her CO zone. Powers are stronger.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Nanami||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Nanoca||[https://drive.google.com/file/d/1BMizP-Vzs2jKlTe41UULV0qoL8S86N_y/view?usp=sharing Standalone release]||[https://i.imgur.com/PjvVhK1.png Image]&lt;br /&gt;
| ||Nanoka||January 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Nazrin||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Netzach||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Night||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Nue||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Nuki||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Oblivian Litleo ||[https://drive.google.com/file/d/1N1nU6U1g9KxFirZKBaklXCDXmgOZ_tRa/view?usp=sharing Imperial COs]|| &lt;br /&gt;
| ||DarkDespair ||December 7th, 2021&lt;br /&gt;
|-&lt;br /&gt;
|The Onceler||[https://drive.google.com/file/d/10cHtcD6ba71-X3iFOoCsani-c661p2Gp/view?usp=sharing Standalone release]|| &lt;br /&gt;
| || Brilliand||December 13th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Ophthalmia||[https://drive.google.com/file/d/1wuuXwiC68_yslNPwWsyTJ-Eld5kgc2Xv/view?usp=sharing The others Co mod]|| &lt;br /&gt;
| ||michale modelcitizen||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Osprey||[https://drive.google.com/file/d/1QY0UJ1M71E97yEfnLrLg56EFefAeof3L/view?usp=sharing Standalone release]||[https://i.imgur.com/y6ZklNb.png Image]&lt;br /&gt;
| All air units are equipped with long-range missiles, giving them +1 range. COP gives a nice ball of stats to allow for an early push, or you can opt for the SCOP to refresh units when they get a kill.|| MrDuck557||March 30th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Panavia||[https://drive.google.com/file/d/1yR-cdufPtctJan2UElGEHwTY7xDrKp4M/view?usp=sharing Tristia COs]|| &lt;br /&gt;
| ||Nanoka||October 19th, 2021&lt;br /&gt;
|-&lt;br /&gt;
|Pawke||[https://drive.google.com/file/d/1xT1vFusnoaEDhwZN47_wJF_0jKhn2wmn/view?usp=sharing Standalone release]||[https://i.imgur.com/IeQjn9a.png Image]&lt;br /&gt;
| ||FruityGum, MrDuck557||February 27th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Pearl ||[https://drive.google.com/file/d/1Q1HAjnSnXJ0NI5900qNF2nEj5Sz_NZqP/view?usp=sharing Standalone release]||[https://i.imgur.com/lDIlQtH.png Image]&lt;br /&gt;
| ||Namelessone||February 1st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Pearl||[https://drive.google.com/file/d/1xL2u2VocZoDOjKP7y8ryH8cfC632WmKo/view?usp=sharing Battalion CoW]|| &lt;br /&gt;
| ||Hamplmann||June 20th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|PenPen||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/QkmHRKz.png Image]&lt;br /&gt;
| || Go7||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Perses||[https://drive.google.com/file/d/1uOPewGS05etwCSMwaDwvWUp-89289n9q/view?usp=sharing Silver Horizon (Older version)]|| &lt;br /&gt;
| ||ChemAtDark||July 2nd, 2022 &lt;br /&gt;
|-&lt;br /&gt;
|Phoenix||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis ||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Pierce||[https://drive.google.com/file/d/1b_rMzpyoh-FEF-xTReUCv3aNdaSZxc6L/view?usp=sharing Anglo Isles CO mod]|| &lt;br /&gt;
| ||michale modelcitizen||April 4th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Polish ||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/00UwOvm.png Image]&lt;br /&gt;
| ||Captain Trek, ???|| August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Quinton||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Buildings damage enemy units at the start of his turns, but at the cost of the building&#039;s durability (if being captured).||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Ralph||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/7rfOP11.png Image]&lt;br /&gt;
| ||Captain Trek||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1BKQyqIoZCrIhhggPnxjXgN_tW-wZ42uZ/view?usp=sharing Standalone version]||[https://i.imgur.com/8eBU4Bl.png Image]&lt;br /&gt;
| ||Captain Trek||August 26th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rance ||[https://drive.google.com/file/d/1N1quhph_bCLJMAOIJa99xaGTvVpE19Na/view?usp=sharing Standalone release]||[https://i.imgur.com/z6uEozJ.png Image]&lt;br /&gt;
| ||Nanoka||December 29th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rapid||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rashelle ||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/ii4IX8U.png Image]&lt;br /&gt;
| ||Captain Trek, ???||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rayane||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rean Schwarzer||[https://drive.google.com/file/d/1HsazQ5CQf2-f4GKO_qKhZU7RJkQpg3D8/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Hog, ZERGRUSHER228||February 11th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Rick||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/5WXHzq0.png Image]&lt;br /&gt;
| Lower defense, but heals 1 HP to all of his units at the start of every turn.||XnKradst|| January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| More or less the same as above, only with slight number changes.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rick Harrison ||[https://drive.google.com/file/d/1LIBEiKQc2asFQG3EGiyBVuB4fAv4XjSs/view?usp=sharing Standalone release]||[https://i.imgur.com/ptalref.png Image]&lt;br /&gt;
| ||Thunderdoughnut|| January 27th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Riki|| [https://drive.google.com/file/d/16GSGcaVzW-YByqO77BnqNyhEFJUJ8qtQ/view?usp=sharing Advance Wars Whatever Mod]|| &lt;br /&gt;
| ||bajing_jalan_jalan||August 31st, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rina||[https://drive.google.com/file/d/10OYQ5y3uP4JEWEuLJdpq91DlFvWRDRMI/view?usp=sharing Standalone release]||[https://i.imgur.com/wJUFwPI.png Image]&lt;br /&gt;
| ||Nanoka||April 29th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rocky||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/WJtKA2o.png Image]&lt;br /&gt;
| High defense, but faster units have one less movement point.||XnKradst|| January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Mostly the same as above, but with a gimmicky superpower that converts all of his cities into custom &amp;quot;fortified&amp;quot; variants that only his own units can cross. They must be destroyed to be reverted to a normal town.|| XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rodger||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/Z0mkX53.png Image]&lt;br /&gt;
| ||Captain Trek, Niklas||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rooke||[https://drive.google.com/file/d/1L6rNvsFL96TRjzSPHSXqaHDraWOILp2A/view?usp=sharing Commander Wars - 1st CO Contest]||[https://i.imgur.com/DJp4RWz.png Image]&lt;br /&gt;
| ||Λvalon||February 5th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://drive.google.com/file/d/1QmFa3xRd9by9J3vfItkLAdV8yI0ge7JQ/view?usp=sharing Standalone version]||[https://i.imgur.com/1Crd7xU.png Image]&lt;br /&gt;
| ||Λvalon||September 7th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Rose ||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Sabrina||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Sakura||[https://drive.google.com/file/d/16GSGcaVzW-YByqO77BnqNyhEFJUJ8qtQ/view?usp=sharing Advance Wars Whatever Mod]|| &lt;br /&gt;
| ||bajing_jalan_jalan|| August 31st, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Sally||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/dNvQc4v.png Image]&lt;br /&gt;
| Units ignore damage below a certain threshold (chip damage). Super CO power renders all units invincible to everything except killing blows.||XnKradst||January 28th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| └──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Repairs cost half the price, and powers allowed her to gain funds from damage received. She still has the above version&#039;s super CO power.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Santa Sturm||[https://drive.google.com/file/d/11iM-LjYWCy946iQM0OmIzvlOUxelZH5p/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Tesla_Trooper||December 24th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Scroid||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Bases can deploy Oozium and a custom Parasite unit. Those units also have 1 more movement than normal. CO powers either buff or spawn more of those units.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Seargent Quackers&lt;br /&gt;
|[https://drive.google.com/file/d/1OyjrJ7GpjVXwqPVHQhfM8vBXYAmt1Snn/view?usp=sharing Standalone release]||[https://i.imgur.com/NtwWlGn.png Image]&lt;br /&gt;
| A duck that repairs. All you need to know.&lt;br /&gt;
Infantry and APCs can repair, and Black Boats repair 2hp instead of one. All repairs are half cost. COP makes all repairs more potent and free, and SCOP gives a refresh on top of that.&lt;br /&gt;
|MrDuck557||March 30th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Serena||[https://drive.google.com/file/d/1K26DVCK5EiIODwaOFUjwQROpOLs74raG/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||TheUberHunter||October 4th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Serg||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Snipers can pierce the armor of enemy vehicles, including helicopters.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Shaltear||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis&lt;br /&gt;
|December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Sheren||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Sidney||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Killing enemy units reduces the enemy player&#039;s funds, which can drop below 0 to the negatives (putting them in debt).||XnKradst ||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Silbergeist||[https://drive.google.com/file/d/1uOPewGS05etwCSMwaDwvWUp-89289n9q/view?usp=sharing Silver Horizon (Older version)]|| &lt;br /&gt;
| ||ChemAtDark||July 2nd, 2022&lt;br /&gt;
|-&lt;br /&gt;
|SKrlett||[https://drive.google.com/file/d/1cxYLlWCmvNLGPMsMtIPbJhxG6U8Nk81u/view?usp=sharing KTeknis Projects (Older version)]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||April 23rd, 2022 &lt;br /&gt;
|-&lt;br /&gt;
|Sol||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Slightly stronger during sunny weather, slightly weaker otherwise. CO powers grant several major stat boosts at once (firepower, defense, movement, fire range, vision, capture points, unit discounts).||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Sonny||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/3Yfp9ku.png Image]&lt;br /&gt;
| Attacks heal the allied unit behind the attacker. CO powers make his attacks deal collateral damage to all enemy units behind the target in a straight line, range depending on power.||XnKradst||January 28th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| └──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as the above, but CO powers deal more damage at the cost of losing terrain stars on most terrain.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Sophia||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/lLYODSP.png Image]&lt;br /&gt;
| ||Captain Trek, Quentcat||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Soraya||[https://drive.google.com/file/d/11UUWFRcv2DwEt4TwUdwZeP5uJ_J0jQQm/view?usp=sharing Standalone release]||[https://i.imgur.com/qNlDB6l.png Image]&lt;br /&gt;
| || ruigio||October 27th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Splitting Slime||[https://drive.google.com/file/d/1TlpgIC5hZ2eCyVLRs10SK-1moFyNvw9M/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Brilliand||October 29th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Surge ||[https://drive.google.com/file/d/1fMb8YTsvbk6BlFrH3tm4zA_VIli2aUON/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Brilliand, I_Am_Jarvis|| October 30th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Syrene||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis|| December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Talas||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tapper||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]&lt;br /&gt;
|[https://i.imgur.com/OuXt63s.png Image]&lt;br /&gt;
| ||Captain Trek, Shaw Fujikawa||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Tara||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/3DAmMnv.png Image]&lt;br /&gt;
| ||Captain Trek, ???||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|TCM&lt;br /&gt;
|[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Teki|| [https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tempest||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis, Marmalad||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tenshi||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tepho||[https://drive.google.com/file/d/1H1hzw10AnLkwm-g0NfVT4SCMHVWEK5lQ/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||MrDuck557, ZERGRUSHER228||January 21st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Tesla||[https://drive.google.com/file/d/18pDeNt4g6Stzdl86ZTvIQwBBxvdcUEQw/view?usp=sharing Standalone release]||[https://i.imgur.com/vIEEDhF.png Image]&lt;br /&gt;
| ||Nanoka, MrDuck557||January 24th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Tiphereth&lt;br /&gt;
|[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tomasu||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/cnFjRdQ.png Image]&lt;br /&gt;
| Start every turn with firepower slightly below average. Every time a unit is ordered to wait, his firepower rises. Every time a unit attacks, his firepower resets (after the attack).||XnKradst||January 28th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| └──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Stealth units cost less and are stronger, but foot soldiers are weaker. CO powers grant movement to all units and allow them to pass enemy units.||XnKradst||March 18th, 2022 &lt;br /&gt;
|-&lt;br /&gt;
| Tondra||[https://drive.google.com/file/d/1QS0OGCeMcONR9k9Nd7e60XDRmqpcmcTI/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Nanoka, Omega||March 30th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Troy||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/49d4slF.png Image]&lt;br /&gt;
| Has the ability to trick the enemy by deploying &amp;quot;decoy&amp;quot; variants of some units (light tank, artillery, anti-air and battle copter), all at the price of 3000. These decoys move slower, cannot attack and are destroyed in one hit. CO powers either allow more decoy deployments, or convert decoys into real units.||XnKradst||January 28th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| └──&lt;br /&gt;
|[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Has the ability to deploy &amp;quot;Spy&amp;quot; units, which are infantry that can use stealth, but weaker in combat. CO powers spawn more spies in random places.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tucker||[https://drive.google.com/file/d/1xL2u2VocZoDOjKP7y8ryH8cfC632WmKo/view?usp=sharing Battalion CoW]|| &lt;br /&gt;
| ||Hamplmann||June 20th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Tyke||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Tynia||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/USHDqrl.png Image]&lt;br /&gt;
| Ground units (except foot soldiers) have an extra movement point if starting on a production facility or road tile. CO powers make her units deal more damage per terrain star traversed before attacking.||XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| All ground vehicles including motorbikes have improved firepower and movement across all terrain. Super CO power kills the enemy&#039;s most expensive unit instantly.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
| Umi||[https://drive.google.com/file/d/1frd3DlcRmIyirjj9GdqKlhfjaVoyWxx9/view?usp=sharing Standalone release]||[https://i.imgur.com/lYOtTmv.png Image]&lt;br /&gt;
| ||Nanoka||March 1st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Visor||[https://drive.google.com/file/d/1XJ9qpPpj4ucHjtCryFmTD5irFQbShEUz/view?usp=sharing The Overlooked Ones]||[https://i.imgur.com/6BF4oUH.png Image]&lt;br /&gt;
| ||Captain Trek, boiyouthought98||August 4th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Walder||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Windsor|| [https://drive.google.com/file/d/1b_rMzpyoh-FEF-xTReUCv3aNdaSZxc6L/view?usp=sharing Anglo Isles CO mod]|| &lt;br /&gt;
| ||michale modelcitizen||April 4th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Xander||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/613P1vb.png Image]&lt;br /&gt;
| Deployed units can immediately act, allowing the same base to deploy as many units as he can afford. All units have more firepower but significantly less defense.&lt;br /&gt;
CO powers reduce deployment costs.&lt;br /&gt;
|XnKradst||January 28th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| └──||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but with more ridiculously overpowered stats.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Xanderbot||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/BPDgAkj.png Image]&lt;br /&gt;
| New version of Error (see above).&lt;br /&gt;
Changes stats and powers to a randomly chosen CO out of the 26 Xanari Crew COs (from the remake) at the start of every turn.&lt;br /&gt;
| XnKradst||January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Xiao||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Xingqiu||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Yesod||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| ||KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Youmu||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Yune||[https://drive.google.com/file/d/1guC8D2-C8hfl4hvNYTEYa6U5HOQfND2W/view KTeknis Projects]|| &lt;br /&gt;
| || KesalahanTeknis||December 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Zaiu||[https://drive.google.com/file/d/1n33aVqoy9uVDC7nR-to8dQa35Y98Dly7/view?usp=sharing Xanari Crew (Remake/AW2)]||[https://i.imgur.com/9ufaR6Z.png Image]&lt;br /&gt;
| Perfect vision at the cost of slightly lower vision range. CO powers grant him temporary control of enemy units.||XnKradst|| January 28th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|└──&lt;br /&gt;
|[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| Same as above, but powers gain permanent control of enemy units.||XnKradst||March 18th, 2022&lt;br /&gt;
|-&lt;br /&gt;
|Zhongli||[https://mega.nz/file/pwoxXL4Y#oy79ceCRPQur_Hr4Fn4HyGSS8yCl8u1EkxfBDS3Mzxg Tsubaki mods]|| &lt;br /&gt;
| ||shirone222||September 27th, 2022 &lt;br /&gt;
|-&lt;br /&gt;
|Zuza||[https://www.mediafire.com/file/czr387mrs7w7d0l/CoW_Xanari_Crew_ver12_1.zip/file Xanari Crew (Original)]|| &lt;br /&gt;
| If units die in one hit, 75% of the funds spent deploying them is refunded. CO powers make all living units generate more money.||XnKradst||March 18th, 2022&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==List of KnightLord COs created for Commander Wars==&lt;br /&gt;
Last Updated: April 12th, 2024&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!Name (Non OCs/OCs)!!Mod!!Image / Dossier&lt;br /&gt;
!Description!!Creator(s)!!Last Updated&lt;br /&gt;
|-&lt;br /&gt;
|Aaron (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Abby (OC) &lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Admiral Wiler (Langrisser 4 &amp;amp; 5)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Adon (Choi Aniki &amp;amp; Langrisser series)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Agana (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Agent #7 (Tsukihime 2000 &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Agnes (Trails Through Daybreak)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ainz (OverLord Anime)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Airi (OC) &lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th 2024&lt;br /&gt;
|-&lt;br /&gt;
|Akatsuki (UNIB &amp;amp; Akatsuki Blitzkampf)|| [https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| || Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Akiha (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Akihiko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Akuhei (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Akira (OC)|| [https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Albedo (Overlord Anime)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Albert (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Alfred (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Alicia (Valkyria Chronicles)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Alina (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Alma (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Altemuller (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Altera (Fate/Grand Order)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Altina (Trails Cold Steel series)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Alustriel (Langrisser Mobile)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ami (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| || Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Amenozako (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ange (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Angelica (Langrisser Mobile) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Angelina (Langrisser 4 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Anna (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ansel (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07 || December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Aoko (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse] || &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Aoi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Arcueid (Tsukihime &amp;amp; Melty Blood)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Arcueid wearing neko suit (Tsukihime 2000 &amp;amp; Joke) &lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Archetype: Earth (Tsukihime &amp;amp; Melty Blood)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ares (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Arianrhod (Trails series)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Artoria Alter (Fate/Stay Night: Heaven Feel)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Artoria Lily (Fate/Unlimited Code)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Artoria Pendragon (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Asa (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ashram (Record of Lodoss War)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Asne (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Asuka (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Asuna (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Autokrato IV (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ayako&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ayami&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ayla (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Ayuka (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Battler (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Bazett (Fate/Hollow Atarxia)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Belne (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Bernhardt (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Betty (Langrisser 1 Remake)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Bianca (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Big Nobu (Fate/Grand Order &amp;amp; Joke)&lt;br /&gt;
| [https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Blood Cougher Okita Souji (Fate/Grand Order &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Borys (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Boris (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Bozel (Langrisser series)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Brainwash Detective Hisui (Tsukihime 2000 &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Brenda (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Bukko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Byakuya (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Calista (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Camille (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Camu (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Caren (Fate/Hollow Atarxia) ||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Carmine (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Carol (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Chad Sanshiro (Project X Zone 2 &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Cherie (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Chie (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Chika (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Chinatsu (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Chiyo (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Chris (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Christiane (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ciel (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07 ||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Clarett (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Claire (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Constanta (Langrisser Re:Incarnation Tensei)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Cu Chulainn (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Culture Spreader Oda Nobunaga (Fate/Grand Order &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Dae (OC)&lt;br /&gt;
| [https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Dai (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Danta (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|Firepower &amp;amp; defense per tiles moved&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Dark Sakura (Fate/Stay Night: Heaven Feel)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Deedlit (Record of Lodoss War)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Diarmuid (Fate/Umlimited Code &amp;amp; Fate/Zero)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Diego (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Dieharte (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Digos (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Dios (Langrisser 3) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Do Kahni (Langrisser 3)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Dust (Melty Blood Actress Again)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Edward (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Egbert (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Elaine (Trails through Daybreak)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Elizabeth (OC)|| [https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Elma (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Eltnum (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| || Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Elwin (Langrisser 2) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Emerick (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Emi (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07|| December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Emika (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Emiko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Emma (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Enkidu (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Eri (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv%20Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Eriko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Eric (OC)&lt;br /&gt;
| [https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Est (Langrisser 2) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Estelle (Trails series)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Eva (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Excella (Shining Resonance)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Fauvel (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Featuring Dante From Devil May Cry (Devil May Cry series &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Fen (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Feraquea (Langrisser 3 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Finn (OC) &lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Florentia (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Freya (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Fuji (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Futaba (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Fuyuko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Gawain (Fate/Extra)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Geese Howard (KOF series)||[https://drive.google.com/file/d/1BE4n71tmlYvtL78EwbJkRRIvXModKZ62/view?usp=sharing Standalone release]||[https://i.imgur.com/beKGSQs.png Image]&lt;br /&gt;
| ||Knightlord07||April 12th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Gerold &amp;amp; Layla (Langrisser Mobile &amp;amp; Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07 || October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Gilbert (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Gilgamesh (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ginko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Gintoki (Gintama)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Gizarof (Langrisser 4 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Gordeau (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Greta (OC)&lt;br /&gt;
| [https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Gudako (Learning FGO Manga &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Gunther (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Gustaf (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hae (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Hammer (Castlevania: Aria &amp;amp; Dawn of Sorrow)||[https://drive.google.com/file/d/1dprfKbgHEOQ__jQe3eAWZtjx6K-zMadV/view?usp=sharing Standalone release]||[https://i.imgur.com/H59xMzc.png Image]&lt;br /&gt;
| ||Knightlord07|| May 13th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Haruhi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Haruka (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Haruyi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Haunted Astolfo Plushie (Meme)&lt;br /&gt;
| [https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Hawking (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Hein (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Helena (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix] || &lt;br /&gt;
| ||Knightlord07||December 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Heracles (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Hisae (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Hiei (Yu Yu Hakusho)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hilda (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hilda (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Himiko (Mashin Hero Wataru)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hinako (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hisui (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Hiyori (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Honoka (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Hotaru (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Hyde (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ichika (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|IIIyasviel (Fate/Stay Night)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| || Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Imelda (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Iori (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Iris (Sakura Wars)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Isara (Valkyria Chronicles)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Iseul (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Ivar (Langrisser 4)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ixqui (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Jeanne (Fate/Apocrypha &amp;amp; Fate series) ||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Jessica (Umineko) ||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07 ||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Jessica (Langrisser series)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Jill (OC)&lt;br /&gt;
| [https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Joa (Langrisser Re:Incarnation)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Johnny (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Joshua (Trails series)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Jugler (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Julian (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Juri (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|JuWon (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07|| November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Kagura (Gintama)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kako (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Kalina (Girls&#039; Frontline &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kana (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Karl (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Karin (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Kasumi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Katsuko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kawai (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Kayura (Legendary Armor Samurai Trooper)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| || Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kazuma (Yu Yu Hakusho)|| [https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kei (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs] || &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Keiko (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Keith (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Kertesz (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ki (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kirei (Fate/Stay Night) ||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse] || &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kirika (Shining Resonance)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kirikaze (Langrisser 3) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kishyami (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kiyoko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Klose (Trails series)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Knight of Mystery (Langrisser Mobile &amp;amp; Langrisser 4 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Knightlord07 (Discord member)||[https://drive.google.com/file/d/1UjrgeGmJX7wUTWKg4Xwa2kPc9gKbHk6W/view?usp=sharing Standalone release]||[https://i.imgur.com/N0t7BrO.png Image]&lt;br /&gt;
| || Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Kohaku (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Koharu (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Komako (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Konomi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kouma (Kagetsu Tohya &amp;amp; Melty Blood)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| || Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kruger (Langrisser 4)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kunio (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kuon (UNIB) ||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kurama (Yu Yu Hakasho)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Kurami (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kwan (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Kyle (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kyoko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Kyrie (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Laetitia (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Laias (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Lainforce (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Laird (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lambda (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Lana (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lance (Langrisser 1) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Landius (Langrisser 4 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ledin (Langrisser 1 &amp;amp; 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Leion (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07|| December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Len (Kagetsu Tohya &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lenon (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Leon (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Leonhardt (Trails of the Sky series)&lt;br /&gt;
|[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Leopold Goenitz (KOF series)||[https://drive.google.com/file/d/1ZvoEp6txHrxWzOhiqHg-MdyWmaPzixdU/view?usp=sharing Standalone release]||[https://i.imgur.com/ZKWPp2j.png Image]&lt;br /&gt;
| ||Knightlord07 ||September 3rd, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lester (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Letitia (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Lewin (Langrisser 3) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Leysritt (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Liana (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Liang (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Licorice (Langrisser Re:Incarnation)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| || Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Liffany (Langrisser 3) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Light of Genesis (Langrisser Mobile &amp;amp; Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lina (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix] || &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Linne (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Listell (Langrisser 4)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Londrekia (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| || Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lucia (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07 ||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lucretia (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lucy (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix] || &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lufu (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Lugner (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Luna (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Lunon (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07|| December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Luviagelita (Fate/Hollow Atarxia)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Maaya (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Madoka (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Magical Amber (Fate/Tiger Colosseum Upper, Tsukhime &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Mai (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Maiya (Langrisser Re:Incarnation)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Makoto (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Manon (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| || Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Marcus (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix] || &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mari (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Mariel (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Mash (Fate/Grand Order)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Masuyo (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|McClaine (Langrisser 4 &amp;amp; 5)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| || Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mecha Hisui (Melty Blood)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Medea (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Medusa (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Merkava (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Michael (Tsukihime &amp;amp; Melty Blood)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Michel (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Michie (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Mika (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mina (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Minako (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mini Nobu (Fate/Grand Order &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Mio (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Mion (Higurashi)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| || Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Misako (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Miyako (Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Mizuki (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Mizuko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Momoko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Mutsumi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Nagya (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Naoko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Narm (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Nasase (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| || Knightlord07||November 15th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Natsuhi (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Neco Arc (Tsukihime &amp;amp; Melty Blood) ||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Neco Arc Chaos (Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Nero (Fate/Extra)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07 ||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Newspaper Miyako (Melty Blood &amp;amp; Joke)&lt;br /&gt;
| [https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Nicolis (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|No Name (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Noel&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Noemi (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| || Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Nrvnqsr (Tsukihime &amp;amp; Melty Blood)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Null (Langrisser 4)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Odilon (Langrisser Re:incarnation Tensei)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Oiwa (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Olivier (Trails series)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Omega (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ophelia (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|OP Vergil (Devil May Cry series &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Orie (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| Hordes||Knightlord07||November 15th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Ost (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Padoru (Fate/Extra)||[https://drive.google.com/file/d/1uat2yf00ZvXfT_55kaWuF9uIRLunZePg/view?usp=sharing Standalone release]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Parn (Record of Lodoss War)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Patsyr (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Pierre (Langrisser 3)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Pilk Seller Neco Arc (Tsukihime &amp;amp; Melty Blood Remake &amp;amp; Joke) &lt;br /&gt;
| [https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 1st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Pirotess (Record of Lodoss War)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Polyal (Langrisser Re:Incarnation Tensei)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Power Ciel (Tsukihime &amp;amp; Melty Blood)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Rachel (Langrisser 4)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rakumei (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ranford (Langrisser 4 &amp;amp; 5)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Red Arcueid (Melty Blood)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Rean (Trails of the Cold Steel Series)|| [https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rei (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Reina (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Rena (Higurashi)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Renata (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Renne (Trails series)|| [https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rie (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ricky (Langrisser 4) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Riesbyfe (Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rika (Higurashi)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Rinko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Rin (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rin Tohsaka on a Pink Car (Fate/Stay Night &amp;amp; Joke)&lt;br /&gt;
| [https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Robo Colonel Sander (Langrisser Mobile &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Rohga (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rona (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Rosa (Umineko) ||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix] || &lt;br /&gt;
| ||Knightlord07||December 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Rosetta (OC) ||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Rozalia (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Rozenciel (Langrisser Mobile &amp;amp; Langrisser 4 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ryo (Legendary Armor Samurai Troopers)|| [https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ryo (OC)&lt;br /&gt;
| [https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Ryu (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ryuji (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sacchin but isn&#039;t it sad Sacchin (Tsukihime &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
| April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sakura (Sakura Wars)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sakura (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sam (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Samson (Choi Aniki &amp;amp; Langrisser series)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sanae (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sanon (Umineko)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sasaki (Fate/Stay Night)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07|| October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Satsuki (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Scathach (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07 ||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Scathach (Fate/Grand Order)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Scott (Langrisser 2)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07&lt;br /&gt;
|October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Seiba Lion (Fate/Tiger Colosseum &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Seiba on a Lion (Fate/Stay Night &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Seikyo (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Seishi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Senpai food lover Sakura (Fate/Stay Night &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Sensei Ciel Curry Maker (Tsukihime &amp;amp; Melty Blood Remake &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Seo (OC) &lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Selvaria (Valkyria Chornicle)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Serena (Langrisser 4)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Serena (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Seth (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Setsuko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Setsuna (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Shalltear (Overlord Anime)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shannon (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07|| November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shelfaniel (Langrisser 4 &amp;amp; 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shibaraku (Mashin Hero Wataru)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shigo (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Shiin (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Shilinka (Langrisser Mobile)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shiki (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07 ||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shiki Nanaya (Kagetsu Tohya &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shiki Ryougi (Melty Blood Actress Again)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shiki Tohno (Tsukihime &amp;amp; Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shinji (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shinpachi (Gintama)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023 &lt;br /&gt;
|-&lt;br /&gt;
|Shion (Higurashi)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Shiori (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Shirou (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023 &lt;br /&gt;
|-&lt;br /&gt;
| Shoten (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sieghart (Langrisser 3 &amp;amp; 2)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sigma (Langrisser 5)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Silver Wolf (Langrisser 3)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sion (Melty Blood)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| || Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sion TATARI (Melty Blood)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sissi White (Langrisser Mobile)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sokushi (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sonia (Shining Resonance)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07 ||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sonia (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sonya (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sophia (Langrisser 3)&lt;br /&gt;
|[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Sora (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07||December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Souichirou (Fate/Stay Night)|| [https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Strange Foreigner (Street Fighter 2 &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Sunako (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Super Smart Eltnam (Melty Blood &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Sumire (Sakura Wars)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Suzette (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Taiga (Fate/Stay Night)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse]|| &lt;br /&gt;
| ||Knightlord07|| October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Taiga on a Tiger Tank (Fate/Stay Night &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024 &lt;br /&gt;
|-&lt;br /&gt;
| Takeru (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Taylor (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Theresa Apocalypse (Honkai Impact 3rd &amp;amp; Joke)||[https://drive.google.com/file/d/1fJ2PcK301so_MOuHc-aLShhQ8Iu-cQdn/view?usp=sharing Standalone release]||[https://i.imgur.com/prekBzv.png Image] &lt;br /&gt;
| ||Knightlord07||April 13th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Thorn (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Thumb Down Akiha (Tsukihime 200 &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Tiaris (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| || Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Toguro (Yu Yu Hakusho)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Toma (Legendary Armor Samurai Troopers)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Towa (Langrisser Re:Incarnation Tensei) ||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Tsundere Jalter (Fate/Grand Order &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Tsubaki (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
| Tsubasa (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|Naval units into land tiles&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024 &lt;br /&gt;
|-&lt;br /&gt;
|Tsubame (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Tsurugi (UNIB) ||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Ultimate Fumo (Touhou &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Valan (Langrisser series)|| [https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07|| October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Van (Trails through Daybreak)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Vanessa (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Vargas (Langrisser 2)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Varna (Langrisser 3)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Vatista (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Vera (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07 ||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Virash (Langrisser 5)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Vermillion Akiha (Melty Blood)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Volkoff (Langrisser 1)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 1] || &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Wagner (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Waldstein (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
| Wanna play some KOF (KOF &amp;amp; Joke)&lt;br /&gt;
|[https://drive.google.com/file/d/1_dLZPct3ns8jeGuf5DDyYpQ167JiR4Fc/view April Fool&#039;s]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 1st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Warui (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul] &lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Wataru (Mashin Hero Wataru)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Werner (Langrisser Re:Incarnation Tensei)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 2]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|White Len (Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse] || &lt;br /&gt;
| ||Knightlord07||October 31st, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Wilhelm (OC)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|William (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Yami (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Yoshiko (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs] || &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Yui (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Yuna (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1zM0ybz8E7J4nvpOLMJ3p6j2jxWtWlm7j/view KL07&#039;s Main Mods Overhaul]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|January 31st, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Yuki (OC)||[https://drive.google.com/file/d/1u4dedGsx0JWVbLEmmEkGBVRftqBpvUHh/view KL07&#039;s Origin Mix]|| &lt;br /&gt;
| ||Knightlord07|| December 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Yulia (Langrisser Mobile)||[https://drive.google.com/file/d/1fm69FaPuCDTxpzS9KvuHNewer_sY20iX/view Langrisser Vol. 3]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Yuri (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|Convert units&lt;br /&gt;
|Knightlord07 &lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Yuriko (OC)&lt;br /&gt;
|[https://drive.google.com/file/d/1F3ZAoyXkCNTEjghfPv+Ly55ptvnJXKZM/view OCs Rival]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|Knightlord07&lt;br /&gt;
|April 12th, 2024&lt;br /&gt;
|-&lt;br /&gt;
|Yusuke (Yu YU Hakusho)||[https://drive.google.com/file/d/1Gzo3tLo8RH_9f7uA7VRZqQjjWg5-rxrg/view Langrisser Mobile Collabs]|| &lt;br /&gt;
| ||Knightlord07||October 9th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Yuzuriha (UNIB)||[https://drive.google.com/file/d/1g67JGlWUtauia1lehRFGurKyVmrbs03f/view KL07&#039;s OCs]|| &lt;br /&gt;
| ||Knightlord07||November 15th, 2023&lt;br /&gt;
|-&lt;br /&gt;
|Zepia (Melty Blood)||[https://drive.google.com/file/d/1i1bSSqae7Gg7GVobJgascbuXI7sbGHni/view Nasuverse] || &lt;br /&gt;
| ||Knightlord07|| October 31st, 2023&lt;br /&gt;
|}Link to those cos in these page&lt;br /&gt;
* [[Langrisser Vol1|Langrisser Vol 1]] (Advancegrisser)&lt;br /&gt;
*[[Langrisser Vol2|Langrisser Vol 2]] (Advancegrisser)&lt;br /&gt;
*[[Langrisser Vol3|Langrisser Vol 3]] (Advancegrisser)&lt;br /&gt;
*[[Langrisser Mobile Collabs|Langrisser Collab]]&lt;br /&gt;
*[[Nasuverse]] (Type Moon)&lt;br /&gt;
*[[KL07&#039;s OCs]]&lt;br /&gt;
*[[KL07&#039;s Origin Mix]]&lt;br /&gt;
*[[KL07&#039;s Final OCs|KL07&#039;s Final]]&lt;br /&gt;
*[[KL07&#039;s April Fools|April Fools]]&lt;br /&gt;
*[[KL07&#039;s OCS Rival Cos|OCs Rivals]]&lt;br /&gt;
[[Category:Mods]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Mods]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3990</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3990"/>
		<updated>2023-12-31T16:12:42Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Links go to master branch now&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/general/animation.js]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/master/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3.  &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID() !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;br /&gt;
&lt;br /&gt;
What a long winded way of explaining 4 lines of code.&lt;br /&gt;
&lt;br /&gt;
== Bio, Description, and Details ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;239&amp;quot;&amp;gt;&lt;br /&gt;
    // CO - Intel&lt;br /&gt;
    this.getBio = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;A whiz with a wrench, this mechanical boy wonder earned fame as the hero who saved Macro Land in the last great war.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Now we get to the CO information. This just returns a string. What&#039;s interesting is the use of the function qsTr. This converts the string into a format that&#039;s easier to display, so just put it around the test you&#039;re displaying and you&#039;re good to go.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;244&amp;quot;&amp;gt;&lt;br /&gt;
    this.getHits = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Mechanics&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getMiss = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Waking up too early&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getCODescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;No real weaknesses or strengths. Ready to fight wherever and whenever.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;More bio.&lt;br /&gt;
&lt;br /&gt;
getCODescription is where you&#039;ll put a short description of your CO. Nothing long and no numbers, just tell the user the basics. Also useful for more flavor text.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;256&amp;quot;&amp;gt;&lt;br /&gt;
    this.getLongCODescription = function()&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;\nSpecial Unit:\nRepair Tanks\n&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\nGlobal Effect: \nNone.&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\n\nCO Zone Effect: \nAndy&#039;s units gain +%0% firepower and +%1% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.d2dCoZoneOffBonus, CO_ANDY.d2dCoZoneDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Predictably, the long CO description, but this time with numbers!&lt;br /&gt;
&lt;br /&gt;
var text is just a temporary placeholder, the name isn&#039;t important&lt;br /&gt;
&lt;br /&gt;
You can join strings to each other with the + operator. You don&#039;t have to do this, but here it makes the text easier to read (code-side, there should be no difference on screen). \n is the newline symbol, which makes a newline. You can get more info on strings on google.&lt;br /&gt;
&lt;br /&gt;
What&#039;s the %0% doing in the string? It&#039;s used by the replaceTextArgs to substitute the proper bonus numbers into the description. Specifically, %0% says &amp;quot;insert the thing in index 0 of the list of objects here&amp;quot;. In this case, it&#039;s easy to see that CO_ANDY.d2dCoZoneOffBonus is the first object in the list. Similar idea with %1%.&lt;br /&gt;
&lt;br /&gt;
Doing this rather than hardcoding the numbers into the string makes it easier to change the stats of the CO without messing up the description. You can hardcode the numbers if you like, just remember they&#039;re there.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;264&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%1% firepower and +%2% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.powerHeal, CO_ANDY.powerOffBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Repair&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Power description and power name. What else is there to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;274&amp;quot;&amp;gt;&lt;br /&gt;
    this.getSuperPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%2 movement, +%1% firepower, and +%3% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.superPowerHeal, CO_ANDY.superPowerOffBonus, CO_ANDY.superPowerMovementBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getSuperPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Upgrade&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The super power. Spicy I know&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;284&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;I&#039;ve got parts to spare!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not giving up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Time to roll up my sleeves!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I haven&#039;t even cranked the engine yet!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Pass me my wrench!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;It&#039;s time for a tune-up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Never give up, and never lose! I&#039;m on my way!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not worried! I can fix anything!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When you use a power, the CO says something before actually using it. What that something is comes from here.&lt;br /&gt;
&lt;br /&gt;
Just return a list of strings (using []), the hard part is thinking of what to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;295&amp;quot;&amp;gt;&lt;br /&gt;
    this.getVictorySentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;We won! Woohoo!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I can fix anything!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I did it! Did you see that!?&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
    this.getDefeatSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;Oh, come on!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Next time I see you, you&#039;re in trouble!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;There are a surprising number of words that go into making a CO aren&#039;t there?&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;306&amp;quot;&amp;gt;&lt;br /&gt;
    this.getName = function()&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Andy&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Just to confirm, we are in fact looking at Andy&#039;s code.&lt;br /&gt;
&lt;br /&gt;
Also the closing bracket of the original Constructor function. How long ago was that?&lt;br /&gt;
&lt;br /&gt;
== Footer ==&lt;br /&gt;
Now for two vital lines of code:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;312&amp;quot;&amp;gt;&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_ANDY = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We set the type of constructor to CO. This tells COW that this is a CO and not some weirdly shaped unit.&lt;br /&gt;
&lt;br /&gt;
Then we set the var CO_ANDY to a new instance of Constructor. This makes CO_ANDY and actual CO object, and not just the blueprints of how to make Andy. CO_ANDY is where COW (and other scripts) will reference your CO from now on. &lt;br /&gt;
&lt;br /&gt;
And with those two lines, we are finished!&lt;br /&gt;
&lt;br /&gt;
== Endnote ==&lt;br /&gt;
If you made it to the end, congrats! You now know the details of how Andy&#039;s code works and (hopefully) how to make your own.&lt;br /&gt;
&lt;br /&gt;
What&#039;s that? You don&#039;t know how to make stuff affect different kinds of units?&lt;br /&gt;
&lt;br /&gt;
Uh...&lt;br /&gt;
&lt;br /&gt;
Maybe I should do this for Max as well.&lt;br /&gt;
&lt;br /&gt;
Anyways, that&#039;s it for this guide. Have a nice day!&lt;br /&gt;
[[Category:Modding tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3988</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3988"/>
		<updated>2023-12-31T13:17:01Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Sami&amp;#039;s code incorrect, fixed&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3. &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID() !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;br /&gt;
&lt;br /&gt;
What a long winded way of explaining 4 lines of code.&lt;br /&gt;
&lt;br /&gt;
== Bio, Description, and Details ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;239&amp;quot;&amp;gt;&lt;br /&gt;
    // CO - Intel&lt;br /&gt;
    this.getBio = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;A whiz with a wrench, this mechanical boy wonder earned fame as the hero who saved Macro Land in the last great war.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Now we get to the CO information. This just returns a string. What&#039;s interesting is the use of the function qsTr. This converts the string into a format that&#039;s easier to display, so just put it around the test you&#039;re displaying and you&#039;re good to go.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;244&amp;quot;&amp;gt;&lt;br /&gt;
    this.getHits = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Mechanics&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getMiss = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Waking up too early&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getCODescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;No real weaknesses or strengths. Ready to fight wherever and whenever.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;More bio.&lt;br /&gt;
&lt;br /&gt;
getCODescription is where you&#039;ll put a short description of your CO. Nothing long and no numbers, just tell the user the basics. Also useful for more flavor text.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;256&amp;quot;&amp;gt;&lt;br /&gt;
    this.getLongCODescription = function()&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;\nSpecial Unit:\nRepair Tanks\n&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\nGlobal Effect: \nNone.&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\n\nCO Zone Effect: \nAndy&#039;s units gain +%0% firepower and +%1% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.d2dCoZoneOffBonus, CO_ANDY.d2dCoZoneDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Predictably, the long CO description, but this time with numbers!&lt;br /&gt;
&lt;br /&gt;
var text is just a temporary placeholder, the name isn&#039;t important&lt;br /&gt;
&lt;br /&gt;
You can join strings to each other with the + operator. You don&#039;t have to do this, but here it makes the text easier to read (code-side, there should be no difference on screen). \n is the newline symbol, which makes a newline. You can get more info on strings on google.&lt;br /&gt;
&lt;br /&gt;
What&#039;s the %0% doing in the string? It&#039;s used by the replaceTextArgs to substitute the proper bonus numbers into the description. Specifically, %0% says &amp;quot;insert the thing in index 0 of the list of objects here&amp;quot;. In this case, it&#039;s easy to see that CO_ANDY.d2dCoZoneOffBonus is the first object in the list. Similar idea with %1%.&lt;br /&gt;
&lt;br /&gt;
Doing this rather than hardcoding the numbers into the string makes it easier to change the stats of the CO without messing up the description. You can hardcode the numbers if you like, just remember they&#039;re there.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;264&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%1% firepower and +%2% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.powerHeal, CO_ANDY.powerOffBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Repair&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Power description and power name. What else is there to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;274&amp;quot;&amp;gt;&lt;br /&gt;
    this.getSuperPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%2 movement, +%1% firepower, and +%3% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.superPowerHeal, CO_ANDY.superPowerOffBonus, CO_ANDY.superPowerMovementBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getSuperPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Upgrade&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The super power. Spicy I know&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;284&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;I&#039;ve got parts to spare!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not giving up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Time to roll up my sleeves!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I haven&#039;t even cranked the engine yet!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Pass me my wrench!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;It&#039;s time for a tune-up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Never give up, and never lose! I&#039;m on my way!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not worried! I can fix anything!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When you use a power, the CO says something before actually using it. What that something is comes from here.&lt;br /&gt;
&lt;br /&gt;
Just return a list of strings (using []), the hard part is thinking of what to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;295&amp;quot;&amp;gt;&lt;br /&gt;
    this.getVictorySentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;We won! Woohoo!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I can fix anything!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I did it! Did you see that!?&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
    this.getDefeatSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;Oh, come on!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Next time I see you, you&#039;re in trouble!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;There are a surprising number of words that go into making a CO aren&#039;t there?&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;306&amp;quot;&amp;gt;&lt;br /&gt;
    this.getName = function()&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Andy&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Just to confirm, we are in fact looking at Andy&#039;s code.&lt;br /&gt;
&lt;br /&gt;
Also the closing bracket of the original Constructor function. How long ago was that?&lt;br /&gt;
&lt;br /&gt;
== Footer ==&lt;br /&gt;
Now for two vital lines of code:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;312&amp;quot;&amp;gt;&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_ANDY = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We set the type of constructor to CO. This tells COW that this is a CO and not some weirdly shaped unit.&lt;br /&gt;
&lt;br /&gt;
Then we set the var CO_ANDY to a new instance of Constructor. This makes CO_ANDY and actual CO object, and not just the blueprints of how to make Andy. CO_ANDY is where COW (and other scripts) will reference your CO from now on. &lt;br /&gt;
&lt;br /&gt;
And with those two lines, we are finished!&lt;br /&gt;
&lt;br /&gt;
== Endnote ==&lt;br /&gt;
If you made it to the end, congrats! You now know the details of how Andy&#039;s code works and (hopefully) how to make your own.&lt;br /&gt;
&lt;br /&gt;
What&#039;s that? You don&#039;t know how to make stuff affect different kinds of units?&lt;br /&gt;
&lt;br /&gt;
Uh...&lt;br /&gt;
&lt;br /&gt;
Maybe I should do this for Max as well.&lt;br /&gt;
&lt;br /&gt;
Anyways, that&#039;s it for this guide. Have a nice day!&lt;br /&gt;
[[Category:Modding tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3987</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3987"/>
		<updated>2023-12-30T20:03:03Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Endnote and removed unfinished notice&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3. &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;br /&gt;
&lt;br /&gt;
What a long winded way of explaining 4 lines of code.&lt;br /&gt;
&lt;br /&gt;
== Bio, Description, and Details ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;239&amp;quot;&amp;gt;&lt;br /&gt;
    // CO - Intel&lt;br /&gt;
    this.getBio = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;A whiz with a wrench, this mechanical boy wonder earned fame as the hero who saved Macro Land in the last great war.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Now we get to the CO information. This just returns a string. What&#039;s interesting is the use of the function qsTr. This converts the string into a format that&#039;s easier to display, so just put it around the test you&#039;re displaying and you&#039;re good to go.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;244&amp;quot;&amp;gt;&lt;br /&gt;
    this.getHits = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Mechanics&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getMiss = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Waking up too early&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getCODescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;No real weaknesses or strengths. Ready to fight wherever and whenever.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;More bio.&lt;br /&gt;
&lt;br /&gt;
getCODescription is where you&#039;ll put a short description of your CO. Nothing long and no numbers, just tell the user the basics. Also useful for more flavor text.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;256&amp;quot;&amp;gt;&lt;br /&gt;
    this.getLongCODescription = function()&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;\nSpecial Unit:\nRepair Tanks\n&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\nGlobal Effect: \nNone.&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\n\nCO Zone Effect: \nAndy&#039;s units gain +%0% firepower and +%1% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.d2dCoZoneOffBonus, CO_ANDY.d2dCoZoneDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Predictably, the long CO description, but this time with numbers!&lt;br /&gt;
&lt;br /&gt;
var text is just a temporary placeholder, the name isn&#039;t important&lt;br /&gt;
&lt;br /&gt;
You can join strings to each other with the + operator. You don&#039;t have to do this, but here it makes the text easier to read (code-side, there should be no difference on screen). \n is the newline symbol, which makes a newline. You can get more info on strings on google.&lt;br /&gt;
&lt;br /&gt;
What&#039;s the %0% doing in the string? It&#039;s used by the replaceTextArgs to substitute the proper bonus numbers into the description. Specifically, %0% says &amp;quot;insert the thing in index 0 of the list of objects here&amp;quot;. In this case, it&#039;s easy to see that CO_ANDY.d2dCoZoneOffBonus is the first object in the list. Similar idea with %1%.&lt;br /&gt;
&lt;br /&gt;
Doing this rather than hardcoding the numbers into the string makes it easier to change the stats of the CO without messing up the description. You can hardcode the numbers if you like, just remember they&#039;re there.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;264&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%1% firepower and +%2% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.powerHeal, CO_ANDY.powerOffBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Repair&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Power description and power name. What else is there to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;274&amp;quot;&amp;gt;&lt;br /&gt;
    this.getSuperPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%2 movement, +%1% firepower, and +%3% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.superPowerHeal, CO_ANDY.superPowerOffBonus, CO_ANDY.superPowerMovementBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getSuperPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Upgrade&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The super power. Spicy I know&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;284&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;I&#039;ve got parts to spare!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not giving up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Time to roll up my sleeves!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I haven&#039;t even cranked the engine yet!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Pass me my wrench!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;It&#039;s time for a tune-up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Never give up, and never lose! I&#039;m on my way!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not worried! I can fix anything!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When you use a power, the CO says something before actually using it. What that something is comes from here.&lt;br /&gt;
&lt;br /&gt;
Just return a list of strings (using []), the hard part is thinking of what to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;295&amp;quot;&amp;gt;&lt;br /&gt;
    this.getVictorySentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;We won! Woohoo!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I can fix anything!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I did it! Did you see that!?&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
    this.getDefeatSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;Oh, come on!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Next time I see you, you&#039;re in trouble!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;There are a surprising number of words that go into making a CO aren&#039;t there?&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;306&amp;quot;&amp;gt;&lt;br /&gt;
    this.getName = function()&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Andy&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Just to confirm, we are in fact looking at Andy&#039;s code.&lt;br /&gt;
&lt;br /&gt;
Also the closing bracket of the original Constructor function. How long ago was that?&lt;br /&gt;
&lt;br /&gt;
== Footer ==&lt;br /&gt;
Now for two vital lines of code:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;312&amp;quot;&amp;gt;&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_ANDY = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We set the type of constructor to CO. This tells COW that this is a CO and not some weirdly shaped unit.&lt;br /&gt;
&lt;br /&gt;
Then we set the var CO_ANDY to a new instance of Constructor. This makes CO_ANDY and actual CO object, and not just the blueprints of how to make Andy. CO_ANDY is where COW (and other scripts) will reference your CO from now on. &lt;br /&gt;
&lt;br /&gt;
And with those two lines, we are finished!&lt;br /&gt;
&lt;br /&gt;
== Endnote ==&lt;br /&gt;
If you made it to the end, congrats! You now know the details of how Andy&#039;s code works and (hopefully) how to make your own.&lt;br /&gt;
&lt;br /&gt;
What&#039;s that? You don&#039;t know how to make stuff affect different kinds of units?&lt;br /&gt;
&lt;br /&gt;
Uh...&lt;br /&gt;
&lt;br /&gt;
Maybe I should do this for Max as well.&lt;br /&gt;
&lt;br /&gt;
Anyways, that&#039;s it for this guide. Have a nice day!&lt;br /&gt;
[[Category:Modding tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3986</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3986"/>
		<updated>2023-12-30T20:00:41Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Finished descriptions and footer&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3. &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;br /&gt;
&lt;br /&gt;
What a long winded way of explaining 4 lines of code.&lt;br /&gt;
&lt;br /&gt;
== Bio, Description, and Details ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;239&amp;quot;&amp;gt;&lt;br /&gt;
    // CO - Intel&lt;br /&gt;
    this.getBio = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;A whiz with a wrench, this mechanical boy wonder earned fame as the hero who saved Macro Land in the last great war.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Now we get to the CO information. This just returns a string. What&#039;s interesting is the use of the function qsTr. This converts the string into a format that&#039;s easier to display, so just put it around the test you&#039;re displaying and you&#039;re good to go.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;244&amp;quot;&amp;gt;&lt;br /&gt;
    this.getHits = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Mechanics&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getMiss = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Waking up too early&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
    this.getCODescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;No real weaknesses or strengths. Ready to fight wherever and whenever.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;More bio.&lt;br /&gt;
&lt;br /&gt;
getCODescription is where you&#039;ll put a short description of your CO. Nothing long and no numbers, just tell the user the basics. Also useful for more flavor text.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;256&amp;quot;&amp;gt;&lt;br /&gt;
    this.getLongCODescription = function()&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;\nSpecial Unit:\nRepair Tanks\n&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\nGlobal Effect: \nNone.&amp;quot;) +&lt;br /&gt;
                   qsTr(&amp;quot;\n\nCO Zone Effect: \nAndy&#039;s units gain +%0% firepower and +%1% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.d2dCoZoneOffBonus, CO_ANDY.d2dCoZoneDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Predictably, the long CO description, but this time with numbers!&lt;br /&gt;
&lt;br /&gt;
var text is just a temporary placeholder, the name isn&#039;t important&lt;br /&gt;
&lt;br /&gt;
You can join strings to each other with the + operator. You don&#039;t have to do this, but here it makes the text easier to read (code-side, there should be no difference on screen). \n is the newline symbol, which makes a newline. You can get more info on strings on google.&lt;br /&gt;
&lt;br /&gt;
What&#039;s the %0% doing in the string? It&#039;s used by the replaceTextArgs to substitute the proper bonus numbers into the description. Specifically, %0% says &amp;quot;insert the thing in index 0 of the list of objects here&amp;quot;. In this case, it&#039;s easy to see that CO_ANDY.d2dCoZoneOffBonus is the first object in the list. Similar idea with %1%.&lt;br /&gt;
&lt;br /&gt;
Doing this rather than hardcoding the numbers into the string makes it easier to change the stats of the CO without messing up the description. You can hardcode the numbers if you like, just remember they&#039;re there.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;264&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%1% firepower and +%2% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.powerHeal, CO_ANDY.powerOffBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Repair&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Power description and power name. What else is there to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;274&amp;quot;&amp;gt;&lt;br /&gt;
    this.getSuperPowerDescription = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        var text = qsTr(&amp;quot;Restores +%0 HP to all of Andy&#039;s units. His units gain +%2 movement, +%1% firepower, and +%3% defence.&amp;quot;);&lt;br /&gt;
        text = replaceTextArgs(text, [CO_ANDY.superPowerHeal, CO_ANDY.superPowerOffBonus, CO_ANDY.superPowerMovementBonus, CO_ANDY.powerDefBonus]);&lt;br /&gt;
        return text;&lt;br /&gt;
    };&lt;br /&gt;
    this.getSuperPowerName = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Hyper Upgrade&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The super power. Spicy I know&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;284&amp;quot;&amp;gt;&lt;br /&gt;
    this.getPowerSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;I&#039;ve got parts to spare!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not giving up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Time to roll up my sleeves!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I haven&#039;t even cranked the engine yet!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Pass me my wrench!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;It&#039;s time for a tune-up!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Never give up, and never lose! I&#039;m on my way!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I&#039;m not worried! I can fix anything!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When you use a power, the CO says something before actually using it. What that something is comes from here.&lt;br /&gt;
&lt;br /&gt;
Just return a list of strings (using []), the hard part is thinking of what to say.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;295&amp;quot;&amp;gt;&lt;br /&gt;
    this.getVictorySentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;We won! Woohoo!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I can fix anything!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;I did it! Did you see that!?&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
    this.getDefeatSentences = function(co)&lt;br /&gt;
    {&lt;br /&gt;
        return [qsTr(&amp;quot;Oh, come on!&amp;quot;),&lt;br /&gt;
                qsTr(&amp;quot;Next time I see you, you&#039;re in trouble!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;There are a surprising number of words that go into making a CO aren&#039;t there?&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;306&amp;quot;&amp;gt;&lt;br /&gt;
    this.getName = function()&lt;br /&gt;
    {&lt;br /&gt;
        return qsTr(&amp;quot;Andy&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Just to confirm, we are in fact looking at Andy&#039;s code.&lt;br /&gt;
&lt;br /&gt;
Also the closing bracket of the original Constructor function. How long ago was that?&lt;br /&gt;
&lt;br /&gt;
== Footer ==&lt;br /&gt;
Now for two vital lines of code:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;312&amp;quot;&amp;gt;&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_ANDY = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We set the type of constructor to CO. This tells COW that this is a CO and not some weirdly shaped unit.&lt;br /&gt;
&lt;br /&gt;
Then we set the var CO_ANDY to a new instance of Constructor. This makes CO_ANDY and actual CO object, and not just the blueprints of how to make Andy. CO_ANDY is where COW (and other scripts) will reference your CO from now on. &lt;br /&gt;
&lt;br /&gt;
And with those two lines, we are finished!&lt;br /&gt;
[[Category:Modding tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3985</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3985"/>
		<updated>2023-12-30T16:54:56Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Right category&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3. &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;br /&gt;
[[Category:Modding tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3984</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3984"/>
		<updated>2023-12-30T16:54:17Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Category added&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3. &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;br /&gt;
[[Category:Modding Tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3983</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3983"/>
		<updated>2023-12-30T16:32:56Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Finish Music and Modifiers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
This format (a switch statement using the power mode) is actually the standard way of doing different things if your power is active or not. You don&#039;t have to memorize it, just copy-paste it a bunch.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3. &lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables for easy modification of Andy&#039;s numbers. If you check the in-game wiki, these numbers should line up with what you see there. As stated above, these variables make sure you don&#039;t accidentally change the numbers in one place but not another.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;169&amp;quot;&amp;gt;&lt;br /&gt;
    this.getOffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isDefender, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return CO_ANDY.superPowerOffBonus;&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return CO_ANDY.powerOffBonus;&lt;br /&gt;
            default:&lt;br /&gt;
                if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
                {&lt;br /&gt;
                    return CO_ANDY.d2dCoZoneOffBonus;&lt;br /&gt;
                }&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getOffensiveBonus is called when you want to find the offensive bonus of a specific unit. There are a lot of parameters for this function, but honestly most of them are pretty self-explanatory (what do you expect defender to be).&lt;br /&gt;
&lt;br /&gt;
if (CO.isActive(co)) just makes sure your CO is actually active and should be used.&lt;br /&gt;
&lt;br /&gt;
The switch statement is explained above. In this case, it changes the offensive bonus depending on if the power is active or not.&lt;br /&gt;
&lt;br /&gt;
Note the co.inCORange() function. This is a very easy way to check if a unit is in the CO zone or not. You may be curious why this check isn&#039;t in any other case. In the original AW DoR, where CO zones were first introduced, CO zones became global while using powers. This is carried over to COW, so not only would the check be redundant (you can be sure your unit is in the map-wide zone), it may not even work (sometimes when a CO unit is moved during powers, the zone shows up as range 0).&lt;br /&gt;
&lt;br /&gt;
Also the break statement at the end. This is best practice in switch statements, as it ensures you get out of the switch right away and not accidentally fall into other cases. You don&#039;t need to do this after a return statement, because return sends you out of the function as well as the switch.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;191&amp;quot;&amp;gt;&lt;br /&gt;
    this.getDeffensiveBonus = function(co, attacker, atkPosX, atkPosY,&lt;br /&gt;
                                 defender, defPosX, defPosY, isAttacker, action, luckmode, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.powerDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
            else if (co.inCORange(Qt.point(defPosX, defPosY), defender))&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.d2dCoZoneDefBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, except for one thing.&lt;br /&gt;
&lt;br /&gt;
A funny thing about enums, they&#039;re actually numbers.&lt;br /&gt;
&lt;br /&gt;
This allows for funky stuff like co.getPowerMode() &amp;gt; GameEnums.PowerMode_Off. This will be true if either CO power is active.&lt;br /&gt;
&lt;br /&gt;
I don&#039;t personally use this, but this is an alternative to a switch statement.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;207&amp;quot;&amp;gt;&lt;br /&gt;
    this.getMovementpointModifier = function(co, unit, posX, posY, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            if (co.getPowerMode() === GameEnums.PowerMode_Superpower ||&lt;br /&gt;
                co.getPowerMode() === GameEnums.PowerMode_Tagpower)&lt;br /&gt;
            {&lt;br /&gt;
                return CO_ANDY.superPowerMovementBonus;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 0;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Very similar, again&lt;br /&gt;
&lt;br /&gt;
Since movement takes place outside of combat, you don&#039;t have attacker, attackerX, defender, and defenderY (some variables skipped for brevity). Instead you just have the unit you&#039;re moving. This shouldn&#039;t be too relevant, but beware accidentally copying attacker and not replacing it with unit.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;220&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnits = function(co, building, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            var buildingId = building.getBuildingID();&lt;br /&gt;
            if (buildingId === &amp;quot;FACTORY&amp;quot; ||&lt;br /&gt;
                    buildingId === &amp;quot;TOWN&amp;quot; ||&lt;br /&gt;
                    BUILDING.isHq(building))&lt;br /&gt;
            {&lt;br /&gt;
                return [&amp;quot;ZCOUNIT_REPAIR_TANK&amp;quot;];&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return [];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This function gets your exclusive CO units. In Andy&#039;s case, we have repair tanks (internal ID ZCOUNIT_REPAIR_TANK). But since it&#039;s a land unit, we don&#039;t want to build it out of any building (as much as I think Andy forgetting what an airport is supposed to do is funny).&lt;br /&gt;
&lt;br /&gt;
So we check the buildingId. For compatibility with Hachi and Hachi&#039;s soul, we also add the repair tank to the build lists of towns and hqs, even though they can&#039;t build anything.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;234&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 1;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;I actually had to look up what this does. If we step away from Andy for a bit and go to Sami&#039;s code [https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_sami.js#L305]:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;305&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiCoUnitBonus = function(co, unit, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (unit.getUnitID !== &amp;quot;INFANTRY&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (unit.getUnitType() === GameEnums.UnitType_Infantry)&lt;br /&gt;
            {&lt;br /&gt;
                return 8;&lt;br /&gt;
            }&lt;br /&gt;
            else if (unit.getBaseMaxRange() === 1)&lt;br /&gt;
            {&lt;br /&gt;
                return -1;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return 2;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;It quickly becomes apparent what this method is used for. If the unit is an infantry, skip the if statement and return 2. If the unit is of type infantry (but not the 1k infantry, something like a commando), return 8. If it&#039;s a direct unit, return -1. And if it&#039;s an indirect, you go outside of the if statement and return 2.&lt;br /&gt;
&lt;br /&gt;
In short, Sami prefers infantry type over infantry and indirects, and those over direct units (for CO units) (Thanks Sami!)&lt;br /&gt;
&lt;br /&gt;
Andy returns 1 no matter what, so no preference.&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3928</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3928"/>
		<updated>2023-12-19T19:51:17Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: A bit of work on Music and Modifiers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange should return the CO zone range, in this case 3.&lt;br /&gt;
&lt;br /&gt;
getCOArmy should return a string corresponding to the co&#039;s country. In this case Andy is from Orange Star, so this function returns &amp;quot;OS&amp;quot;. You can check other COs for their country&#039;s strings. &amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;158&amp;quot;&amp;gt;&lt;br /&gt;
    this.superPowerHeal = 5;&lt;br /&gt;
    this.superPowerOffBonus = 30;&lt;br /&gt;
    this.superPowerMovementBonus = 1;&lt;br /&gt;
&lt;br /&gt;
    this.powerDefBonus = 20;&lt;br /&gt;
    this.powerOffBonus = 20;&lt;br /&gt;
    this.powerHeal = 2;&lt;br /&gt;
&lt;br /&gt;
    this.d2dCoZoneOffBonus = 20;&lt;br /&gt;
    this.d2dCoZoneDefBonus = 20;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;These are variables&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3927</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3927"/>
		<updated>2023-12-19T18:47:42Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Started music and modifiers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;br /&gt;
&lt;br /&gt;
== Music and Modifiers ==&lt;br /&gt;
Most of these functions will return a value. Not much logic in these.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;127&amp;quot;&amp;gt;&lt;br /&gt;
    this.loadCOMusic = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        if (CO.isActive(co))&lt;br /&gt;
        {&lt;br /&gt;
            switch (co.getPowerMode())&lt;br /&gt;
            {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/power.mp3&amp;quot;, 992, 45321);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/superpower.mp3&amp;quot;, 1505, 49515);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/tagpower.mp3&amp;quot;, 14611, 65538);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;resources/music/cos/andy.mp3&amp;quot;,  4466, 74972);&lt;br /&gt;
                break;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;co.getPowerMode() returns something based on what power is activated.&lt;br /&gt;
&lt;br /&gt;
switch statements execute different code based on the input value. In this case that would be the power mode.&lt;br /&gt;
&lt;br /&gt;
audio.addMusic plays the music (in a loop presumably) from startTime (in milliseconds) to endTime (in milliseconds).&lt;br /&gt;
&lt;br /&gt;
The break statements prevent the code from considering other cases once one case has been run.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;149&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOUnitRange = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        return 3;&lt;br /&gt;
    };&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;getCOUnitRange&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3926</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3926"/>
		<updated>2023-12-19T18:26:07Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Power stuff finished. activatePower and activateSuperpower explained&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
Note: CO_&amp;lt;co name&amp;gt; is standard convention for CO variables. Often, you&#039;ll store important variables for your CO on CO_&amp;lt;co name&amp;gt; like CO_ANDY.powerHeal. CO_&amp;lt;co name&amp;gt; is how other scripts are going to access your CO, and how your own script accesses your CO.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before going any further into the animation code, I want to go into the big picture of what is actually happening.&lt;br /&gt;
&lt;br /&gt;
So first of all, when an animation is created, it&#039;s going to be handled by the Commander Wars engine no matter what. It doesn&#039;t matter if no variable in your script points to it, it&#039;s going to be saved in the core game and the core game will handle it.&lt;br /&gt;
&lt;br /&gt;
The power animation for the units goes something like this: make an animation for every unit in a random order, but don&#039;t have more than 5 animations going on at the same time.&lt;br /&gt;
&lt;br /&gt;
With that out of the way, here&#039;s the rest of the code&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;49&amp;quot;&amp;gt;&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;delay is set to some random number between 135 and 265. Then, if the animation queue isn&#039;t filled (length is 5), multiply the delay by i.&lt;br /&gt;
&lt;br /&gt;
What delay *= i will do is approximately make sure that the animations are in order. Say we happen to roll 200 3 times, the delays would be 200 (start at 200), 400, and 600. This will make the animations appear one after the other, kind of like how it works in the original advance wars. I&#039;ll explain what happens if the delay isn&#039;t multiplied later.&lt;br /&gt;
&lt;br /&gt;
animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay) sets the sound of the animation. power0.wav is the filename of the sound, 1 is the number of times to repeat (1 means 1 play) and delay is how delayed it is. If you want, I believe you can add another number for volume and also set if the oldest sound should be stopped. (animation.setSound(&amp;quot;filename&amp;quot;, repeats, delay, volume, stopOldestSound))&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;55&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;animations.length &amp;lt; 5 means the animation queue isn&#039;t full. It then adds a sprite (power0) and positions it accordingly.&lt;br /&gt;
&lt;br /&gt;
Looking at the source of addSprite [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/game/gameanimation/gameanimation.cpp], it offsets the image so that the unit is in the center (-map.getImageSize()*1.27) (both of them), sets sleepAfterFinish (0 is no I think), sets the scale (2) and adds delay (delay). There&#039;s another parameter for loops, which would probably set repeats if you want the image to show up more than once.&lt;br /&gt;
&lt;br /&gt;
powerNameAnimation.queueAnimation(animation) sets the current animation to fire right after powerNameAnimation (the screen fill with your power name). But while the animation starts right away internally, the sound and image are delayed (thanks to delay) so what you see and hear on screen actually starts a bit later (which is probably what you want). queueAnimation() is a function attached to the animation class in general, so don&#039;t be confused if you see a different animation object using this function.&lt;br /&gt;
&lt;br /&gt;
animations.push(animation) sticks the current animation at the end of the animations list. This will become very relevant shortly.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;61&amp;quot;&amp;gt;&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;else is for if the statement in the if block isn&#039;t true (in this case animations.length &amp;lt; 5). This would mean that the animation queue is full.&lt;br /&gt;
&lt;br /&gt;
Just to recap, delay has not been multiplied by i, counter is the index of some animation in animation, and animations is full of animations.&lt;br /&gt;
&lt;br /&gt;
We&#039;ve seen the addSprite method before. What&#039;s different is animations[counter].queueAnimation(animation). Here, the current animation is set to fire right after animations[counter] finishes. Then the current animation replaces the old animation, and counter increases by 1. (++ does that) If counter &amp;gt;= animations.length (animations[counter] would throw an error), just set it back to 0.&lt;br /&gt;
&lt;br /&gt;
Was that confusing? Here&#039;s a step by step diagram.&lt;br /&gt;
&lt;br /&gt;
Right before the first instance of this, animations is filled with [0,1,2,3,4]. (not actually those numbers, just animations 0, 1, 2, 3, and 4)&lt;br /&gt;
&lt;br /&gt;
On the first iteration of this else statement, counter is 0, so animation 0 will set 5 to fire right after it, then 5 takes 0&#039;s place. counter increases by 1.&lt;br /&gt;
&lt;br /&gt;
The list looks like this: [5,1,2,3,4], and counter is 1 now.&lt;br /&gt;
&lt;br /&gt;
Next iteration: [5,6,2,3,4] (6 is queued after 1, counter is 2)&lt;br /&gt;
&lt;br /&gt;
Skip forwards a bit: [5,6,7,8,4] (7 after 2, 8 after 3, counter is 4)&lt;br /&gt;
&lt;br /&gt;
Now the animations will do their dance [5,6,7,8,9], and counter increases by 1 to 5.&lt;br /&gt;
&lt;br /&gt;
But animations[5] is not valid (remember 0 indexing), so counter is set back to 0, and the cycle repeats.&lt;br /&gt;
&lt;br /&gt;
The delay works here, because we have 0,5,10,15 going &amp;quot;1 delay&amp;quot; after each other, 1,6,11,16 going &amp;quot;1 delay&amp;quot; after each other (but 1 is delayed by &amp;quot;1 delay&amp;quot; relative to 0) and the rest is similar. If you don&#039;t think this is good, feel free to mess around with the code and see what happens.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;72&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;And that&#039;s that function done.&lt;br /&gt;
&lt;br /&gt;
activateSuperpower is actually pretty similar, using much of the same mechanics to do basically the same thing.&lt;br /&gt;
&lt;br /&gt;
Notable changes:&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;92&amp;quot;&amp;gt;&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.superPowerHeal);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;When using the SCOP, we use the superPowerHeal rather than the regular power heal.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;95&amp;quot;&amp;gt;&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;bigger queue, more animations at once&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;99&amp;quot;&amp;gt;&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;We have two sounds! i%2===0 will be true every other iteration, so we alternate between the two sounds.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;109&amp;quot;&amp;gt;&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Different image, and the offset is bigger (because the image is bigger)&lt;br /&gt;
&lt;br /&gt;
Again, it was basically the same thing, but with SCOP stuff.&lt;br /&gt;
&lt;br /&gt;
You&#039;re asking how long the next functions are going to be?&lt;br /&gt;
&lt;br /&gt;
Not very long actually, they&#039;re far simpler and mostly just for returning numbers.&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3925</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3925"/>
		<updated>2023-12-18T17:42:02Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Animation stuff&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will iterate through the units, with i being the index and unit being the current unit. This is randomized because units was randomized beforehand.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;44&amp;quot;&amp;gt;&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(CO_ANDY.powerHeal);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Here the animation is set up. The animation is created on the map at the unit&#039;s position in createAnimation. Then the unit&#039;s position is written to the animation and CO_ANDY.powerHeal. powerHeal is an integer specifying the COP healing, in this case 2. The variable is useful to avoid &amp;quot;magic numbers&amp;quot;, constant values that are typed in directly. If you want to change a magic number, you have to manually go into the code and edit every instance of that magic number. Keeping your constants in variables like CO_ANDY.powerHeal allows you to change the value quickly and easily from one place. You&#039;ll see variables like this later in the code.&lt;br /&gt;
&lt;br /&gt;
At the end of the animation, the units will be healed for 2 hp. postAnimationHeal uses the prior three values to know what position to heal as well as how much to heal. setEndOfAnimationCall tells the animation engine to call a function (in this case postAnimationHeal) from an object (ANIMATION) at the end of the animation. Here&#039;s the actual postAnimationHeal if you&#039;re curious. [https://github.com/Robosturm/Commander_Wars/blob/5a820a28c520f5cfa0c18a5fe1e82a916c927f6f/resources/scripts/general/animation.js#L4]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3924</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3924"/>
		<updated>2023-12-18T16:14:27Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Added unfinished notice, did part of power animation code&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;THIS IS UNFINISHED DO NOT COMPLAIN ABOUT MISSING SECTIONS&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;br /&gt;
&lt;br /&gt;
Next segment!&lt;br /&gt;
&lt;br /&gt;
== Power stuff ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
    this.init = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;init() is generally a function called to make sure that something is ready and to set up any needed variables. In this case, the only things that are done are setting COP stars to 3 and setting SCOP stars to 3. Note how the SCOP does not cost 3 stars, rather this is 3 stars on top of the COP cost of 3 stars, for a total of 6 stars.&lt;br /&gt;
&lt;br /&gt;
Since the next function probably won&#039;t fit on the screen all at once, I&#039;ll just break it down now.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;30&amp;quot;&amp;gt;&lt;br /&gt;
    this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The function is called activatePower, which is used when you activate power (COP specifically)&lt;br /&gt;
&lt;br /&gt;
dialogAnimation and powerNameAnimation are used for the flashy effects whenever you use a power, the ones that appear, fill the screen with the power name, and disappear before your units get sparkles on them.&lt;br /&gt;
&lt;br /&gt;
.queueAnimation is used to make sure that the whole screen is filled after the dialog finishes.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;36&amp;quot;&amp;gt;&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;To go through all the units and make animations, we&#039;ll need to get all the units and have a place to store all the animations. counter is set to 0 and will correspond to animations&#039;s size (incidentally both are 0 right now)&lt;br /&gt;
&lt;br /&gt;
units.randomize() makes sure that the units will be considered in a random order. Since animations happen in the same order, the animations are randomized as well.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The for loop will&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3921</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3921"/>
		<updated>2023-12-17T14:59:09Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Header code. There&amp;#039;s actually a lot of it.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Small Disclaimer ==&lt;br /&gt;
This will only go through vanilla Andy&#039;s js code, and not any other files. This is intended for newer players to understand the workings of what the code they&#039;re copy-pasting actually does. If you want to make a brand new CO in a mod, a good starting point is [[Custom CO]]. Alternatively, download a mod and edit to suit your needs.&lt;br /&gt;
&lt;br /&gt;
Also I refer to normal CO powers as COP and super CO powers as SCOP, just clearing that up&lt;br /&gt;
&lt;br /&gt;
== Some stuff in the header ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;The very first line (or two) of code. This defines a variable called Constructor to be a function. What does the function do? It&#039;s defined in the curly brackets {} following it. Notice how only the opening bracket is present. This is a long function (the whole CO).&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
    this.getCOStyles = function()&lt;br /&gt;
    {&lt;br /&gt;
        return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;];&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Due to some js... weirdness, we treat functions as objects that you can define properties of. If we called Constructor.getCOStyles() after finishing the Constructor function, we would get this. Specifically it would return [&amp;quot;+alt&amp;quot;, &amp;quot;+alt2&amp;quot;, &amp;quot;+alt3&amp;quot;]. This is telling the game to look for alternate CO images labeled &amp;quot;andy+alt&amp;quot;, &amp;quot;andy+alt2&amp;quot;, and &amp;quot;andy+alt3&amp;quot; as well as simply &amp;quot;andy&amp;quot;. If you look in the corresponding images folder ([https://github.com/Robosturm/Commander_Wars/tree/master/resources/images/co/os]), we do actually find said images. This is Commander Wars&#039;s way to get CO styles, so if you want to have extra costumes for your CO, this is how you do it.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This is a custom function for the AI behavior of Andy. If it looks scary, that&#039;s because &amp;lt;s&amp;gt;it kinda is&amp;lt;/s&amp;gt; there&#039;s just a bunch of variables and if statements flying around. Let&#039;s break this down further&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;8&amp;quot;&amp;gt;&lt;br /&gt;
    this.getAiUsePower = function(co, powerSurplus, unitCount, repairUnits, indirectUnits, directUnits, enemyUnits, turnMode)&lt;br /&gt;
    {&lt;br /&gt;
        &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Again, a function definition. But this time, with words inside the function() brackets. Those are called parameters, and how you can pass data into a function. Here, the game is passing in:&lt;br /&gt;
&lt;br /&gt;
* The CO (co) (specifically the player&#039;s instance of a CO, in an andy mirror match both andys are actually considered different COs)&lt;br /&gt;
* The power charge more than what the COP needs (powerSurplus)&lt;br /&gt;
* The count of all owned units on the field (unitCount)&lt;br /&gt;
* Count of all units less than 10hp (repairUnits)&lt;br /&gt;
* Count of all units that can shoot at more than 1 range (indirectUnits)&lt;br /&gt;
* Count of all units not an indirect unit (directUnits)&lt;br /&gt;
* The number of enemy units&lt;br /&gt;
* The turn mode of the AI, set to start of day, during the day, and end of day.&lt;br /&gt;
&lt;br /&gt;
The vast majority of the time, a significant portion of these will not be used (for example, Andy doesn&#039;t really care if his units are direct or indirect, so long as they&#039;re repaired)&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;10&amp;quot;&amp;gt;&lt;br /&gt;
        if (turnMode === GameEnums.AiTurnMode_StartOfDay)&lt;br /&gt;
        {&lt;br /&gt;
            &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;This checks that the turn mode is start of day. This makes sure that Andy only ever uses his power at the start of each day.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
            if (co.canUseSuperpower())&lt;br /&gt;
            {&lt;br /&gt;
                return GameEnums.PowerMode_Superpower;&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy can use his SCOP of course he uses his SCOP&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
            else if (powerSurplus &amp;lt;= 0.5 &amp;amp;&amp;amp;&lt;br /&gt;
                     co.canUsePower())&lt;br /&gt;
            {&lt;br /&gt;
                return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);&lt;br /&gt;
            }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;If Andy has at most 0.5 stars more than his COP (and if he can use his COP in the first place), return CO.getAiUsePowerAtUnitCount(co, powerSurplus, turnMode, repairUnits);?&lt;br /&gt;
&lt;br /&gt;
Referencing CO.getAiUsePowerAtUnitCount, it first checks if turnMode is equal to start of day, and also if repairUnits (in Andy&#039;s getAiUsePower at least, the name is changed during the function call to unitCount) is at least 5.&lt;br /&gt;
&lt;br /&gt;
If either of these conditions are not fulfilled, don&#039;t use any power.&lt;br /&gt;
&lt;br /&gt;
If both of these conditions are  fulfilled, use SCOP is possible, and use COP if powerSurplus &amp;lt;= 0.5 (and if COP is usable in the first place)&lt;br /&gt;
&lt;br /&gt;
So essentially, Andy doesn&#039;t want to Hyper Repair unless he has just enough power charge and if he can repair at least 5 units.&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot; line=&amp;quot;1&amp;quot; start=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;Closing brackets you always need those&lt;br /&gt;
&lt;br /&gt;
You may be put off at the lack of a return statement here. Won&#039;t the code break if the function doesn&#039;t return anything?&lt;br /&gt;
&lt;br /&gt;
I&#039;m put off too.&lt;br /&gt;
&lt;br /&gt;
Also the semicolon at the end? This is because we&#039;re actually defining a variable (getAiUsePower) as this function. Defining a variable is a code statement. We need semicolons after each code statement so the computer knows where to end each block of code. This is a property of c++ and java as well as javascript.&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3920</id>
		<title>Andy Breakdown</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Andy_Breakdown&amp;diff=3920"/>
		<updated>2023-12-17T14:03:07Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Created Andy Breakdown page, added basic intro text&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; In case you want to learn more about Javascript, you can check the tutorial here: Derek Banas&#039; Javascript tutorial , purchase O&#039;Reilly&#039;s excellent book on the subject JavaScript: The Definitive Guide, or check out W3 Schools Interactive Tutorials&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;This tutorial references https://github.com/Robosturm/Commander_Wars/blob/master/resources/scripts/cos/co_andy.js, the source code of the actual vanilla Andy in COW.&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
	<entry>
		<id>https://www.commanderwars.com/w/index.php?title=Custom_CO&amp;diff=3919</id>
		<title>Custom CO</title>
		<link rel="alternate" type="text/html" href="https://www.commanderwars.com/w/index.php?title=Custom_CO&amp;diff=3919"/>
		<updated>2023-12-17T14:00:04Z</updated>

		<summary type="html">&lt;p&gt;MrDuck557: Added a reference to a non-existent Andy Breakdown page to reference it later. Will create Andy Breakdown page.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Notice: Modding tutorials assume you know at least the basics of coding or scripting. Commander Wars uses Javascript as the Scripting Language.&#039;&#039;&#039; &lt;br /&gt;
In case you want to learn more about Javascript, you can check the tutorial here: [https://www.youtube.com/watch?v=fju9ii8YsGs Derek Banas&#039; Javascript tutorial] , purchase O&#039;Reilly&#039;s excellent book on the subject [https://www.amazon.com/JavaScript-Definitive-Most-Used-Programming-Language/dp/1491952024/ JavaScript: The Definitive Guide], or check out [https://www.w3schools.com/js/ W3 Schools Interactive Tutorials]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;You may download the files of this tutorial on [https://discord.com/channels/615556870064832533/688802481504911372/1010627909133811785 Discord]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Setup==&lt;br /&gt;
In this tutorial a basic CO will be created, with an Advance Wars 2 like set of powers. The mod must be created in the mods folder for the Javascript to be detected properly.&lt;br /&gt;
&lt;br /&gt;
To simplify things, we will create a CO that simply boosts the defense and offense of all units and heals up during powers. However notes to modify specific units, adding custom weapon values to units will be linked at the end of the tutorial.&lt;br /&gt;
&lt;br /&gt;
*Create the following folder and file structure, inside a new &#039;&#039;&#039;testco&#039;&#039;&#039; folder leave any files empty for now. The mp3 files can be any songs of your choice, so as long as they have the same file name. The &#039;&#039;&#039;png&#039;&#039;&#039; images will be added later in the tutorial. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;apacheconf&amp;quot;&amp;gt;&lt;br /&gt;
~/mods/testco&lt;br /&gt;
├── images&lt;br /&gt;
│   └── co&lt;br /&gt;
│       ├── co_test+face.png&lt;br /&gt;
│       ├── co_test+info.png&lt;br /&gt;
│       ├── co_test+nrm.png&lt;br /&gt;
│       └── res.xml&lt;br /&gt;
├── mod.txt&lt;br /&gt;
├── music&lt;br /&gt;
│   └── cos&lt;br /&gt;
│       ├── Power.mp3&lt;br /&gt;
│       ├── Super.mp3&lt;br /&gt;
│       └── Theme.mp3&lt;br /&gt;
└── scripts&lt;br /&gt;
    └── cos&lt;br /&gt;
        └── co_test.js&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To the &#039;&#039;&#039;mod.txt&#039;&#039;&#039; file add the following content. This is required for the engine to detect compatibilities between mods, and to display what your mod does&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;apacheconf&amp;quot;&amp;gt;&lt;br /&gt;
name=Test CO&lt;br /&gt;
description=This is a test CO.&lt;br /&gt;
version=N/A&lt;br /&gt;
compatible_mods=&lt;br /&gt;
incompatible_mods=&lt;br /&gt;
required_mods=&lt;br /&gt;
cosmetic=false&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==CO Constructor==&lt;br /&gt;
Inside &#039;&#039;&#039;co_test.js&#039;&#039;&#039; put the following code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
   this.init = function(co,map)&lt;br /&gt;
    {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getCOArmy = function()&lt;br /&gt;
    {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_TEST = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This code simply inits the constructor to create our CO, &#039;&#039;&#039;this.init&#039;&#039;&#039; sets the stars that are required for the Power and Super Power respectively.&lt;br /&gt;
&#039;&#039;&#039;this.getCOArmy&#039;&#039;&#039; sets to which country the CO  belongs to. In this case &#039;&#039;&#039;OS&#039;&#039;&#039; sets it for the Orange Star Army. The list of values are:&lt;br /&gt;
&#039;&#039;&#039;OS&#039;&#039;&#039; for Orange Star, &#039;&#039;&#039;BM&#039;&#039;&#039; for Blue Moon, &#039;&#039;&#039;YC&#039;&#039;&#039; for Yellow Comet, &#039;&#039;&#039;GE&#039;&#039;&#039; for Green Earth and &#039;&#039;&#039;BH&#039;&#039;&#039; for Black Hole. Custom factions will have their own, specific strings.&lt;br /&gt;
&lt;br /&gt;
==CO Intel==&lt;br /&gt;
Up next, we will add the Intel information of our CO. &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function () {&lt;br /&gt;
    &lt;br /&gt;
    this.init = function (co, map) {&lt;br /&gt;
        co.setPowerStars(3);&lt;br /&gt;
        co.setSuperpowerStars(3);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getCOArmy = function () {&lt;br /&gt;
        return &amp;quot;OS&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getBio = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;A test CO.&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getHits = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;Hitting&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getMiss = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;Missing&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getCODescription = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;A Simple CO created for this tutorial. All units have 10% extra Firepower and Defense&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getPowerDescription = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;Increases the Firepower and Defense of all units by 20%, heals 2HP to all units&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getPowerName = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;Power Boost&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getSuperPowerDescription = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;Increases the Firepower and Defense of all units by 40%, heals 5HP to all units&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getSuperPowerName = function (co) {&lt;br /&gt;
        return qsTr(&amp;quot;Super Power Boost&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getPowerSentences = function (co) {&lt;br /&gt;
        return [qsTr(&amp;quot;Attack!&amp;quot;), qsTr(&amp;quot;Destroy the Enemy!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getVictorySentences = function (co) {&lt;br /&gt;
        return [qsTr(&amp;quot;Victory!&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getDefeatSentences = function (co) {&lt;br /&gt;
        return [qsTr(&amp;quot;Defeat...&amp;quot;)];&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    this.getName = function () {&lt;br /&gt;
        return qsTr(&amp;quot;Test CO&amp;quot;);&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_TEST = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The anonymous functions set the values for each of the respective values in the Engine. The &#039;&#039;&#039;qsTr()&#039;&#039;&#039; function is a Qt function which is used to generate translatable strings in the Engine. You can know more about the qsTr() function here: [https://doc.qt.io/qt-6/qtquick-internationalization.html:  qsTr()]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;this.getVictorySentences&#039;&#039;&#039;, &#039;&#039;&#039;this.getDefeatSentences&#039;&#039;&#039;, &#039;&#039;&#039;this.getPowerSentences&#039;&#039;&#039; all take arrays which are randomized when a Victory, Defeat or Power activation occur. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;this.getPowerSentences&#039;&#039;&#039; lists the strings for both the CO Power and Super Power.&lt;br /&gt;
&lt;br /&gt;
==Adding Offensive and Defensive stats==&lt;br /&gt;
&lt;br /&gt;
To add Firepower and Defense in CoW-Engine Style we can use the following functions&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
//Constructor code ommited for brevity&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_TEST = new Constructor();&lt;br /&gt;
&lt;br /&gt;
CO_TEST.getOffensiveBonus = function (co, attacker, atkPosX, atkPosY,&lt;br /&gt;
    defender, defPosX, defPosY, isDefender, action, luckMode, map) {&lt;br /&gt;
&lt;br /&gt;
    switch (co.getPowerMode())&lt;br /&gt;
    {&lt;br /&gt;
        case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
        case GameEnums.PowerMode_Superpower:&lt;br /&gt;
            return 50;&lt;br /&gt;
        case GameEnums.PowerMode_Power:&lt;br /&gt;
            return 30;&lt;br /&gt;
        default:&lt;br /&gt;
            if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
            {&lt;br /&gt;
                return 10;&lt;br /&gt;
            }&lt;br /&gt;
                return 10; &lt;br /&gt;
            break;&lt;br /&gt;
    }&lt;br /&gt;
    return 0;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
CO_TEST.getDeffensiveBonus = function (co, attacker, atkPosX, atkPosY,&lt;br /&gt;
    defender, defPosX, defPosY, isAttacker, action, luckMode,map) {&lt;br /&gt;
&lt;br /&gt;
    switch (co.getPowerMode())&lt;br /&gt;
    {&lt;br /&gt;
        case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
        case GameEnums.PowerMode_Superpower:&lt;br /&gt;
            return 50;&lt;br /&gt;
        case GameEnums.PowerMode_Power:&lt;br /&gt;
            return 30;&lt;br /&gt;
        default:&lt;br /&gt;
            if (co.inCORange(Qt.point(atkPosX, atkPosY), attacker))&lt;br /&gt;
            {&lt;br /&gt;
                return 10;&lt;br /&gt;
            }&lt;br /&gt;
                return 10; &lt;br /&gt;
            break;&lt;br /&gt;
    }&lt;br /&gt;
    return 0;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will set the Defense and Offense of all units to 10% inside the co-zone as the day to day ability.&lt;br /&gt;
And increase both to 30% during the Power activation, and to 50% during the Super Powers for all units.&lt;br /&gt;
All bonuses are applied independend of the fact if it&#039;s the first or second co.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The following example does the same but as an AW-DS-Style CO.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
//Constructor code ommited for brevity&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_TEST = new Constructor();&lt;br /&gt;
&lt;br /&gt;
CO_TEST.getOffensiveBonus = function (co, attacker, atkPosX, atkPosY,&lt;br /&gt;
    defender, defPosX, defPosY, isDefender, action, luckMode, map) {&lt;br /&gt;
&lt;br /&gt;
    if (co.getIsCO0() === true) {&lt;br /&gt;
        switch (co.getPowerMode()) {&lt;br /&gt;
&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return 50;&lt;br /&gt;
&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return 30;&lt;br /&gt;
            &lt;br /&gt;
            default:&lt;br /&gt;
                return 10;&lt;br /&gt;
                break;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    return 0;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
CO_TEST.getDeffensiveBonus = function (co, attacker, atkPosX, atkPosY,&lt;br /&gt;
    defender, defPosX, defPosY, isAttacker, action, luckMode,map) {&lt;br /&gt;
&lt;br /&gt;
    if (co.getIsCO0() === true) {&lt;br /&gt;
        switch (co.getPowerMode()) {&lt;br /&gt;
&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                return 50;&lt;br /&gt;
&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                return 30;&lt;br /&gt;
&lt;br /&gt;
            default:&lt;br /&gt;
                return 10;&lt;br /&gt;
                break;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    return 0;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This will set the Defense and Offense of all units to 10% as the day to day ability, increase both to 30% during the Power activation, and to 50% during the Super Power.&lt;br /&gt;
If the CO is the currently the first one.&lt;br /&gt;
&lt;br /&gt;
==Power and Super Power Animations==&lt;br /&gt;
To create the Power animation we will use the following code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
//Rest of the code ommited for brevity&lt;br /&gt;
var Constructor = function () {&lt;br /&gt;
      this.activatePower = function(co, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(GameEnums.PowerMode_Power);&lt;br /&gt;
        dialogAnimation.queueAnimation(powerNameAnimation);&lt;br /&gt;
&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(2);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            animation.setSound(&amp;quot;power0.wav&amp;quot;, 1, delay);&lt;br /&gt;
            if (animations.length &amp;lt; 5)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power0&amp;quot;, -map.getImageSize() * 1.27, -map.getImageSize() * 1.27, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        units.remove();&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And for the Super Power:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
//Rest of the code omitted for brevity &lt;br /&gt;
var Constructor = function () {&lt;br /&gt;
      this.activateSuperpower = function(co, powerMode, map)&lt;br /&gt;
    {&lt;br /&gt;
        var dialogAnimation = co.createPowerSentence();&lt;br /&gt;
        var powerNameAnimation = co.createPowerScreen(powerMode);&lt;br /&gt;
        powerNameAnimation.queueAnimationBefore(dialogAnimation);&lt;br /&gt;
&lt;br /&gt;
        var units = co.getOwner().getUnits();&lt;br /&gt;
        var animations = [];&lt;br /&gt;
        var counter = 0;&lt;br /&gt;
        units.randomize();&lt;br /&gt;
        for (var i = 0; i &amp;lt; units.size(); i++)&lt;br /&gt;
        {&lt;br /&gt;
            var unit = units.at(i);&lt;br /&gt;
&lt;br /&gt;
            var animation = GameAnimationFactory.createAnimation(map, unit.getX(), unit.getY());&lt;br /&gt;
            animation.writeDataInt32(unit.getX());&lt;br /&gt;
            animation.writeDataInt32(unit.getY());&lt;br /&gt;
            animation.writeDataInt32(5);&lt;br /&gt;
            animation.setEndOfAnimationCall(&amp;quot;ANIMATION&amp;quot;, &amp;quot;postAnimationHeal&amp;quot;);&lt;br /&gt;
            var delay = globals.randInt(135, 265);&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
            {&lt;br /&gt;
                delay *= i;&lt;br /&gt;
            }&lt;br /&gt;
            if (i % 2 === 0)&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_1.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.setSound(&amp;quot;power12_2.wav&amp;quot;, 1, delay);&lt;br /&gt;
            }&lt;br /&gt;
            if (animations.length &amp;lt; 7)&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
                powerNameAnimation.queueAnimation(animation);&lt;br /&gt;
                animations.push(animation);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                animation.addSprite(&amp;quot;power12&amp;quot;, -map.getImageSize() * 2, -map.getImageSize() * 2, 0, 2, delay);&lt;br /&gt;
                animations[counter].queueAnimation(animation);&lt;br /&gt;
                animations[counter] = animation;&lt;br /&gt;
                counter++;&lt;br /&gt;
                if (counter &amp;gt;= animations.length)&lt;br /&gt;
                {&lt;br /&gt;
                    counter = 0;&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        units.remove();&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==CO Images==&lt;br /&gt;
In the Setup step, we created a set of folders,  &#039;&#039;&#039;&amp;quot;mods/testco/images/co/&amp;quot;&#039;&#039;&#039; is where all the images for this tutorial will go. Make sure you also created the &#039;&#039;&#039;res.xml&#039;&#039;&#039; file inside the &#039;&#039;&#039;&amp;quot;mods/testco/images/co/&amp;quot;&#039;&#039;&#039; folder.&lt;br /&gt;
&lt;br /&gt;
Inside &#039;&#039;&#039;res.xml&#039;&#039;&#039; place the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;resources&amp;gt;&lt;br /&gt;
  &amp;lt;set path = &amp;quot;mods/testco/images/co/&amp;quot; /&amp;gt;&lt;br /&gt;
   &amp;lt;atlas linearFilter=&amp;quot;false&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;set scale_factor = &amp;quot;1.0&amp;quot; /&amp;gt; &lt;br /&gt;
      &amp;lt;image file=&amp;quot;co_test+nrm.png&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;set scale_factor = &amp;quot;1.0&amp;quot; /&amp;gt; &lt;br /&gt;
      &amp;lt;image file=&amp;quot;co_test+info.png&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;image file=&amp;quot;co_test+face.png&amp;quot; cols = &amp;quot;3&amp;quot; /&amp;gt;&lt;br /&gt;
   &amp;lt;/atlas&amp;gt;&lt;br /&gt;
&amp;lt;/resources&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;co_test+nrm.png&#039;&#039;&#039; is the image that will be displayed when the power and superpowers are activated. It will also show on the Intel options of the CO. This image has no set standard and can be of any size you choose, such that it fits on the screen.&lt;br /&gt;
[[File:Testco+nrm.png|thumb|center|co_test+nrm.png]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;co_test+info.png&#039;&#039;&#039; is the image that shows next to the Star Meter of the CO as well as in some menus of the game. The standard size for this image is 32x12.&lt;br /&gt;
&lt;br /&gt;
[[File:Testco+info.png|thumb|center| co_test+info.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;co_test+face.png&#039;&#039;&#039; is the portrait picture of the CO, with three different facial expressions, the order of these facial expressions is normal, happy and sad, these can be given a rows argument to have Advance Wars style animations. You can use the &#039;&#039;&#039;scale_factor&#039;&#039;&#039; parameter to resize the images in-game. The standard for this image is 144x48 (48x48 for each facial expression).&lt;br /&gt;
&lt;br /&gt;
[[File:Testco+face.png|thumb|center|co_test+face.png]]&lt;br /&gt;
&lt;br /&gt;
==CO Music==&lt;br /&gt;
Inside the constructor of the CO, place the following code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
var Constructor = function()&lt;br /&gt;
{&lt;br /&gt;
  //Rest of the code ommited for brevity&lt;br /&gt;
 this.loadCOMusic = function (co,map) {&lt;br /&gt;
        &lt;br /&gt;
        switch (co.getPowerMode()) {&lt;br /&gt;
            case GameEnums.PowerMode_Power:&lt;br /&gt;
                audio.addMusic(&amp;quot;mods/testco/music/cos/Power.mp3&amp;quot;, 0, 0);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Superpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;mods/testco/music/cos/Super.mp3&amp;quot;, 0, 0);&lt;br /&gt;
                break;&lt;br /&gt;
            case GameEnums.PowerMode_Tagpower:&lt;br /&gt;
                audio.addMusic(&amp;quot;mods/testco/music/cos/Super.mp3&amp;quot;, 0, 0);&lt;br /&gt;
                break;&lt;br /&gt;
            default:&lt;br /&gt;
                audio.addMusic(&amp;quot;mods/testco/music/cos/Theme.mp3&amp;quot;, 0, 0);&lt;br /&gt;
                break;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Constructor.prototype = CO;&lt;br /&gt;
var CO_TEST = new Constructor();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Make sure the files are properly placed inside the path passed to the  &#039;&#039;&#039;audio.addMusic()&#039;&#039;&#039; function.&lt;br /&gt;
&lt;br /&gt;
==Activating the CO==&lt;br /&gt;
*Start the Game. &lt;br /&gt;
*Click &#039;Options&#039;. &lt;br /&gt;
*On the right hand side of the Options menu, click &#039;Mods&#039;. &lt;br /&gt;
*Activate the checkbox &#039;Test CO&#039; and click &#039;Exit&#039;. &lt;br /&gt;
After you do, the game will restart on its own. Once the game restarts, click on &#039;Style CO&#039;. The test CO should show up under Orange Star.&lt;br /&gt;
&lt;br /&gt;
== Further Information ==&lt;br /&gt;
To learn more about the details of how the code works, this page breaks down Andy and the specifics of each segment of code.&lt;br /&gt;
&lt;br /&gt;
[[Andy Breakdown]]&lt;br /&gt;
[[Category:Modding tutorials]]&lt;/div&gt;</summary>
		<author><name>MrDuck557</name></author>
	</entry>
</feed>