The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > ROM Hacking > Research & Development
Sign Up Rules/FAQ Live Battle Blogs Mark Forums Read

Notices

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.


Advertise here

Reply
Click here to go to the first staff post in this thread.  
Thread Tools
  #126    
Old 4 Weeks Ago, 12:13 AM
mamamama
 
Join Date: Feb 2014

Advertise here
Quote:
Originally Posted by MrDollSteak View Post
Awesome! Thanks Tlachtli. I'm using 02023D60 in this case, as theres nothing specific that it does.

Also I've edited my original post, since I've added Shell Smash to Dragon Dance's BS. As mamamama rightly said +Atk and +Speed is closer to Shell Smash's effect than +Spatk could have been. Anyway here are the new moves! All for Fire Red.[/CODE][/SPOILER]
I noticed that you use playtstatsanimation 0x0 0xA 0x0 on moves such as Quiver Dance, Coil and Shell Smash. Is there a reason it's always that combination?

I was under the impression you had to add the stats you are raising/lowering together so that the correct colour changes when just one stats is raising.

For example. Dragon Dance has Speed (0x8) and Attack (0x2) so if you add them together you get 0xA and thus one colour is correctly used if the other is already at +6. This would place Coil at 0x46 etc.
Reply With Quote
  #127    
Old 4 Weeks Ago, 12:18 AM
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
Quote:
Originally Posted by mamamama View Post
I noticed that you use playtstatsanimation 0x0 0xA 0x0 on moves such as Quiver Dance, Coil and Shell Smash. Is there a reason it's always that combination?

I was under the impression you had to add the stats you are raising/lowering together so that the correct colour changes when just one stats is raising.

For example. Dragon Dance has Speed (0x8) and Attack (0x2) so if you add them together you get 0xA and thus one colour is correctly used if the other is already at +6. This would place Coil at 0x46 etc.
Oh that may be the case to be honest I just assumed it was 0xA for every multi-stat raising move. Let me look at Calm Mind to see if it also uses 0xA.

EDIT: I've gone through and fixed all of them. Thanks mamamama. Also I've tested them all in my rombase and they all work perfectly now.
EDIT2: My BSP has been compiling incorrectly in areas, for some reason the B_>= command isn't compiling to 0x3 as it should but to 0x0. I'm just going to change some move effects to show this.
__________________

Last edited by MrDollSteak; 4 Weeks Ago at 02:05 AM. Reason: Phrasing
Reply With Quote
  #128    
Old 4 Weeks Ago, 02:36 AM
mamamama
 
Join Date: Feb 2014
Quote:
Originally Posted by MrDollSteak View Post
Oh that may be the case to be honest I just assumed it was 0xA for every multi-stat raising move. Let me look at Calm Mind to see if it also uses 0xA.
If you use a Pokemon with Dragon Dance + Shell Smash against a Zigzagoon with only Fake Tears, start with 2 Dragon Dances, and then go for a Shell Smash you will notice that neither of the defenses will lower when the regular defense should be going down.

I made this script a few weeks ago and cleaned it up a bit using yours as template. This is Quiver Dance and Shell Smash combined with Dragon Dance. I use Dragon Dance because I want the AI to recognize to use it when it wants to outspeed an opponent that is faster. I don't think the AI will act much differently if you choose to combine QDance with Calm Mind (My QDance is pretty much identical to yours).

I've tested this with all kinds of combinations and it should work. Note that this is for Emerald but should be easy to translate using the offsets in Mr. Ds's code. I made this based on the original Dragon Dance and Curse scripts combined.

EDIT: I noticed that my old effect did not pierce through White Smoke so I'm updating it with a fix. I believe yours has the same problem MrDollSteak. You can just change 0x1 TRUE @XX to 0x81 TRUE @XX and playstatanimation to 0x1 0x24 0x9 and it will work properly.

Credit to DoesntKnowHowToPlay's Hammer Arm Script for this fix.
Spoiler:
Code:
#dynamic 0x[Offset]
#freespacebyte 0xFF

#include moves.bsh

#org @start
jumpifhalfword 0x0 0x20241EA 0x[Attack# in Hex] @QDance
jumpifhalfword 0x0 0x20241EA 0x[Attack# in Hex] @ShellSmash
goto 0x82DA731

#org @QDance
attackcanceler
attackstring
ppreduce
jumpifstat 0x1 0x3 0x5 0xC @SpAtt
jumpifstat 0x1 0x3 0x4 0xC @SpAtt
jumpifstat 0x1 0x0 0x3 0xC 0x82DA71D

#org @SpAtt
attackanimation
waitanimation
setbyte 0x202448F 0x0
playstatchangeanimation 0x0 0x38 0x0
setbyte 0x202448E 0x14
statbuffchange 0x41 TRUE @SpDef
jumpifbyte 0x0 0x2024337 0x2 @SpDef
printfromtable 0x85CC89C
waitmessage 0x40

#org @SpDef
setbyte 0x202448E 0x15
statbuffchange 0x41 TRUE @Speed
jumpifbyte 0x0 0x2024337 0x2 @Speed
printfromtable 0x85CC89C
waitmessage 0x40

#org @Speed
setbyte 0x202448E 0x13
statbuffchange 0x41 TRUE 0x82DA790
jumpifbyte 0x0 0x2024337 0x2 0x82DA790
printfromtable 0x85CC89C
waitmessage 0x40
goto 0x82D8A4E

#org @ShellSmash
attackcanceler
attackstring
ppreduce
jumpifstat 0x1 0x2 0x2 0x0 @DropDef
jumpifstat 0x1 0x2 0x5 0x0 @DropDef
jumpifstat 0x1 0x1 0x1 0xC @DropDef
jumpifstat 0x1 0x1 0x4 0xC @DropDef
jumpifstat 0x1 0x0 0x3 0xC 0x82DA71D

#org @DropDef
attackanimation
waitanimation
playstatchangeanimation 0x1 0x24 0x9
setbyte 0x202448E 0x92
statbuffchange 0x81 TRUE @DropSpDef
jumpifbyte 0x0 0x2024337 0x2 @DropSpDef
printfromtable 0x85CC8A8
waitmessage 0x40

#org @DropSpDef
setbyte 0x202448E 0x95
statbuffchange 0x81 TRUE @2Att
jumpifbyte 0x0 0x2024337 0x2 @2Att
printfromtable 0x85CC8A8
waitmessage 0x40

#org @2Att
setbyte 0x202448F 0x0
playstatchangeanimation 0x0 0x1A 0x0
setbyte 0x202448E 0x21
statbuffchange 0x41 TRUE @2SpAtt
jumpifbyte 0x0 0x2024337 0x2 @2SpAtt
printfromtable 0x85CC89C
waitmessage 0x40

#org @2SpAtt
setbyte 0x202448E 0x24
statbuffchange 0x41 TRUE @2Speed
jumpifbyte 0x0 0x2024337 0x2 @2Speed
printfromtable 0x85CC89C
waitmessage 0x40

#org @2Speed
setbyte 0x202448E 0x23
statbuffchange 0x41 TRUE 0x82DA790
jumpifbyte 0x0 0x2024337 0x2 0x82DA790
printfromtable 0x85CC89C
waitmessage 0x40
goto 0x82D8A4E

Last edited by mamamama; 2 Weeks Ago at 04:11 PM.
Reply With Quote
  #129    
Old 4 Weeks Ago, 02:47 AM
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
Quote:
Originally Posted by mamamama View Post
If you use a Pokemon with Dragon Dance + Shell Smash against a Zigzagoon with only Fake Tears, start with 2 Dragon Dances, and then go for a Shell Smash you will notice that neither of the defenses will lower when the regular defense should be going down.
The problem with that has been fixed, it was because BSP wasn't compiling the 0x3 byte in the jump properly.

Also here is an animation for Shift Gear using a custom particle.

Code:
00 3D 28 0A 03 28 01 0C 0C 08 19 B4 00 3F 02 XX XX XX 08 02 05 D6 FF E7 FF 00 00 00 00 0F 00 04 0C 02 YY YY YY 08 02 07 07 00 05 00 01 00 00 00 0A 00 00 00 00 00 19 74 00 3F 05 0B 03 0D 08 FF
At offset XXXXXX put
XX 28 XX 28 38 CA 3A 08 F0 1C 23 08 00 00 00 00 24 7A 3E 08 55 8C 0B 08

At offset YYYYYY put
XX 28 XX 28 58 CB 3A 08 F0 1C 23 08 00 00 00 00 F8 7B 3E 08 61 A5 0B 08

Then insert the attached particle particle wherever you want and change the index from XX 28 to your value in the particle table.
Attached Images
File Type: png Shift Gear.png‎ (292 Bytes, 334 views) (Save to Dropbox)
__________________

Last edited by MrDollSteak; 4 Weeks Ago at 03:38 AM.
Reply With Quote
  #130    
Old 4 Weeks Ago, 03:43 AM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
The updated Hi Jump Kick for Fire Red if anyone didn't notice.
http://www.pokecommunity.com/showpos...17&postcount=2
Reply With Quote
  #131    
Old 4 Weeks Ago, 02:40 AM
BugMania's Avatar
BugMania
The Bug Master
 
Join Date: Jun 2013
Gender: Male
Nature: Quiet
Quote:
Originally Posted by MrDollSteak View Post
Awesome! Thanks Tlachtli. I'm using 02023D60 in this case, as theres nothing specific that it does.

Also I've edited my original post, since I've added Shell Smash to Dragon Dance's BS. As mamamama rightly said +Atk and +Speed is closer to Shell Smash's effect than +Spatk could have been. Anyway here are the new moves! All for Fire Red.

Flower Shield

Spoiler:
Replace effect 11 with this battle script.
Flower Shield doesn't yet have an index in my rombase so just give it one.
Credits to Tlachtli for his original Emerald battle script.
Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @Effect11
setbyte 0x2023FDE 0x12
jumpifhalfword B_= 0x2023D4A 0x??? @FlowerShield
goto 0x1D6B9E

#org @FlowerShield
setbyte 0x02023D60 0x0
attackcanceler
attackstring
ppreduce
cmd25
jumpiftype 0x1 0xC @SelfGrass
goto @Call

#org @SelfGrass
jumpifsecondarystatus 0x1 0x1000000 @NextTarget
jumpifstat 0x1 B_>= 0x2 0xC @NextTarget
jumpifbyte B_= 0x02023D60 0x1 @SelfNoAnimation
attackanimation
waitanimation
setbyte 0x02023D60 0x1
goto @SelfNoAnimation

#org @SelfNoAnimation
cmd47
playstatchangeanimation 0x1 0x4 0x0
statbuffchange 0x80 true @NextTarget
jumpifbyte B_>= 0x2023E87  0x2 @NextTarget
printfromtable 0x83FE57C
waitmessage 0x40

#org @NextTarget
cmd25

#org @Call
jumpifarrayequal 0x2023D6B 0x2023D6C 0x1 @NextTarget
call @TargetBuff
setbyte 0x2023FD8 0x0
cmd49 0x2 0x10
jumpwhiletargetvalid @NextTarget
jumpifbyte B_= 0x02023D60 0x0 @NoBuffs
end

#org @TargetBuff
jumpiftype 0x0 0xC @Grass
goto @Return

#org @Grass
jumpifsecondarystatus 0x0 0x1000000 @Return
jumpifstat 0x0 B_>= 0x2 0xC @Return
jumpifbyte B_= 0x02023D60 0x1 @NoAnimation
attackanimation
waitanimation
setbyte 0x02023D60 0x1
goto @NoAnimation

#org @NoAnimation
cmd47
playstatchangeanimation 0x0 0x4 0x0
statbuffchange 0x0 false @Return
jumpifbyte B_>= 0x2023E87 0x2 @Return
printfromtable 0x83FE57C
waitmessage 0x40

#org @Return
return

#org @NoBuffs
pause 0x20
orbyte 0x2023DCC 0x20
resultmessage
waitmessage 0x40
end


Work Up and Growth and Rototiller

Spoiler:
Replace effect 13 with this battle script.
Growth is updated to its Gen V effect.
Work Up has an index of 19E in my rombase, and Rototiller is 0x1DF so just make note of that.
Rototiller works in the same way that Flower Shield does, so thanks to Tlachtli for the original notes on how to do this.
Code:
#include abilities.bsh
#dynamic 0x800000
#freespacebyte 0xFF

#org @pickmove
jumpifhalfword 0x0 0x2023D4A 0x4A @growth
jumpifhalfword 0x0 0x2023D4A 0x19E @workup
jumpifhalfword 0x0 0x2023D4A 0x1DF @rototiller
goto 0x1D6B8D

#org @growth
jumpifabilitypresent ABILITY_CLOUDNINE @workup
jumpifabilitypresent ABILITY_AIRLOCK @workup
jumpifhalfword B_& 0x2023F1C 0x60 @sunlight

#org @sunlight
attackcanceler
attackstring
ppreduce
jumpifstat BANK_USER 0x3 0x1 0xC @attack2
jumpifstat BANK_USER B_= 0x4 0xC 0x81D85E7

#org @attack2
attackanimation
waitanimation
setbyte 0x2023FDF 0x0
playstatchangeanimation 0x0 0x12 0x0
setbyte 0x2023FDE 0x21
statbuffchange 0x1 true @spatk2
jumpifbyte 0x0 0x2023E87 0x2 @spatk2
printfromtable 0x83FE57C
waitmessage 0x40

#org @spatk2
setbyte 0x2023FDE 0x24
statbuffchange 0x1 true 0x81D85E2
jumpifbyte 0x0 0x2023E87 0x2 0x81D85E2
printfromtable 0x83FE57C
waitmessage 0x40
goto 0x1D694E

#org @workup
attackcanceler
attackstring
ppreduce
jumpifstat BANK_USER 0x3 0x1 0xC @attack
jumpifstat BANK_USER B_= 0x4 0xC 0x81D85E7

#org @attack
attackanimation
waitanimation
setbyte 0x2023FDF 0x0
playstatchangeanimation 0x0 0x12 0x0
setbyte 0x2023FDE 0x11
statbuffchange 0x1 true @spatk
jumpifbyte 0x0 0x2023E87 0x2 @spatk
printfromtable 0x83FE57C
waitmessage 0x40

#org @spatk
setbyte 0x2023FDE 0x14
statbuffchange 0x1 true 0x81D85E2
jumpifbyte 0x0 0x2023E87 0x2 0x81D85E2
printfromtable 0x83FE57C
waitmessage 0x40
goto 0x1D694E

#org @rototiller
setbyte 0x2023D60 0x0
attackcanceler
attackstring
ppreduce
cmd25
jumpiftype 0x1 0xC @selfgrass
goto @call

#org @selfgrass
jumpifsecondarystatus 0x1 0x1000000 @next
jumpifstat 0x1 B_>= 0x1 0xC @next
jumpifstat 0x1 B_>= 0x4 0xC @next
jumpifbyte B_= 0x2023D60 0x1 @selfnoanimation
attackanimation
waitanimation
setbyte 0x2023D60 0x1

#org @selfnoanimation
cmd47
playstatchangeanimation 0x1 0x12 0x0
setbyte 0x2023FDE 0x11
statbuffchange 0x80 true @selfnoanimation2
jumpifbyte B_>= 0x2023E87 0x2 @selfnoanimation2
printfromtable 0x83FE57C
waitmessage 0x40

#org @selfnoanimation2
setbyte 0x2023FDE 0x14
statbuffchange 0x80 true @next
jumpifbyte B_>= 0x2023E87 0x2 @next
printfromtable 0x83FE57C
waitmessage 0x40

#org @next
cmd25

#org @call
jumpifarrayequal 0x2023D6B 0x2023D6C 0x1 @next
call @target
setbyte 0x2023FD8 0x0
cmd49 0x2 0x10
jumpwhiletargetvalid @next
jumpifbyte B_= 0x2023D60 0x0 @nobuffs
end

#org @target
jumpiftype 0x0 0xC @grass
goto @return

#org @grass
jumpifsecondarystatus 0x0 0x1000000 @return
jumpifstat 0x0 B_>= 0x1 0xC @return
jumpifstat 0x0 B_>= 0x4 0xC @return
jumpifbyte B_= 0x02023D60 0x1 @noanimation
attackanimation
waitanimation
setbyte 0x02023D60 0x1

#org @noanimation
cmd47
playstatchangeanimation 0x0 0x12 0x0
setbyte 0x2023FDE 0x11
statbuffchange 0x0 false @noanimation2
jumpifbyte B_>= 0x2023E87 0x2 @noanimation2
printfromtable 0x83FE57C
waitmessage 0x40

#org @noanimation2
setbyte 0x2023FDE 0x14
statbuffchange 0x0 false @return
jumpifbyte B_>= 0x2023E87 0x2 @return
printfromtable 0x83FE57C
waitmessage 0x40

#org @return
return

#org @nobuffs
pause 0x20
orbyte 0x2023DCC 0x20
resultmessage
waitmessage 0x40
end


Cotton Guard

Spoiler:
Replace effect 51 with this battle script.
You'll need Jambo's battle message hack and set word command.
0x1B7 is the index for Cotton Guard so just change that.
It successfully raises Defense by 3 stages and displays the message 'drastically rose' not Sharply rose.
Though if you are already at +4 or +5 it will jump to the equivalent +2 or +1 battle script.
Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @pickmove
jumpifhalfword 0x0 0x2023D4A 0x1B7 @cottonguard
goto 0x1D7103

#org @cottonguard
jumpifstat BANK_USER B_>= 0x2 0xA 0x1D7103
jumpifstat BANK_USER B_>= 0x2 0xB 0x1D6B82
attackcanceler
attackstring
ppreduce
setbyte 0x2023FDE 0x22
statbuffchange 0x1 true 0x81D6BCC
jumpifbyte 0x0 0x2023E87 0x2 0x81D6BC4

#org @singleboost
attackanimation
waitanimation
cmd47
playanimation BANK_USER 0x1 0x2023FD4
setbyte 0x2023FDE 0x12
statbuffchange 0x1 true 0x81D6BCC
jumpifbyte 0x0 0x2023E87 0x2 0x81D6BC4

#org @end
setword 0x203C020 0x8CCCCCC
printstring 0x184
waitmessage DELAY_1SECOND
goto 0x81D694E
At CCCCCC place this hex:
FD 0F B4 E7 00 BE D9 DA D9 E2 E7 D9 FE D8 E6 D5 E7 E8 DD D7 D5 E0 E0 ED 00 E6 E3 E7 D9 AB


Tail Glow

Spoiler:
Replace effect 53 with this battle script.
You'll need Jambo's battle message hack and set word command.
It updates Tail Glow to its Gen V+ usage.
It successfully raises Defense by 3 stages and displays the message 'drastically rose' not Sharply rose.
Though if you are already at +4 or +5 it will jump to the equivalent +2 or +1 battle script.
Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @pickmove
jumpifhalfword 0x0 0x2023D4A 0x126 @tailglow
goto 0x1D7119

#org @tailglow
jumpifstat BANK_USER B_>= 0x4 0xA 0x1D7119
jumpifstat BANK_USER B_>= 0x4 0xB 0x1D6B8D
attackcanceler
attackstring
ppreduce
setbyte 0x2023FDE 0x24
statbuffchange 0x1 true 0x81D6BCC
jumpifbyte 0x0 0x2023E87 0x2 0x81D6BC4

#org @singleboost
attackanimation
waitanimation
cmd47
playanimation BANK_USER 0x1 0x2023FD4
setbyte 0x2023FDE 0x14
statbuffchange 0x1 true 0x81D6BCC
jumpifbyte 0x0 0x2023E87 0x2 0x81D6BC4

#org @end
setword 0x203C020 0x8DDDDDD
printstring 0x184
waitmessage DELAY_1SECOND
goto 0x81D694E
At DDDDDD place this hex:
FD 0F B4 E7 00 CD E4 AD 00 BB E8 DF FE D8 E6 D5 E7 E8 DD D7 D5 E0 E0 ED 00 E6 E3 E7 D9 AB


Charge

Spoiler:
Replace effect 174 with this battle script.
It's Charge but now with a permanent Sp. Def boost that's added after the charge effect to match the message style of Gen V.
Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @charge
attackcanceler
attackstring
ppreduce
setcharge
attackanimation
waitanimation
printstring 0xA5
waitmessage DELAY_1SECOND

#org @spdefboost
setbyte 0x2023FDE 0x15
statbuffchange 0x1 true 0x81D6BCC
jumpifbyte B_!= 0x2023E87 0x2 0x81D6BCC
goto 0x81D6BBC
Thank you very much! I still do not have time to test, but if you really found the hex for new messages, I'm relieved! My routine had problems when there were battles with link...

Glad that you are now working with asm and hex!

When I have time, I'll show you how I make an effect run in a end of turn, without using pauses! Also, things like the "toxic spikes!"
__________________
Even the smallest of beings can achieve the greatest of obstacles!
Click in the spoiler, if you dare!
Spoiler:


L
et's dream bigger than our bodies can endure!
G
et to the extreme!

See my works here

Reply With Quote
  #132    
Old 4 Weeks Ago, 08:37 AM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
Clubbed Sky Attack (also updated it's message), Freeze Shock (updated it's effect so that electric mons can't be paralysed by it), Ice Burn together due to similar effect. This also requires the battle string loader ASM:

Replace Sky Attack's effect with this one:
Code:
#dynamic 0x[YourOffset]
#freespacebyte 0xFF

#org @moveselect
jumpifhalfword 0x0 0x2023D4A 0xXX @freejshock //replace XX with ID of freeze shock
jumpifhalfword 0x0 0x2023D4A 0xYY @iceburn //replace XX with ID of ice burn
goto @skyattack


#org @skyattack
jumpifsecondarystatus 0x1 0x1000 0x81D6F29
jumpifword 0x4 0x2023DD0 0x200 0x81D6F29
setbyte 0x2023FD3 0x3
call @firstturnsk
goto 0x81D694E

#org @firstturnsk
attackcanceler
attackstring
waitmessage 0x40
ppreduce
attackanimation
waitanimation
orword 0x2023DD0 0x8000000
setbyte 0x2023E85 0x4C
seteffecttarget
copyarray 0x2023E87 0x2023FD3 0x1
setword 0x203C020 0x8A20000
printstring 0x184
waitmessage 0x40
return


#org @freejshock
jumpifsecondarystatus 0x1 0x1000 @executefs
jumpifword 0x4 0x2023DD0 0x200 @executefs
setbyte 0x2023FD3 0x3
call @firstturnfs
goto 0x81D694E

#org @executefs
attackcanceler
setbyte 0x2023E85 0xC
setbyte 0x2023FDC 0x1
clearstatus 0x1
orword 0x2023DD0 0x800
jumpiftype 0x0 0xD 0x81D6927
setbyte 0x2023E85 0x5
goto 0x81D6927

#org @firstturnfs
attackcanceler
attackstring
waitmessage 0x40
ppreduce
attackanimation
waitanimation
orword 0x2023DD0 0x8000000
setbyte 0x2023E85 0x4C
seteffecttarget
copyarray 0x2023E87 0x2023FD3 0x1
setword 0x203C020 0x8A00000
printstring 0x184
waitmessage 0x40
return


#org @iceburn
jumpifsecondarystatus 0x1 0x1000 @executeib
jumpifword 0x4 0x2023DD0 0x200 @executeib
setbyte 0x2023FD3 0x3
call @firstturnib
goto 0x81D694E

#org @executeib
attackcanceler
setbyte 0x2023E85 0xC
setbyte 0x2023FDC 0x1
clearstatus 0x1
orword 0x2023DD0 0x800
setbyte 0x2023E85 0x3
goto 0x81D6927

#org @firstturnib
attackcanceler
attackstring
waitmessage 0x40
ppreduce
attackanimation
waitanimation
orword 0x2023DD0 0x8000000
setbyte 0x2023E85 0x4C
seteffecttarget
copyarray 0x2023E87 0x2023FD3 0x1
setword 0x203C020 0x8A10000
printstring 0x184
waitmessage 0x40
return
String at A20000 (Sky Attack's)
Code:
FD 0F B4 E7 00 D6 D9 D7 D5 E1 D9 00 D7 E0 E3 D5 DF D9 D8 00 DD E2 00 D5 00 DC D5 E6 E7 DC 00 E0 DD DB DC E8 AB FF
String at A00000 (Freeze Shock's)
Code:
FD 0F B4 E7 00 D6 D9 D7 D5 E1 D9 00 D7 E0 E3 D5 DF D9 D8 00 DD E2 00 D5 00 DA E6 D9 D9 EE DD E2 DB 00 E0 DD DB DC E8 AB FF
String at A10000 (Ice Burn's)
Code:
FD 0F B4 E7 00 D6 D9 D7 D5 E1 D9 00 D7 E0 E3 D5 DF D9 D8 00 DD E2 00 D5 00 DA E6 D9 D9 EE DD E2 DB 00 D5 DD E6 AB FF
Reply With Quote
  #133    
Old 3 Weeks Ago, 03:02 AM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
Heavy Slam for Fire Red. The script is simple as for Doesnt's ASMs. Use the callasm command just after the pp reducer and before damagecalculator in the script:

The ASM:
Code:
.text
.align 2
.thumb
.thumb_func
.global heavyslam

main:
push {lr}
ldr r0, userBank
ldrb r0, [r0]
ldr r1, battleData
mov r2, #0x58
mul r0, r2
add r3, r0, r1
ldr r0, targetBank
ldrb r0, [r0]
mul r0, r2
add r4, r0, r1
ldrb r5, [r3, #0x0]
ldrb r6, [r4, #0x0]
ldr r1, dexData
mov r2, #0x24
mul r5, r2
add r0, r1, r5
ldrh r5, [r0, #0xE]
mul r6, r2
add r0, r1, r6
ldrh r6, [r0, #0xE]

label1:
ldr r1, floatstoneindex
mov r7, r3
add r7, #0x20
ldrb r7, [r7]
cmp r7, #0xXX
bne label2
lsr r5, #0x1

label2:
cmp r7, #0xYY
bne label3
lsl r5, #0x1

label3:
ldrh r7, [r3, #0x2e]
cmp r7, r1
bne label4
lsr r5, #0x1


label4:
mov r7, r4
add r7, #0x20
ldrb r7, [r7]
cmp r7, #0xXX
bne label5
lsr r6, #0x1

label5:
cmp r7, #0xYY
bne label6
lsl r6, #0x1

label6:
ldrh r7, [r4, #0x2e]
cmp r7, r1
bne label7
lsr r5, #0x1

label7:
mov r2, #0x5
mul r2, r6
cmp r5, r2
bgt set120
sub r2, r6
cmp r5, r2
bgt set100
sub r2, r6
cmp r5, r2
bgt set80
sub r2, r6
cmp r5, r2
bgt set60
mov r1, #0x28
b end

set60:
mov r1, #0x3C
b end

set80:
mov r1, #0x50
b end

set100:
mov r1, #0x64
b end

set120:
mov r1, #0x78

end:
ldr r2, basePower
strh r1, [r2, #0x0]
pop {r0}
bx r0

.align 2
floatstoneindex: .hword 0xZZZZ
targetBank: .word 0x02023D6C
userBank: .word 0x02023D6B
battleData: .word 0x02023BE4
basePower: .word 0x02023F50
dexData: .word 0x0844E850
NOTES
1. The bold section of the code is meant to accommodate the weight changes due to Light Metal, Heavy Metal abilities and the item Float Stone because the Weight is directly loaded from the Dex Data in the ROM (even lowkick does).

2. If your ROM don't have anyone of these things remove the bolded section. Otherwise, replace XX with the index of Light Metal, replace YY with the index of Heavy Metal, and replace ZZZZ with the index of Float Stone.

3. If you have expanded the no of pokemons then the value of dexData also needs to be changed to the new location.

4. If someone wants to port it to Emerald, in addition to changing the value of offsets also change the mov r2, #0x24 to mov r2, #0x20 after the ldr r1, dexData, this because in every GBA Rom except Emerald the dex entry for each poke takes 36 bytes, whereas in Emerald it takes 32 bytes.

Last edited by KDS; 3 Weeks Ago at 07:33 AM.
Reply With Quote
  #134    
Old 3 Weeks Ago, 01:16 AM
Spherical Ice's Avatar
Spherical Ice
Community Supporter
 
Join Date: Nov 2007
Location: UK
Send a message via Skype™ to Spherical Ice
Petal Blizzard animation for FireRed:


Code:
00 4F 27
00 97 27
00 AF 27

0A 03 28 01

19 E4 00

3F

02
20 2C 3E 08
82 05 78
00 46
00 05
00 46
00 1E
00 04
01

02
20 2C 3E 08
82 05 73
00 37
00 06
00 3C
00 19
00 04
01

02
20 2C 3E 08
82 05 73
00 3C
00 07
00 3C
00 1E
00

02
AA AA AA 08
82 05 73
00 37
00 0A
00 3C
00 1E
00 04
03

02
AA AA AA 08
82 05 64
00 32
00 04
00 32
00 1A
00 04
01

02
AA AA AA 08
82 05 69
00 19
00 08
00 3C
00 14
00 04
01

02
AA AA AA 08
82 05 73
00 28
00 0A
00 30
00 1E
00 04
03

02
BB BB BB 08
82 05 78
00 1E
00 06
00 2D
00 19
00

02
20 2C 3E 08
82 05 73
00 23
00 0A
00 3C
00 1E
00 04
03

02
BB BB BB 08
82 05 69
00 14
00 08
00 28
00 00
00 04
03

02
20 2C 3E 08
82 05 14
00 FF
00 0F
00 20
00 00
00

02
20 2C 3E 08
82 05 6E
00 0A
00 08
00 20
00 14
00

05

02
08 7C 3E 08
83 04 E0
FF F0
FF 01
00 03
00

19 84 00

3F

03
D1 8C 09 08
02 05
01 00
03 00
00 00
0C 00
01 00

03
D1 8C 09 08
02 05
03 00
03 00
00 00
0C 00
01 00

04 04

02
50 7C 3E 08
83 02 01
00 03
00

19 84 00

3F 04 04

02
50 7C 3E 08
83 02
01 00
03 00

19 84 00

3F 04 04

02
08 7C 3E 08
83 04
20 00
14 00
01 00
03 00

19 84 00

3F 05 0B 03 0D 08
At AAAAAA:
Code:
AF 27
AF 27
CC CC CC 08
DD DD DD 08
00 00 00 00
FC 1C 23 08
11 2D 0A 08

At CCCCCC:
00 00 00 40 00 08 00 00 00

At DDDDDD:
EE EE EE 08

At EEEEEE:
00 00 00 00 00 00
At BBBBBB:
Code:
AF 27
AF 27
CC CC CC 08
DD DD DD 08
00 00 00 00
FC 1C 23 08
11 2D 0A 08

At CCCCCC:
00 00 00 20 00 08 00 00 00

At DDDDDD:
EE EE EE 08

At EEEEEE:
00 00 04 00 04 00
__________________

Last edited by Spherical Ice; 3 Weeks Ago at 01:23 AM.
Reply With Quote
  #135    
Old 3 Weeks Ago, 08:47 AM
hashtag's Avatar
hashtag
the man in black
Community Supporter
 
Join Date: Nov 2008
Location: Salisbury, England
Age: 19
Gender: Male
I like this thread and all it contributes so I'm stickying it for a bit :)

#stickied
__________________
"i am the hero pokécommunity deserves, but not the one it needs right now"

paired with christos
Reply With Quote
  #136    
Old 2 Weeks Ago, 02:35 AM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
Here is the effect for acupressure:
Acupressure (Set the targeting scheme to '2' so that the move it can select any target bank):
Code:
#dynamic 0x800000
#freespacebyte 0xFF

#org @main
callasm 0x8GGGGGG+1
attackcanceler
attackstring
ppreduce
callasm 0x8HHHHHH+1
attackanimation
waitanimation
callasm 0x8IIIIII+1
statbuffchange 0x1 false 0x81D694E
jumpifbyte 0x0 0x2023E87 0x2 0x81D694E
setbyte 0x2023FD4 0x27
playanimation 0x0 0x1 0x2023FD4
cmd47
printfromtable 0x83FE57C
waitmessage 0x40
goto 0x81D694E
Asm at GGGGGG:
Code:
.text
.align 2
.thumb
.thumb_func
.global targetAdjust

main:
push {lr}
ldr r0, userBank
ldr r1, targetBank
ldrb r2, [r0]
ldrb r3, [r1]
mov r4, #0x1
and r4, r2
mov r5, #0x1
and r5, r3
cmp r4, #0x1
beq targetside
cmp r5, #0x1
bne end
sub r3, #0x1
strb r3, [r1]
b end

targetside:
cmp r5, #0x1
beq end
add r3, #0x1
strb r3, [r1]
end:
pop {r0}
bx r0

.align 2
targetBank: .word 0x02023D6C
userBank: .word 0x02023D6B
ASM at HHHHHH
Code:
.text
.align 2
.thumb
.thumb_func
.global accstatcomp

main:
push {lr}
ldr r0, targetBank
ldrb r0, [r0]
ldr r1, battleData
mov r2, #0x58
mul r2, r0
add r3, r2, r1
ldr r1, userBank
ldrb r1, [r1]
cmp r1, r0
bne subcheck

nosub:
ldr r4, [r3, #0x18]
ldr r5, comp1
cmp r4, r5
bgt allmax
b end

subcheck:
ldr r4, [r3, #0x50]
ldr r5, subval
cmp r4, r5
beq fail
b nosub

allmax:
ldr r4, [r3, #0x1c]
ldr r5, comp2
cmp r4, r5
bne end
fail:
ldr r1, failScript
ldr r0, scriptPointer
str r1, [r0, #0x0]
end:
pop {r0}
bx r0

.align 2
failScript: .word 0x081D7DF0
targetBank: .word 0x02023D6C
userBank: .word 0x02023D6B
battleData: .word 0x02023BE4
scriptPointer: .word 0x02023D74
comp1: .word 0x0C0C0C00
comp2: .word 0x0C0C0C0C
subval: .word 0x01000000
ASM at IIIIII:
Code:
.text
.align 2
.thumb
.thumb_func
.global accupressure

main:
push {lr}
bl GetRand
mov r1, #0x7
and r1, r0
ldr r0, targetBank
ldrb r0, [r0]
ldr r2, battleData
mov r3, #0x58
mul r0, r3
add r4, r0, r2
add r4, #0x18
cmp r1, #0x0
bne Cont
Limitadj:
mov r1, #0x1

Cont:
add r6, r4, r1
ldrb r5, [r6, #0x0]
cmp r5, #0xC
bne End
cmp r1, #0x7
beq Limitadj 
add r1, #0x1
b Cont

End:
add r1, #0x20
ldr r2, statByte
strb r1, [r2]
pop {r0}
bx r0

GetRand:
ldr r2, randGen
bx r2

.align 2
statByte: .word 0x02023FDE
targetBank: .word 0x02023D6C
battleData: .word 0x02023BE4
randGen: .word 0x08044EC9
The first ASM adjusts the target, if accidentally selected by the player or AI that is out of the range of acupressure i.e opponent's team, to the required range. (If somebody has the knowledge of hacking the targeting scheme then this ASM would not be required).

The seconds ASM checks for maximization of all stats and ally's substitute.

The third ASM randomly selects the boosting byte.

Last edited by KDS; 2 Weeks Ago at 09:05 AM. Reason: Important bug correction
Reply With Quote
  #137    
Old 2 Weeks Ago, 03:04 AM
hackstar's Avatar
hackstar
Check it out!!
 
Join Date: Jan 2013
Location: Dhaka
Gender: Male
Nature: Bashful
I have a question,how will these work for emerald ?
__________________
Do not waste your time by seeing my signature.
Reply With Quote
  #138    
Old 2 Weeks Ago, 10:51 PM
destinedjagold's Avatar
destinedjagold
Oh Hai Thar~ 'ω'
Community Supporter
 
Join Date: May 2007
Location: Philippines
Gender: Male
Nature: Careful
Here's my poor attempt at porting Ice Fang to Ruby.
Code:
01 72 6F 1D 08 00 00 02 03 04 05 06 07 09 0A 0E 5C 00 3A 0B 00 0C 00 0D 12 40 00 0F 12 40 00 2E 21 4D 02 02 08 15 2E 21 4D 02 02 84 15 28 5B 6F 1D 08
But it has a problem though... It instantly freezes the target, no matter how much percent chance I put on any move-editing tools. =/
__________________
Reply With Quote
  #139    
Old 1 Week Ago, 06:11 AM
byrikudouvlog's Avatar
byrikudouvlog
Romhacker promise
 
Join Date: Feb 2014
Location: Milano, IT
Gender: Female
Nature: Serious
i wanna create my own custom moves of the VI GEN too, please, do u know where can i find the hex data of the animations or how can i calculate the hex data?
please, im disperate
Reply With Quote
  #140    
Old 1 Week Ago, 07:09 PM
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
Quote:
Originally Posted by KDS View Post
Here is the effect for acupressure:
Acupressure (Set the targeting scheme to '2' so that the move it can select any target bank):

The first ASM adjusts the target, if accidentally selected by the player or AI that is out of the range of acupressure i.e opponent's team, to the required range. (If somebody has the knowledge of hacking the targeting scheme then this ASM would not be required).

The seconds ASM checks for maximization of all stats and ally's substitute.

The third ASM randomly selects the boosting byte.
The move freezes when it's executed. Also targeting 2 isn't very good, because in single battles you can pick the opponent which isn't ideal.
__________________
Reply With Quote
  #141    
Old 1 Week Ago, 09:39 PM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
Quote:
Originally Posted by MrDollSteak View Post
The move freezes when it's executed. Also targeting 2 isn't very good, because in single battles you can pick the opponent which isn't ideal.
It isn't good but this scheme is capable of selecting any bank individually. There does not exist a scheme similar to accupressure in gen 3. I do not not have the knowledge of hscking targetting scheme. So the first asm is written to rectify the target e.g in a single battle if you select the enemy the target is readjusted to the user i.e. if you select the enemy as the target accupressure would still work on the user.

And tell me, when it is freezing? After the attack name is announced or before? I'll look into it.
Reply With Quote
  #142    
Old 1 Week Ago, 09:52 PM
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
Quote:
Originally Posted by KDS View Post
It isn't good but this scheme is capable of selecting any bank individually. There does not exist a scheme similar to accupressure in gen 3. I do not not have the knowledge of hscking targetting scheme. So the first asm is written to rectify the target e.g in a single battle if you select the enemy the target is readjusted to the user i.e. if you select the enemy as the target accupressure would still work on the user.

And tell me, when it is freezing? After the attack name is announced or before? I'll look into it.
Ah okay, I didn't realise that's what the first ASM did because of the freezing. I assumed it was for double battles. I don't entirely remember what moves occur in Gen III but surely there must be one that you can only use on yourself or your partner? This would be helpful in creating Aromatic Mist too.

The move name doesn't even come up. It freezes before that.
It could just be my assembler acting up, I'll double check it as well.
__________________
Reply With Quote
  #143    
Old 1 Week Ago, 04:20 AM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
Quote:
Originally Posted by MrDollSteak View Post
Ah okay, I didn't realise that's what the first ASM did because of the freezing. I assumed it was for double battles. I don't entirely remember what moves occur in Gen III but surely there must be one that you can only use on yourself or your partner? This would be helpful in creating Aromatic Mist too.

The move name doesn't even come up. It freezes before that.
It could just be my assembler acting up, I'll double check it as well.
I rechecked and reassembled the ASM statement on a Fire Red 1.0 ROM, and it was running perfectly. If there is some problem while setting the move in your ROM, then I can send you the direct compiled hex codes.

Actually, acupressure is the only 1 move out of 619 moves that uses this unique targeting scheme and since this was from Gen IV it was not coded in the GBA. Aromatic Mist only can target an ally pokemon (similar to helping hand) (Source: Bulbapedia).
Reply With Quote
  #144    
Old 1 Week Ago, 05:02 PM
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
Quote:
Originally Posted by KDS View Post
I rechecked and reassembled the ASM statement on a Fire Red 1.0 ROM, and it was running perfectly. If there is some problem while setting the move in your ROM, then I can send you the direct compiled hex codes.

Actually, acupressure is the only 1 move out of 619 moves that uses this unique targeting scheme and since this was from Gen IV it was not coded in the GBA. Aromatic Mist only can target an ally pokemon (similar to helping hand) (Source: Bulbapedia).
Okay well that's fair enough then, I didn't realise exactly how it worked.

Okay well I'll look at Helping Hand's code to try and make that then. Never used the move in XY so I assumed it was User / Ally.

I feel like when compiling to the rom it probably messed up a bx or b. I've noticed that when using KK552's compiler if it goes from 9000F2 to 900100 the branches sometimes mess up. I'll just recompile them.
__________________
Reply With Quote
  #145    
Old 1 Week Ago, 07:02 PM
KDS
 
Join Date: Jul 2013
Age: 19
Gender: Male
Quote:
Originally Posted by MrDollSteak View Post
Okay well that's fair enough then, I didn't realise exactly how it worked.

Okay well I'll look at Helping Hand's code to try and make that then. Never used the move in XY so I assumed it was User / Ally.

I feel like when compiling to the rom it probably messed up a bx or b. I've noticed that when using KK552's compiler if it goes from 9000F2 to 900100 the branches sometimes mess up. I'll just recompile them.
I suggest using hackmew's thumb assembler with command line, it is very good.
Reply With Quote
  #146    
Old 1 Day Ago, 07:31 AM
karatekid552's Avatar
karatekid552
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
I have given Spherical Ice ownership of this thread so that the top post can keep being updated. Good luck guys!

~karatekid552
__________________

Paired with Simba
Reply With Quote
  #147    
Old 1 Day Ago, 08:37 AM
Spherical Ice's Avatar
Spherical Ice
Community Supporter
 
Join Date: Nov 2007
Location: UK
Send a message via Skype™ to Spherical Ice
I've updated the OP, and also renamed the thread so it isn't so limited in what can be posted. I've also sorted the moves that don't require new effects, with the move that they can use the effect of already.
__________________
Reply With Quote
  #148    
Old 1 Day Ago, 04:48 PM
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
Quote:
Originally Posted by Spherical Ice View Post
I've updated the OP, and also renamed the thread so it isn't so limited in what can be posted. I've also sorted the moves that don't require new effects, with the move that they can use the effect of already.
Loving the renovation! You can probably delete some of the move effects up there that I've since redone, eg. Growth, Quiver Dance, Hone Claws etc.

I'm also going to post some updated Fang effects, using the 'may cause flinch' move effect slot, so the AI uses them better.

------------------------------------------------

In the mean time I have some animations to post!

Flower Shield
Spoiler:
02 24 7B 3E 08 02 05 01 00 01 00 00 00 08 00 7D 6E 05 00 AF 27 00 97 27 0A 03 0C 0C 08 19 C3 00 C0 02 94 2B 3E 08 02 04 00 00 E8 FF 08 00 8C 00 02 AC 2B 3E 08 02 04 10 00 E8 FF 08 00 64 00 02 AC 2B 3E 08 02 04 F0 FF E8 FF 08 00 64 00 04 0F 02 94 2B 3E 08 02 04 00 00 E8 FF 08 00 8C 00 02 AC 2B 3E 08 02 04 20 00 E8 FF 08 00 64 00 02 AC 2B 3E 08 02 04 E0 FF E8 FF 08 00 64 00 04 0F 02 94 2B 3E 08 02 04 00 00 E8 FF 08 00 8C 00 02 AC 2B 3E 08 02 04 18 00 E8 FF 08 00 64 00 02 AC 2B 3E 08 02 04 E8 FF E8 FF 08 00 64 00 04 1E 02 AC 2B 3E 08 02 04 10 00 E8 FF 00 00 64 00 02 AC 2B 3E 08 02 04 F0 FF E8 FF 00 00 64 00 04 1E 02 AC 2B 3E 08 02 04 14 00 F0 FF 0E 00 50 00 02 AC 2B 3E 08 02 04 EC FF F2 FF 10 00 50 00 05 0B 03 0D 02 24 7B 3E 08 02 05 01 00 01 00 08 00 00 00 7D 6E 05 0B 03 0D 08 08


Rototiller
Spoiler:
00 5A 27 00 29 28 02 C4 7A 3E 08 01 03 00 00 00 00 B4 00 02 C4 7A 3E 08 01 03 00 00 01 00 B4 00 03 7D 90 09 08 02 05 00 00 06 00 04 00 02 00 04 00 0E 0A A9 1C 08 0E 0A A9 1C 08 03 7D 90 09 08 02 05 00 00 06 00 04 00 02 00 04 00 0E 0A A9 1C 08 0E 0A A9 1C 08 05 23 00 04 01 08


Sticky Web
Spoiler:
00 1B 27 00 C5 27 00 C4 27 0A 03 04 00 02 24 7B 3E 08 05 05 01 00 02 00 00 00 09 00 00 00 05 28 01 1C 7A 00 C0 09 06 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 0E A5 15 1D 08 05 19 7B 00 3F 02 DC 72 3E 08 02 00 05 0B 03 04 01 02 24 7B 3E 08 05 05 01 00 02 00 09 00 00 00 00 00 08 02 90 72 3E 08
__________________
Reply With Quote
Reply
Quick Reply

Sponsored Links


Advertise here
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
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 01:20 AM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2014 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2014 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.