Changing the Power Charge Rate (AW2)

Discussion of hacking, editing and developments in Advance Wars games.
Remember, no Rom Requests
User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD

Changing the Power Charge Rate (AW2)

Post by Xenesis » Sun May 04, 2008 2:54 am

Okay, I figured this out today, but I thought I'd share.

As you all may know, the AW2 Charge Rate is as follows:

Attacker:
(HP Destroyed * Unit Cost)/2

Defender
HP Destroyed * Unit Cost

To fiddle with this effectively you need to fiddle with two opcodes.

The first is at 41CB2 in the ROM.

By default this is:

Code: Select all

1C01 mov r1, r0
(or 011C when you're in a hex editor).

Change this to

Code: Select all

0041 lsl r1, r0, #0x1 - Doubles the attacker's charge relative to before
0081 lsl r1, r0, #0x2 - Quadruples the attacker's charge rate
00C1 lsl r1, r0, 0x3 - Multiplies by 8
The first will make the attacker and defender charge at the same rate, the second makes the attacker charge twice as fast and the third, notably makes the attacker charge four times as fast as the defender.

The second one is to change is the overall charge rate. This is found at 41C88 in the ROM.
By default:

Code: Select all

1C05 mov r5, r0
(or 051C in your hex editor).

Modify it like so

Code: Select all

0845 lsr r5, r0, #0x1 - Halves overall charge rate
0885 lsr r5, r0, #0x2 - Quarters overall charge rate
08C5 lsr r5, r0, #0x3 - Eighths overall charge rate
0045 lsl r5, r0, #0x1 - Doubles overall charge rate
0085 lsl r5, r0, #0x2 - Quadruples overall charge rate
00C5 lsl r5, r0, #0x3 - Multiplies overall charge rate by 8
I wouldn't recommend decreasing the overall charge rate to less than an Eighth of the current, because you'll start losing accuracy (If you have any unit prices with hundreds digits). But yes, fiddling with this should let you change it to your whim.

Edit: As an addendum
080441D0 - Star Capacity
This number is the capacity of each star in G. by default it's #0x2328 (9000). Change it to what you feel like.

Edit 2: An addendum to the addendum
Changing the behaviour of the cost increases as powers are used (lots of stuff)

Code: Select all

080441A8 	(21C8)	- Multiplier for Star Cost after 9 uses, change #0xC8 to the multiple of choice (C8 = 200, or double cost)
080441A4	(2809)	- Compares the address to the maximum number of COP uses before it becomes fixed. By default the 10th use becomes fixed. Change this from 0 to #0xFF
080441BC	(1809)	- Adds cost increase to base amount. Change to 1A49 to subtract it instead (careful that you don't get negative numbers!)
080441B2...B6 		- Routine that generates the total cost increase
0081 lsl r1, r0, #0x2
1809 add r1, r1, r0
0489 lsl r1, r1, #0x12
The three opcodes can be manipulated to give you any charge rate increase you desire, really. To change it from +20% to say +40%, change the lsl #0x12 to lsl #0x13. Likewise change it to lsl#0x11 to get it to +10% per use.
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

User avatar
Terragent
Rank: Cussing Aussie
Location: Adelaide, Australia

Re: Changing the Power Charge Rate (AW2)

Post by Terragent » Sun May 04, 2008 11:28 am

Oh yes oh yes oh yes.

User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD

Re: Changing the Power Charge Rate (AW2)

Post by Xenesis » Sun May 04, 2008 2:33 pm

Added the Star Capacity address.
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

User avatar
Xenesis
Tri-Star CO
Tri-Star CO
Rank: Hydrocarbon Inspector
3DS Code: 2535-4646-7163
Location: 0x020232DD

Re: Changing the Power Charge Rate (AW2)

Post by Xenesis » Sun May 04, 2008 3:22 pm

Added a whole ton of stuff related to how powers increase in cost after use.
IST wrote:Even the worst individual needs to discover the joys of a chicken statue that is also a pregnant blonde housewife.

Who is online

Users browsing this forum: Multivac [Bot] and 0 guests