that would be great--why not make one?I wish there was an ability editor that made this so much easier.
Here's Snow Warning for Fire Red! I'll update this and port it to Emerald. I'm going to edit it slightly in the future to account for the new weather abilities too that Kleenex has already written routines for.
Snow Warning
Spoiler:Fire Red
Spoiler:Code:.text .text .align 2 .thumb .thumb_func .global snowwarning BufferAbility: ldrb r0, [r1] cmp r0, #0xSnowWarning beq SnowWarning SandStreamCheck: cmp r0, #0x2D bne ReturnChecks SandStream: ldr r2, .Return bx r2 ReturnChecks: ldr r4, .Return2 bx r4 SnowWarning: CheckWeather: ldr r2, .WeatherLoc ldrh r1, [r2] mov r0, #0x80 and r0, r1 CheckHail: cmp r0, #0x0 beq Continue bl EndScript SetHail: mov r0, #0x80 strh r0, [r2] ldr r2, .Place mov r0, #0x0 strb r0, [r2] ldr r0, .SnowWarningBS bl PlayScript ldr r0, .Place2 mov r1, r10 strb r1, [r0, #0x17] bl OtherBL EndScript: ldr r4, .EndScriptBL bx r4 PlayScript: ldr r2, .PlayScriptBL bx r2 OtherBL: ldr r0, .OtherBL bx r0 .align 2 .Return: .word 0x0801A2AD .Return2: .word 0x0801A149 .WeatherLoc: .word 0x02023F1C .Place: .word 0x02023F48 .SnowWarningBS: .word 0x08CCCCCC .Place2: .word 0x02023FC4 .EndScriptBL: .word 0x0801BBAB .PlayScriptBL: .word 0x0801BC25 .OtherBL: .word 0x0801BB5B #Insert 00 48 00 47 xx xx xx 08 at 1A140
Can someone please teach me, I tried all the abilities here but when I try it out, it just hangs or reset (well except for the Skill Link which is just some simple adding and editing in the hex(?)). I use emerald version but I'm hacking the one that is already PSS split from a video.
Here the step I do from what I understand with an example of "Tangled Feet"
1. Copy the code and paste it to notepad. save it as ASM file.
2. Drag the ASM file to "thumb".
3. Open the resulting file and the rom I'm hacking in the HxD.
4. Copy and paste the bytes(?) of the resulting file on the free space of the rom
5. (in the rom) Goto 468EC
6. starting from that address, typed 00 49 08 47 xx xx xx 08 (xx xx xx with my own address)
7. save it; open PGE and edit the pokemon which should have that ability.
(I already expanded that ability table by the way)
8. Try the pokemon with that ability and do what should be done to trigger the ability...
Then BOOM, it did not work.
Don't bother with that thread, it was good 2 years ago. If you hack Emerald, check out the battle engine in my signature and enjoy a new battle experience.
.text
.align 2
.thumb
.thumb_func
.global typechangeabilities
BufferAbility:
mov r0, r6
add r0, #0x20
ldrb r1, [r0]
NormalCheck:
mov r0, r9
cmp r0, #0x0
bne NormalizeCheck
RefrigerateCheck:
cmp r1, #0x87
bne PixilateCheck
Refrigerate:
mov r0, #0xF
b StoreType
PixilateCheck:
cmp r1, #0x88
bne AerilateCheck
Pixilate:
mov r0, #0x17
b StoreType
GalvanizeCheck:
cmp r1, #0x8D
bne PixilateCheck
Galvanize:
mov r0, #0xD
b StoreType
AerilateCheck:
cmp r1, #0x89
bne Return
Aerilate:
mov r0, #0x2
StoreType:
mov r9, r0
ldr r0, .ChangeTypeLoc
ldr r1, [r0]
add r1, #0x13
ldrb r1, [r1]
mov r2, #0x3F
and r2, r1
cmp r2, #0x0
bne Return
mov r2, r9
strb r2, [r1]
Boost:
mov r0, r8
mov r1, #0xA7
mul r0, r1
lsr r0, #0x7
mov r8, r0
mul r7, r1
lsr r7, #0x7
b Return
NormalizeCheck:
cmp r1, #0x8A
bne Return
Normalize:
mov r0, #0x0
mov r9, r0
Return:
ldr r0, [sp, #0x4]
ldrh r0, [r0, #0xA]
str r0, [sp, #0x18]
ldrh r0, [r6, #0x2E]
cmp r0, #0x87
bne NoEnigmaBerry
ldr r1, .Return
bx r1
NoEnigmaBerry:
ldr r0, .Return2
bx r0
.align 2
.ChangeTypeLoc: .word 0x02023FE8
.Return: .word 0x0803ED87
.Return2: .word 0x0803EDA1[/SPOILER]
edit: if this helps with anything im using the MrDS rombase which might affect things like pointers.
The ability names and descriptions and still stored in tables.Hey, can anyone explain to me if I need to, or why I don't need to, point Abilities in PGE to some specific offset? Does the game just check the string representation of the ability to see if the Pokémon has it? Or am I missing the part where I somehow point it to the index of the ability in PGE?
The ability names and descriptions and still stored in tables.
individual abilities are each checked for in the battle engine as indexes.Thanks, I understand that, but how is the actual effect of the ability called in battle? I can't find anyway to point the name of the ability to its corresponding effect. So the question is, do I have to?
individual abilities are each checked for in the battle engine as indexes.
this next scene is a plausible way of it working
so like take levitate
let's say we have our latios with levitate
earthquake is used by opponent
game checks type of move used - returns ground
game checks latios for ability - returns levitate
compares it with levitate's index number
branches off to levitate's battle message printing and zero damage done
attack over
Pointer to your asm routine +1.One more thing, this line of code I've found at the end of each ability script,
Spoiler:#insert 01 49 08 47 00 00 xx xx xx 08 at 026192
I assume I'm supposed to change those x's to something meaningful like a pointer, is that the case?
Pointer to your asm routine +1.
Can anyone code Beast Boost?
Thank you!