Go Back   The PokéCommunity Forums > ROM Hacking > Research & Development
Reload this Page Development: Move Resource Thread

Notices
For all updates, view the main page.

Research & Development Got a well-founded knack with ROM hacking? Love reverse-engineering the Pokémon games? Or perhaps you love your assembly language. This is the spot for polling and gathering your ideas, and then implementing them! Share your hypothesis, get ideas from others, and collaborate to create!
Research & Development programs in this forum are subject to moderator approval before they are displayed.



Reply
 
Thread Tools
  #201    
Old January 21st, 2015 (12:28 AM).
jirachiwishmaker's Avatar
jirachiwishmaker
 
Join Date: Jul 2007
Location: Forina
Age: 29
Gender: Male
Nature: Lonely
The following is Boomburst animation for Emerald that translated from MrDollSteak's Rombase.

Spoiler:
02 74 72 59 08 02 05 01 00 01 00 00 00 0C 00 1A 21 05 00 D6 27 00 DB 27 0A 03 03 91 6D 10 08 02 01 00 00 02 98 38 59 08 03 06 00 00 00 00 00 00 00 00 1F 00 08 00 19 F1 00 C0 02 ZZ YY XX 08 02 04 00 00 1D 00 F4 FF 00 00 02 ZZ YY XX 08 02 04 00 00 F4 FF E3 FF 01 00 04 10 03 91 6D 10 08 02 01 00 00 02 98 38 59 08 03 06 00 00 00 00 00 00 00 00 1F 00 08 00 19 F1 00 C0 02 ZZ YY XX 08 02 04 00 00 0C 00 E3 FF 01 00 02 ZZ YY XX 08 02 04 00 00 E3 FF F4 FF 00 00 04 10 03 91 6D 10 08 02 01 00 00 02 98 38 59 08 03 06 00 00 00 00 00 00 00 00 1F 00 08 00 19 F1 00 C0 02 ZZ YY XX 08 02 04 00 00 18 00 E8 FF 01 00 02 ZZ YY XX 08 02 04 00 00 E8 FF E8 FF 00 00 05 0B 03 02 74 72 59 08 02 05 01 00 01 00 0C 00 00 00 1A 21 05 0B 03 0D 08

At offset XX YY ZZ:
D6 27 D6 27 14 49 52 08 18 37 59 08 00 00 00 00 A8 C6 2E 08 C9 77 0A 08
Reply With Quote
  #202    
Old February 4th, 2015 (12:58 PM). Edited February 4th, 2015 by Edwearth.
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Hi, i have a question about the psystrike effect.

Quote originally posted by daniilS:
@swapphysicalspecialdefence
copyarray 0x020247DC @fourbytesoffreespace 2
copyarray 0x020247DA 0x020247DC 2
copyarray @fourbytesoffreespace 0x020247DA 2
copyarray 0x02024840 @anotherfourbytesoffreespace 2
copyarray 0x0202483E 0x02024840 2
copyarray @anotherfourbytesoffreespace 0x0202483E 2
return
Ok, but what are :
_ 0x020247DC
_0x020247DA
_0x02024840
_0x0202483E
Yeah i imagine what they are, but when i tried to find them with the VBA's memory vewer there are just lines of "00".
It is for FireRed, right ?

Edit : I tried to make this effect in Emerald :
Spoiler:

Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @start
attackcanceler
accuracycheck 0x82D8A5E 0x0
call @swap
attackstring
ppreduce
calculatedamage
attackanimation
waitanimation
cmd5c 0x0
waitstate
datahpupdate 0x0
graphicalhpupdate 0x0
critmessage
waitmessage 0x40
resultmessage
waitmessage 0x40
call @swap
goto 0x82D8A47

@swapphysicalspecialdefence
copyarray 0x020247A0 @ennemy1 2
copyarray 0x020247A6 0x020247A0 2
copyarray @ennemy1 0x020247A6 2
copyarray 0x02024804 @ennemy2 2
copyarray 0x0202480A 0x02024804 2
copyarray @ennemy2 0x0202480A 2
copyarray 0x02024548 @ally1 2
copyarray 0x0202454E 0x02024548 2
copyarray @ally1 0x0202454E 2
copyarray 0x020245AC @ally2 2
copyarray 0x020245B2 0x020245AC 2
copyarray @ally2 0x020245B2 2
return


I don't know if it works. I'll try it tomorrow.
Reply With Quote
  #203    
Old February 4th, 2015 (10:41 PM).
daniilS's Avatar
daniilS
busy trying to do stuff not done yet
 
Join Date: Aug 2013
Age: 15
Gender: Male
Quote originally posted by Edwearth:
Hi, i have a question about the psystrike effect.



Ok, but what are :
_ 0x020247DC
_0x020247DA
_0x02024840
_0x0202483E
Yeah i imagine what they are, but when i tried to find them with the VBA's memory vewer there are just lines of "00".
It is for FireRed, right ?

Edit : I tried to make this effect in Emerald :
Spoiler:

Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @start
attackcanceler
accuracycheck 0x82D8A5E 0x0
call @swap
attackstring
ppreduce
calculatedamage
attackanimation
waitanimation
cmd5c 0x0
waitstate
datahpupdate 0x0
graphicalhpupdate 0x0
critmessage
waitmessage 0x40
resultmessage
waitmessage 0x40
call @swap
goto 0x82D8A47

@swapphysicalspecialdefence
copyarray 0x020247A0 @ennemy1 2
copyarray 0x020247A6 0x020247A0 2
copyarray @ennemy1 0x020247A6 2
copyarray 0x02024804 @ennemy2 2
copyarray 0x0202480A 0x02024804 2
copyarray @ennemy2 0x0202480A 2
copyarray 0x02024548 @ally1 2
copyarray 0x0202454E 0x02024548 2
copyarray @ally1 0x0202454E 2
copyarray 0x020245AC @ally2 2
copyarray 0x020245B2 0x020245AC 2
copyarray @ally2 0x020245B2 2
return


I don't know if it works. I'll try it tomorrow.
Please forget that post. I was a noob at the time. I'm sorry.
There was only a slight amount of testing done and it doesn't account for any unique causes, so it's probably bugged as hell the Distortion World.
__________________
Reply With Quote
  #204    
Old February 4th, 2015 (11:53 PM). Edited February 5th, 2015 by Edwearth.
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
I think, if we swap the Def and the spe Def of the two allies and the two enemies, it will work. The AI will use it very badly, but I'm doing it to make two signature moves (mewtwo and keldeo if I remember). So this move will be used by the user, not the AI.

just I need explanation about "copyarray". What does the "2" do at the end of this command ? I think I have to find free ram space by myself, maybe bsp can't find it alone.
Thanks
Reply With Quote
  #205    
Old February 5th, 2015 (05:12 AM).
KDS's Avatar
KDS
 
Join Date: Jul 2013
Age: 20
Gender: Male
Quote originally posted by Edwearth:
I think, if we swap the Def and the spe Def of the two allies and the two enemies, it will work. The AI will use it very badly, but I'm doing it to make two signature moves (mewtwo and keldeo if I remember). So this move will be used by the user, not the AI.

just I need explanation about "copyarray". What does the "2" do at the end of this command ? I think I have to find free ram space by myself, maybe bsp can't find it alone.
Thanks
Only swapping def and sp def won't do the job mate, defense stat changes, plus abilties affecting the defense and sp def also do matter.
Reply With Quote
  #206    
Old February 5th, 2015 (05:22 AM).
daniilS's Avatar
daniilS
busy trying to do stuff not done yet
 
Join Date: Aug 2013
Age: 15
Gender: Male
Quote originally posted by KDS:
Only swapping def and sp def won't do the job mate, defense stat changes, plus abilties affecting the defense and sp def also do matter.
That's what I meant. Please forgive my noobishness at that time, I've realized a long time ago already it requires some glorious ASMAGIX.
__________________
Reply With Quote
  #207    
Old February 5th, 2015 (09:53 AM).
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Oh, yes sorry I totally forgot abilities and moves like magic mirror. So, is there a function like calculateSpeAttack, calculateDeffense then calculatedamages? :p
What is Asmagix?
Reply With Quote
  #208    
Old February 5th, 2015 (10:22 AM).
pokenoobend's Avatar
pokenoobend
 
Join Date: Jan 2014
Quote originally posted by Edwearth:
What is Asmagix?
I googled ASMAGIX because I was wondering that too, the first page has one link to PC where someone mentions it then says, more serious answer ... . Maybe a troll term?
Reply With Quote
  #209    
Old February 5th, 2015 (11:02 AM).
GoGoJJTech's Avatar
GoGoJJTech
http://GoGoJJTech.com (WIP!)
Community Supporter
 
Join Date: Nov 2012
Location: Earth
Age: 16
Gender: Male
Nature: Quiet
Quote originally posted by pokenoobend:
I googled ASMAGIX because I was wondering that too, the first page has one link to PC where someone mentions it then says, more serious answer ... . Maybe a troll term?
It's a play on the term "ASM" or "Assembly" which is the language the GBA runs on.
__________________
I believe in Jesus Christ my Savior. If you do too, and aren't scared to admit it, then copy and paste this into your signature.
The SoulSilver Music Patch - The Black Music Patch - Mega-Huge Sappy Tutorial
Romhack.me Profile - Pokecommunity Profile - Pokemonhackersonline Profile - Youtube Channel

Join us in the romhacking chat
Pokémon Platinum Red and Blue
Reply With Quote
  #210    
Old February 5th, 2015 (11:25 AM). Edited February 7th, 2015 by Edwearth.
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Quote originally posted by GoGoJJTech:
It's a play on the term "ASM" or "Assembly" which is the language the GBA runs on.
I know this, but i thought that it is an language between ASM and C or a simplified ASM.

Edit :

I tried something to make the swap. I know it's a wrong way to create the move but I did it like a training.
But when I use it, the effect resets the game.
Here my effect :
Spoiler:

Code:
#dynamic 0xF10526
#freespacebyte 0xFF

#org @start
attackcanceler
accuracycheck 0x82D8A5E 0x0
call @swap
attackstring
ppreduce
calculatedamage
attackanimation
waitanimation
cmd5c 0x0
waitstate
datahpupdate 0x0
graphicalhpupdate 0x0
critmessage
waitmessage 0x40
resultmessage
waitmessage 0x40
call @swap
goto 0x82D8A47

#org @swap
copyarray 0x020247A0 0x20375F0 2 //ennemy1
copyarray 0x020247A6 0x020247A0 2
copyarray 0x20375F0 0x020247A6 2

copyarray 0x02024804 0x20375F0 2 //ennemy2
copyarray 0x0202480A 0x02024804 2
copyarray 0x20375F0 0x0202480A 2

copyarray 0x02024548 0x20375F0 2 //ally1
copyarray 0x0202454E 0x02024548 2
copyarray 0x20375F0 0x0202454E 2

copyarray 0x020245AC 0x20375F0 2 //ally2
copyarray 0x020245B2 0x020245AC 2
copyarray 0x20375F0 0x020245B2 2
return

//0x20375F0 = Var 800D


Why ?

I also tried to did it just for the first Pokemon in my team in ASM, but it also resets the game.
Here my ASM code :
Spoiler:

Code:
.text
.align 2
.thumb
.thumb_func
.global swap

main:
	push {r0-r3, lr}
	ldr r0, .DEF
	ldr r1, .DEF
	
	ldr r2, .SPEDEF
	ldr r3, .SPEDEF
	
	strh r0, [r3]
	strh r2, [r1]
	
	
	pop {r0-r3, pc}
	
.align 2
.DEF:
	.word 0x02024548
.SPEDEF:
	.word 0x0202454E


Why ? It's my codes ? It's the action which is forbidden ?

Edit : Ok, forget this, i found the solution.
But i have another question ! How to port the callasm command ? I compile the routine with the address 0x02024214 for the scriptlocation. Ok, but I have to repoint and extend the battle script command table to had the new command F9 XX XX XX 08. Where is this table ? And how do you find it ?
Reply With Quote
  #211    
Old February 9th, 2015 (01:01 AM). Edited February 9th, 2015 by Artemis64.
Artemis64
 
Join Date: Mar 2014
Gender: Male
A new attack particle:
Healing Sparkles:
Spoiler:

Fire Sprite (new, removed some of the edges):
Spoiler:

Horn Sprite:
Spoiler:

Mean Look:
Spoiler:
Reply With Quote
  #212    
Old February 23rd, 2015 (05:28 PM). Edited 3 Weeks Ago by Edwearth.
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
So I made the effect for Oblivion Wings for Emerald.

First insert this routine :
Spoiler:

Code:
.text
.align 2
.thumb
.thumb_func
.global main

main:
	push {r0-r3, lr}
	
	ldr r0, = (0x020241F0)
	
	ldrh r1, [r0]
	mov r2, #0x3
        mul r1, r2
        lsr r1, #2
        cmp r1, #0x0
        beq nineth
	b eighth

nineth:
	add r1, #0x1
	b eighth
	
eighth:
	ldr r2, = (0x0202420B)
	ldrb r2, [r2]
	
	cmp r2, #0x0
	beq fourth
	cmp r2, #0x1
	beq fifth
	cmp r2, #0x2
	beq sixth
	cmp r2, #0x3
	beq seventh
	b end

fourth:
	ldr r0, = (0x02024542)
	b third
	
fifth:
	ldr r0, = (0x0202479A)
	b third
	
sixth:
	ldr r0, = (0x020245A6)
	b third

seventh:
	ldr r0, = (0x020247FE)
	b third
	
third:
	mov r2, r0
	ldrh r3, [r0]
	
	add r2, #0x2
	ldrh r2, [r2]
	
	add r1, r3
	
	cmp r1, r2
	bhs first
	cmp r1, r2
	blo second
	b end
	
second:
	strh  r1, [r0]
	b end
	
first:
	strh  r2, [r0]
	b end
	
end:
	pop {r0-r3, pc}
	
.align 2
In compiled version:
Code:
0F B5 16 48 01 88 03 22 51 43 89 08 00 29 00 D0 01 E0 01 31 FF E7 12 4A 12 78 00 2A 06 D0 01 2A 06 D0 02 2A 06 D0 03 2A 06 D0 15 E0 0D 48 05 E0 0D 48 03 E0 0D 48 01 E0 0D 48 FF E7 02 1C 03 88 02 32 12 88 C9 18 91 42 04 D2 91 42 00 D3 03 E0 01 80 01 E0 02 80 FF E7 0F BD C0 46 F0 41 02 02 0B 42 02 02 42 45 02 02 9A 47 02 02 A6 45 02 02 FE 47 02 02


Then here is the effect:
Spoiler:

Code:
#dynamic 0xF00000
#freespacebyte 0xFF

#org @start
attackcanceler
accuracycheck 0x82D8A5E 0x0
attackstring
ppreduce
calculatedamage
attackanimation
waitanimation
missmessage
cmd5c 0x0
waitstate
graphicalhpupdate 0x0
datahpupdate 0x0
critmessage
waitmessage 0x40
resultmessage
waitmessage 0x40
negativedamage
orword 0x2024280 0x100
callasm 0x08XXXXXX
graphicalhpupdate 0x1
datahpupdate 0x1
setbyte 0x2024337 0x0
goto 0x82D8B2E
end
Where XXXXXX is a pointer to the routine +1

It looks working, but i'm not 100% sure. And I think that "Liqid Ooze" does nothing.

Edit : Wrong !
Reply With Quote
  #213    
Old 4 Weeks Ago (07:50 AM).
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Quote originally posted by KDS:
Some new effects:
1. Crush Grip: Just use the callasm statement after the announcement of attack and before the damage calculation.
Spoiler:

ASM:
Code:
.text
.align 2
.thumb
.thumb_func
.global crushgrip

main:
push {lr}
ldr r0, targetBank
ldrb r0, [r0]
ldr r1, battleData
mov r2, #0x58
mul r0, r2
add r3, r0, r1
ldrh r0, [r3, #0x28]
mov r2, #0x78
mul r0, r2
ldrh r1, [r3, #0x2c]
bl divide
mov r1, #0x1
add r1, r0
ldr r2, basePower
strb r1, [r2]
pop {r0}
bx r0

divide:
ldr r2, divider
bx r2

.align 2
targetBank: .word 0x02023D6C
battleData: .word 0x02023BE4
divider: .word 0x081E4019
basePower: .word 0x02023F50
There is a problem with the script. When you call the routine, it sets the base damages. But when you calculate damages, it resets the damages to the base damages of the move.
Reply With Quote
  #214    
Old 4 Weeks Ago (08:28 AM).
KDS's Avatar
KDS
 
Join Date: Jul 2013
Age: 20
Gender: Male
Quote originally posted by Edwearth:
There is a problem with the script. When you call the routine, it sets the base damages. But when you calculate damages, it resets the damages to the base damages of the move.
Could you please be more clear that what are you trying to stay. I am unable to understand.
Reply With Quote
  #215    
Old 4 Weeks Ago (08:43 AM).
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Quote originally posted by KDS:
Could you please be more clear that what are you trying to stay. I am unable to understand.
I call the routine, the base power of the move is set. The calculation is good. So 0x020244E0 (Emerald) takes 0x79 if the enemy is full life.
And then the calculate damage is called, and the base damages are reset. So 0x020244E0 takes 0x1 because in PGE I set the move's base power to 1.
So the damages inflicted to the foe are very low.
Reply With Quote
  #216    
Old 4 Weeks Ago (10:01 AM).
KDS's Avatar
KDS
 
Join Date: Jul 2013
Age: 20
Gender: Male
Quote originally posted by Edwearth:
I call the routine, the base power of the move is set. The calculation is good. So 0x020244E0 (Emerald) takes 0x79 if the enemy is full life.
And then the calculate damage is called, and the base damages are reset. So 0x020244E0 takes 0x1 because in PGE I set the move's base power to 1.
So the damages inflicted to the foe are very low.
You used the wrong offset for base power, use 0x02024400 instead
Reply With Quote
  #217    
Old 4 Weeks Ago (10:39 AM).
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Quote originally posted by KDS:
You used the wrong offset for base power, use 0x02024400 instead
Ok thank you! I just thought there was a mistake because at 0x02024400 i juste saw 0x0000.
Reply With Quote
  #218    
Old 4 Weeks Ago (09:59 AM).
Edwearth's Avatar
Edwearth
 
Join Date: May 2014
Location: Paris
Gender: Male
Here is my effect for V-Create. I used the Spherical Ice's effect for Close Combat.
It is for Emerald.

First we need to insert seven battle scripts.
Spoiler:

Defense
Code:
#dynamic 0xAAAAAA
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0x4 0x1
setbyte 0x202448E 0x92
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40

#org @end
goto 0x82D8A4E
Special Defense
Code:
#dynamic 0xBBBBBB
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0x20 0x1
setbyte 0x202448E 0x95
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40

#org @end
goto 0x82D8A4E
Speed
Code:
#dynamic 0xCCCCCC
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0x8 0x1
setbyte 0x202448E 0x93
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40

#org @end
goto 0x82D8A4E
Defense and Special Defense
Code:
#dynamic 0xDDDDDD
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0x24 0x1
setbyte 0x202448E 0x92
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40
setbyte 0x202448E 0x95
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40

#org @end
goto 0x82D8A4E
Defense and Speed
Code:
#dynamic 0xEEEEEE
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0xC 0x1
setbyte 0x202448E 0x92
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40
setbyte 0x202448E 0x93
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40

#org @end
goto 0x82D8A4E
Special Defense and Speed
Code:
#dynamic 0xFFFFFF
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0x28 0x1
setbyte 0x202448E 0x95
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40
setbyte 0x202448E 0x93
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40

#org @end
goto 0x82D8A4E
Defense and Special Defense and Speed
Code:
#dynamic 0xGGGGGG
#freespacebyte 0xFF

#org @start
setbyte 0x202448F 0x0
playstatchangeanimation 0x1 0x2C 0x1
setbyte 0x202448E 0x92
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40
setbyte 0x202448E 0x95
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40
setbyte 0x202448E 0x93
statbuffchange 0x80 true @end
jumpifbyte 0x0 0x2024337 0x2 @end
printfromtable 0x85CC89C
waitmessage 0x40


#org @end
goto 0x82D8A4E


The we have to insert this routine at 0xHHHHHH.
Spoiler:

Code:
.text
.align 2
.thumb
.thumb_func

main:
	ldr r1, .battleData
	ldr r0, .userBank
	ldrb r0, [r0]
	mov r3, #0x58
	mul r3, r0
	add r1, #0x1a
	add r3, r1
	ldrb r0, [r3]
	ldrb r1, [r3, #0x3]
	ldrb r2, [r3, #0x1]
	mov r3, #0x0
	cmp r0, r3
	beq defIsZero
	cmp r1, r3
	beq spdefIsZero3
	cmp r2, r3
	beq speedIsZero3
	ldr r4, .lowerAll
	b end

defIsZero:
	cmp r1, r3
	beq spdefIsZero1
	b spdefIsZero2
	b end

spdefIsZero1:
	cmp r2, r3
	beq any
	ldr r4, .lowerSpeed
	b end
	
spdefIsZero2:
	cmp r2, r3
	beq speedIsZero1
	ldr r4, .lowerSpdDefSpeed
	b end

speedIsZero1:
	ldr r4, .lowerSpDef
	b end
	
spdefIsZero3:
	cmp r2, r3
	beq speedIsZero2
	ldr r4, .lowerDefSpeed
	b end
	
speedIsZero2:
	ldr r4, .lowerDef
	b end
	
speedIsZero3:
	ldr r4, .lowerDefSpDef
	b end
	
any:
	ldr r4, .endBS
	b end

end:
	ldr r5, .activeBSPointer
	str r4, [r5, #0x0]
	bx lr

.align 2
.battleData:		        .word 0x02024084
.userBank:			.word 0x0202420B
.activeBSPointer:	        .word 0x02024214
.lowerSpDef:		        .word 0x08BBBBBB
.lowerDef:			.word 0x08AAAAAA
.lowerDefSpDef:		.word 0x08DDDDDD
.lowerDefSpeed:		.word 0x08EEEEEE
.lowerSpdDefSpeed:	.word 0x08FFFFFF
.lowerAll:			        .word 0x08GGGGGG
.lowerSpeed:		        .word 0x08CCCCCC
.endBS:				.word 0x082D8A4E


And last, we have to insert the effect for the attack.
Spoiler:

Code:
#dynamic 0xF1138F
#freespacebyte 0xFF

#org @start
attackcanceler
accuracycheck 0x82D8A5E 0x0
attackstring
ppreduce
calculatedamage
attackanimation
waitanimation
missmessage
cmd5c 0x0
waitstate
graphicalhpupdate 0x0
datahpupdate 0x0
critmessage
waitmessage 0x40
resultmessage
waitmessage 0x40
faintpokemon 0x0 0x0 0x8000000
callasm 0xHHHHHH + 1


With this effect, you have different animation for each possibility.
Reply With Quote
  #219    
Old 1 Week Ago (01:10 AM). Edited 1 Week Ago by Artemis64.
Artemis64
 
Join Date: Mar 2014
Gender: Male
Here's an updated version of Fire Fang that better resembles the DS Fire Fang:
Spoiler:

02 74 72 59 08 02 05 01 00 01 00 00 00 0A 00 9F 09 05 00 9B 27 00 97 27 00 2D 27 0A 01 0C 0C 08 19 A1 00 3F 02 80 70 59 08 02 06 00 00 E0 FF 00 00 00 00 33 03 0A 00 02 80 70 59 08 02 06 00 00 20 00 04 00 00 00 CD FC 0A 00 04 0A 0E 18 2D 2D 08 04 04 19 93 00 3F 05 02 74 72 59 08 02 05 01 00 01 00 0A 00 00 00 9F 09 05 0B 03 0D 08

Also a couple of new moves:
Dark Pulse:
Spoiler:

14 00 17 00 E9 27 00 A7 27 19 98 00 C0 03 99 7B 0A 08 05 05 00 00 08 28 0C 00 05 00 01 00 04 04 03 65 60 0D 08 05 05 F9 FF F9 FF 0B 00 00 00 00 00 19 D9 00 C0 02 ZZ YY XX 08 82 01 00 00 02 ZZ YY XX 08 82 01 20 00 02 ZZ YY XX 08 82 01 40 00 02 ZZ YY XX 08 82 01 60 00 02 ZZ YY XX 08 82 01 80 00 02 ZZ YY XX 08 82 01 A0 00 02 ZZ YY XX 08 82 01 C0 00 02 ZZ YY XX 08 82 01 E0 00 0E DD 7C 2D 08 08
At offset XX YY ZZ:
E9 27 A7 27 CC 49 52 08 9C C6 2E 08 00 00 00 00 00 3A 59 08 79 68 10 08

Rock Smash:
Spoiler:

00 4A 27 00 97 27 00 9F 27 0A 03 0C 0C 08 04 01 0E FC 6B 2D 08 19 7B 00 05 0B 03 0D 08

By the way, is Spherical Ice busy or something? Because no one seems to be updating the OP with new animations/effects/sprites.
Reply With Quote
  #220    
Old 1 Week Ago (03:10 AM).
Spherical Ice's Avatar
Spherical Ice
 
Join Date: Nov 2007
Location: UK
Send a message via Skype™ to Spherical Ice
Quote originally posted by Artemis64:
By the way, is Spherical Ice busy or something? Because no one seems to be updating the OP with new animations/effects/sprites.
Sorry about that, I just kept putting it off haha. I've updated everything, but please PM / VM me if I forgot something!
__________________
Reply With Quote
  #221    
Old 1 Week Ago (05:08 AM).
Artemis64
 
Join Date: Mar 2014
Gender: Male
It's alright, all of us procrastinate to some extent. By the way since you have added a updated animations section, I might as well share my updated Mud Shot animation:
Spoiler:


00 13 28 0A 03 28 01 1C 90 00 C0 07 07 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 03 21 66 11 08 0A 05 04 00 01 00 00 00 09 00 B0 01 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 03 D1 52 0D 08 02 05 01 00 02 00 00 00 15 00 01 00 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 04 02 02 ZZ YY XX 08 82 05 00 00 00 00 00 00 00 00 14 00 05 03 21 66 11 08 0A 05 04 00 01 00 09 00 00 00 B0 01 05 0B 03 08
At offset XX YY ZZ:
13 28 13 28 D4 49 52 08 B4 6E 59 08 00 00 00 00 EC 6E 59 08 25 32 11 08
You'll also need to insert the custom sprite for it at slot 13 28 in the attack particles table and change the size (the bytes after the image pointer, before the index) to 00 0A.

Reply With Quote
  #222    
Old 2 Days Ago (09:03 PM). Edited 2 Days Ago by Chaos Rush.
Chaos Rush's Avatar
Chaos Rush
im sexy and i know it
 
Join Date: May 2007
Location: Taylor Swift
Gender: Male
Nature: Adamant
Payback (FireRed):
Spoiler:

Insert this ASM somewhere:
Code:
.text
.align 2
.thumb
.thumb_func
.global test

main:
push {lr}
ldr r0, .TargetBank
ldrb r0, [r0, #0x0]
ldr r1, .BattleStruct
mov r2, #0x58
mul r0, r2
add r5, r0, r1

OrderCheck:
ldr r0, .TargetBank
ldr r1, .UserBank
ldrb r4, [r0, #0x0] /*put target bank into R4*/
ldrb r5, [r1, #0x0] /*put user bank into R5*/
ldr r1, .TurnOrder /*put turn order offset into R1*/

Loop:
ldrb r2, [r1, #0x0] 	/*put attacking PKMN into r2*/
cmp r2, r4 		/*is the attacking PKMN the target?*/
beq SuperAttack 	/*if so, prepare double damage*/
cmp r2, r5 		/*is the attacking PKMN the user?*/
beq Attack		/*if so, attack*/
add r1, #0x1		/*move on to next attacking PKMN*/
b Loop

SuperAttack:
mov r1, #0x2
ldr r0, .DamageMultiplier
strb r1, [r0, #0x0]

Attack:
End:
pop {r0}
bx r0

.align 2

.UserBank: .word 0x02023D6B
.TargetBank: .word 0x02023D6C
.BattleStruct: .word 0x02023BE4
.BasePower: .word 0x02023F50
.TurnOrder: .word 0x02023bde
.DamageMultiplier: .word 0x02023FD2
Use this battle script:
Code:
#org @main
callasm 0x8(offset that you inserted the ASM + 1)
goto 0x81D6900
Payback animation (it's just Counter with the Dark BG):
Code:
14 00 17 00 97 27 00 9F 27 0A 03 0C 0C 08 03 7D 90 09 08 02 05 00 00 12 00 06 00 01 00 04 00 19 73 00 C0 05 02 9C 4E 3D 08 02 05 00 00 14 00 00 00 00 00 04 00 04 04 02 08 7C 3E 08 02 04 F1 FF 12 00 01 00 00 00 19 74 00 3F 04 01 03 F9 89 09 08 02 05 01 00 05 00 00 00 19 00 01 00 02 10 67 3E 08 03 05 F1 FF 12 00 08 00 01 00 00 00 04 03 02 08 7C 3E 08 02 04 00 00 FC FF 01 00 00 00 19 74 00 3F 04 01 02 10 67 3E 08 03 05 00 00 FC FF 08 00 01 00 00 00 04 03 02 08 7C 3E 08 02 04 0F 00 09 00 01 00 00 00 19 74 00 3F 04 01 02 10 67 3E 08 03 05 0F 00 09 00 08 00 01 00 00 00 04 05 02 84 4E 3D 08 02 03 00 00 00 00 05 00 05 0B 03 0D 0E C7 59 1D 08 08
Credit to DoesntKnowHowToPlay because I modified his Sucker Punch ASM for this.


Trump Card (FireRed):
Spoiler:
First, insert this ASM somewhere:
Code:
.text
.align 2
.thumb
.thumb_func
.global test

main:
push {lr}
ldr r0, .UserBank 	/*get user slot*/
ldrb r0, [r0, #0x0]
ldr r1, .BattleData	/*load battle struct*/
mov r2, #0x58		/*separate into 4*/
mul r0, r2		/*get beginning of user stats*/
add r5, r0, r1		/*R5 should now have user's offset*/

GetWhichSlot:
mov r0, #0xBC		/*make sure this is your Trump Card move ID divided by 2*/
lsl r0, r0, #0x1	/*r0 should now have Trump Card ID*/
add r5, #0xC		/*check slot 1 move ID*/
ldrh r1, [r5]
cmp r0, r1
beq ver1
add r5, #0x2		/*check slot 2 move ID*/
ldrh r1, [r5]
cmp r0, r1
beq ver2
add r5, #0x2		/*check slot 3 move ID*/
ldrh r1, [r5]
cmp r0, r1
beq ver3
add r5, #0x2		/*check slot 4 move ID*/
ldrh r1, [r5]
cmp r0, r1
beq ver4

ver1:
add r5, #0x18
ldrb r0, [r5]		/*r0 should now have how much PP is left*/
b getPP

ver2:
add r5, #0x17
ldrb r0, [r5]		/*r0 should now have how much PP is left*/
b getPP

ver3:
add r5, #0x16
ldrb r0, [r5]		/*r0 should now have how much PP is left*/
b getPP

ver4:
add r5, #0x15
ldrb r0, [r5]		/*r0 should now have how much PP is left*/
b getPP

getPP:
cmp r0, #0x4
bgt FourOrMore
cmp r0, #0x4
beq FourOrMore
cmp r0, #0x3
beq Three
cmp r0, #0x2
beq Two
cmp r0, #0x1
beq One
cmp r0, #0x0
beq Zero

FourOrMore:
mov r0, #0x28
b StorePower

Three:
mov r0, #0x32
b StorePower

Two:
mov r0, #0x3C
b StorePower

One:
mov r0, #0x50
b StorePower

Zero:
mov r0, #0xC8
b StorePower

StorePower:
ldr r1, .BasePower
strb r0, [r1]

End:
pop {r0}
bx r0

.align 2
.BattleData:		.word 0x02023BE4
.UserBank:		.word 0x02023D6B
.BasePower:		.word 0x02023F50
If your Trump Card move ID isn't 0x178, then change the bolded line to your Trump Card move ID divided by 2.

The Battle Script ID has to be 17 (Swift/Feint Attack/attacks that never miss), otherwise it won't work properly. Replace the script with this:
Code:
#org @main
jumpifhalfword 0x0 0x2023D4A 0x178 @new
jumpifhalfword 0x1 0x2023D4A 0x39 0x81D6926
jumpifspecialstatusflag 0x0 0x40000 0x1 0x81D6926
orword 0x2023DD0 0x40000
setbyte 0x2023FD2 0x2

#org @new
attackcanceler
accuracycheck 0x81D695E 0x0
attackstring
ppreduce
callasm 0x8(offset of Trump Card ASM routine +1)
calculatedamage
attackanimation
waitanimation
missmessage
cmd5c 0x0
waitstate
graphicalhpupdate 0x0
datahpupdate 0x0
critmessage
waitmessage 0x40
resultmessage
waitmessage 0x40
seteffectwithchancetarget
faintpokemon 0x0 0x0 0x0
setbyte 0x2023FD8 0x0
cmd49 0x0 0x0
end


EDIT: Also here's my really lame Trump Card particle, for Trump Card I just used Swift's animation but with this particle instead:
Attached Images
File Type: png TrumpCard.png‎ (311 Bytes, 16 views) (Save to Dropbox)
__________________
Reply With Quote
Reply
Quick Reply

Sponsored Links
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are UTC -8. The time now is 01:12 PM.