Thread: Development: Wild double / triple battles
View Single Post
  #37    
Old June 3rd, 2011 (02:42 PM). Edited June 4th, 2011 by Team Fail.
Team Fail's Avatar
Team Fail Team Fail is online now
fun in the sun
Platinum Tier
 
Join Date: May 2009
Age: 20
Gender: Male
Nature: Brave
Posts: 10,742
Quote originally posted by sonic1:
At 01065c put a branch to this routine:~
Code:
.thumb
.align 2

main:
LDR     R5, =0x20370CA  ' var 8009 adress. Chose this one because its not used often
LDRB    R5, [R5]
CMP     R5, #0xF 'If var 8009 is 0xF then go to new code. Else continue original code.
BEQ     new_code
STR     R1, [R2]
LDR     R1, =0x2023E82
MOV    R0, #0xF
STRB    R0, [R1]
LDR     R4, =0x8010665
BX      R4

new_code:        'What this code does is basically add 1 to the current value in r1, setting the double battle bit
ADD    R1, #1  ' see the line up
STR     R1, [R2]'----------Rest of the routine
LDR     R1, =0x2023E82
MOV    R0, #0xF
STRB    R0, [R1]
LDR     R4, =0x8010665
BX      R4
Presto! With var 8009 with value 0xF set, you can now have double battles. Any double battles: Wild, trainer, wireless, safari, blah blah blah.

~Sonic1
Ooh goody. Now, all that needs to be done is to write a routine that allows a wireless double battle to work!

Especially if each trainer tries to catch the same Pokemon.


Edit: Someone made a really good point on that video. I'll have to see to it. It is using surf to kill both opposing Pokemon. But, I don't think anything special will happen.
__________________


voler avec moi
Reply With Quote