[Sprint Samsung Galaxy S III] studentjunk:
A while ago someone in the MOAR thread asked about changing the battery animation. I thought I would post a few, and do an abbreviated how-to to make adjustments.

For people on stock ROM, you first will need to make a 1% battery mod with your SystemUI.apk. This has been every elegantly described by RMarkwald at team us cellular site. I use the apk multi tool for my compilng and decompiling. as you can see, only two xml files need to be edited: stat_sys_battery.xml and stat_sys_battery_charging.xml.

Decoding the xml is not very difficult, which makes editing quite easy. When the phone is running on battery, it uses the stat_sys_battery.xml. Each item refers to a png file by name. the maxLevel is the maximum battery percentage that is used by the png file.

<?xml version="1.0" encoding="UTF-8"?>

-<level-list xmlns:android="http://schemas.android.com/apk/res/android"><item android:maxLevel="0" android:drawable="@drawable/stat_sys_battery_0"/><item android:maxLevel="1" android:drawable="@drawable/stat_sys_battery_1"/><item android:maxLevel="2" android:drawable="@drawable/stat_sys_battery_2"/><item android:maxLevel="3" android:drawable="@drawable/stat_sys_battery_3"/><item android:maxLevel="4" android:drawable="@drawable/stat_sys_battery_4"/><item android:maxLevel="5" android:drawable="@drawable/stat_sys_battery_5"/><item android:maxLevel="6" android:drawable="@drawable/stat_sys_battery_6"/><item android:maxLevel="7" android:drawable="@drawable/stat_sys_battery_7"/><item android:maxLevel="8" android:drawable="@drawable/stat_sys_battery_8"/><item android:maxLevel="9" android:drawable="@drawable/stat_sys_battery_9"/><item android:maxLevel="10" android:drawable="@drawable/stat_sys_battery_10"/><item android:maxLevel="11" android:drawable="@drawable/stat_sys_battery_11"/><item android:maxLevel="12" android:drawable="@drawable/stat_sys_battery_12"/><item android:maxLevel="13" android:drawable="@drawable/stat_sys_battery_13"/><item android:maxLevel="14" android:drawable="@drawable/stat_sys_battery_14"/><item android:maxLevel="15" android:drawable="@drawable/stat_sys_battery_15"/><item android:maxLevel="16" android:drawable="@drawable/stat_sys_battery_16"/><item android:maxLevel="17" android:drawable="@drawable/stat_sys_battery_17"/><item android:maxLevel="18" android:drawable="@drawable/stat_sys_battery_18"/><item android:maxLevel="19" android:drawable="@drawable/stat_sys_battery_19"/><item android:maxLevel="20" android:drawable="@drawable/stat_sys_battery_20"/><item android:maxLevel="21" android:drawable="@drawable/stat_sys_battery_21"/>

When the phone is charging, it uses the stat_sys_battery_charging.xml.

<item android:maxLevel="92">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_92" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim93" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim94" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim95" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim96" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim97" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="93">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_93" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim94" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim95" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim96" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim97" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="94">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_94" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim95" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim96" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim97" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="95">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_95" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim96" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim97" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="96">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_96" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim97" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="97">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_97" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="98">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_98" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

</item>

<item android:maxLevel="99">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="2000" android:drawable="@drawable/stat_sys_battery_99" />

<item android:duration="80" android:drawable="@drawable/stat_sys_battery_charge_anim100" />

</animation-list>

The above item is from a ginger bread based animation. The maxlevel shows the maximum charge level to use the item. The duration is the amount of milliseconds the png file will be displayed, and of course they are displayed in the order typed.

As you can see, editing each item will allow one to change the animation various ways. Some people prefer a completely stock animation (no animation), which has a charging file like this:

<?xml version="1.0" encoding="utf-8"?>

<level-list

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:drawable="@drawable/stat_sys_battery_charge_anim0" android:maxLevel="0" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim1" android:maxLevel="1" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim2" android:maxLevel="2" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim3" android:maxLevel="3" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim4" android:maxLevel="4" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim5" android:maxLevel="5" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim6" android:maxLevel="6" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim7" android:maxLevel="7" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim8" android:maxLevel="8" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim9" android:maxLevel="9" />

<item android:drawable="@drawable/stat_sys_battery_charge_anim10" android:maxLevel="10" />

Alternatively, one could have a stock like animation that shows the battery uncharged icon. This works better if you have png files with the battery percentage on them, which can be easily generated from The ROM Fumbler

<?xml version="1.0" encoding="utf-8"?>

<level-list

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:maxLevel="0">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="1500" android:drawable="@drawable/stat_sys_battery_charge_anim0" />

<item android:duration="500" android:drawable="@drawable/stat_sys_battery_0" />

</animation-list>

</item>

<item android:maxLevel="1">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="1500" android:drawable="@drawable/stat_sys_battery_charge_anim1" />

<item android:duration="500" android:drawable="@drawable/stat_sys_battery_1" />

</animation-list>

</item>

<item android:maxLevel="2">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="1500" android:drawable="@drawable/stat_sys_battery_charge_anim2" />

<item android:duration="500" android:drawable="@drawable/stat_sys_battery_2" />

</animation-list>

</item>

<item android:maxLevel="3">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="1500" android:drawable="@drawable/stat_sys_battery_charge_anim3" />

<item android:duration="500" android:drawable="@drawable/stat_sys_battery_3" />

</animation-list>

</item>

<item android:maxLevel="4">

<animation-list android:oneshot="false"

xmlns:android="http://schemas.android.com/apk/res/android">

<item android:duration="1500" android:drawable="@drawable/stat_sys_battery_charge_anim4" />

<item android:duration="500" android:drawable="@drawable/stat_sys_battery_4" />

</animation-list>

</item>

If you are moding a stock ROM to have the 1% mod, then you need to edit the xml files, and also add the png icon files to the folder res\drawable-xhdpi. But this can vary from ROM to ROM. These battery mods can be customized in The ROM fumbler, or swiped from a MOD or ROM systemUI.apk. If you are swiping, then please give credit if you are going to distribute it.

Below you will find several mods. I have been using MOAR for a while, so I know that each of the mods beginning with MOAR work on my version of this ROM. Basically, to make these, I pulled compiled the systemUI of the xml files, and then put the compiled xml files into the universal flasher morph folder (swiped from OlliG with permission).

For the MD4 files, I only tested the MD4stock100batterymod.zip file, but I made the others following the same procedure. Of note, any SystemUI.apk mods will be overwritten if you are using a a moded ROM.

The MOAR mods are safe to flash on moded ROMs. They do not affect other mods. However, I only tested on my own MOAR ROM, so I don't know if they work on other ROMs. However, I think so long as you back up, it's worth a try if you are looking to change up that battery icon.