The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Creative Discussions > Emulation & ROM Hacking > Tutorials
Register New Account FAQ/Rules Chat Blogs Mark Forums Read

Notices

Tutorials Looking for a guide to help you out? Then you're in the right place! We've got everything you need, ranging from Mapping to Music!
New threads in this forum are to be approved by a moderator before they are displayed. The thread revival limit does not apply here.



Reply
Thread Tools
  #101  
Unread November 1st, 2011, 07:48 AM
erusanma's Avatar
erusanma
Beginning Trainer
 
Join Date: Aug 2011
Gender: Male
I have a question about your debbuger,because the command prompt dysplays this message:

..............
Unknown file type pokemon.

Also,when trying to open a fire red rom,only a white image is displayed in the emulator.

But apart from all this all your tools are exellent,specially xse because I really like scripting in an easy way(not like pokescript or scripted).

Sorry for any mistake I commit but English is not my native language.
Reply With Quote
  #102  
Unread April 8th, 2012, 02:42 AM
NintendoBoyDX
Togepi
 
Join Date: Jul 2010
Gender: Male
This is way more complicated than it needs to be... 080440F4 is the shiny decision routine. Go to 0804411E and replace it with 00 20. This is the spot that it checks whether the value is greater or less than 7. Replacing that will make the value always 00 right before the check, and that means all pokemon will be shiny. Much easier to replace 2 bytes.

just throwin that out there
Reply With Quote
  #103  
Unread April 11th, 2012, 01:56 AM
YouListeningROMs's Avatar
YouListeningROMs
Beginning Trainer
 
Join Date: Mar 2012
Gender: Male
With ASM, how would you do modulo?
Reply With Quote
  #104  
Unread April 11th, 2012, 06:39 AM
NintendoBoyDX
Togepi
 
Join Date: Jul 2010
Gender: Male
Quote:
Originally Posted by YouListeningROMs View Post
With ASM, how would you do modulo?
There are a couple of ways in fr. There is software interrupt 0x6, which is a bios function call that does division and modulo. There is routine 081E4018 developed by gamefreak, that does division and modulo as well.

R0 = dividend
R1 = divisor

returning
R0 = quotient
R1 = modulo answer

081E4684 is another routine made by gamefreak that does modulo only.

A few other math routines:
081E460C: another division routine
081E3B9C: square root, calls swi 0x8

I've stumbled across a few others that I dont remember..
Reply With Quote
  #105  
Unread April 11th, 2012, 11:57 AM
YouListeningROMs's Avatar
YouListeningROMs
Beginning Trainer
 
Join Date: Mar 2012
Gender: Male
Quote:
Originally Posted by NintendoBoyDX View Post
There are a couple of ways in fr. There is software interrupt 0x6, which is a bios function call that does division and modulo. There is routine 081E4018 developed by gamefreak, that does division and modulo as well.

R0 = dividend
R1 = divisor

returning
R0 = quotient
R1 = modulo answer

081E4684 is another routine made by gamefreak that does modulo only.

A few other math routines:
081E460C: another division routine
081E3B9C: square root, calls swi 0x8

I've stumbled across a few others that I dont remember..
Thank you for your assistance.
Reply With Quote
  #106  
Unread November 13th, 2012, 04:07 PM
truekidmoney
Unhatched Egg
 
Join Date: Apr 2011
Gender: Male
Hey guys i have a question how do i get the results lesson1.bin this:
03 B5 03 48 00 68 03 49 80 89 08 80 03 BD C0 46
0C 50 00 03 D0 70 03 02
into my rom?
Reply With Quote
  #107  
Unread November 13th, 2012, 04:13 PM
Manipulation's Avatar
Manipulation
it's a mad world
 
Join Date: Nov 2008
Location: Salisbury, England
Age: 18
Gender: Male
Use a Hex Editor and insert the bytes into free space ending with a 0, 4, 8 or C.
__________________
Pokémon Sienna: Experience the thrill again
"i'm a man of simple tastes; no whiskey or caviar"




Reply With Quote
  #108  
Unread November 30th, 2012, 03:55 PM
CallarinCreator's Avatar
CallarinCreator
Unhatched Egg
 
Join Date: Sep 2012
Gender: Male
kan u post something on xse? it aint wantin to work for me. it will work. but it shuts down after like a second.
__________________
iiiiiiii uummm.... i scared.

house of EVIL!!! muhuahahahahhahahaha!!!!!!!!!
Reply With Quote
  #109  
Unread November 30th, 2012, 05:27 PM
Deokishisu's Avatar
Deokishisu
Mr. Magius
 
Join Date: Feb 2006
Location: If I'm online, it's a safe bet I'm at a computer.
Gender: Male
Nature: Relaxed
Quote:
Originally Posted by CallarinCreator View Post
kan u post something on xse? it aint wantin to work for me. it will work. but it shuts down after like a second.
O poor English, struck down in its prime.

Anyway, this is because of the auto update feature. Since Hackmew's site is down, it tries to update, fails, and closes. To fix it, go into your .ini file and change it so that the AutoUpdateCheck equals zero.

So that line should look like this:
AutoUpdateCheck=0
Reply With Quote
  #110  
Unread January 31st, 2013, 12:52 AM
gogojjtech's Avatar
gogojjtech
Experienced ROM Hacker
 
Join Date: Nov 2012
Location: New York City
Age: 14
Gender: Male
Nature: Quiet
These are extremely helpful ( and long ) well great job hackmew
__________________
I believe in Jesus Christ my Savior. If you do too, and aren't scared to admit it, then copy and paste this in your signature.


Pokémon Platinum Red and Blue Versions! Coming soon!
GUYS, IF MY IMAGES OR LINKS ARE BROKEN PLEASE PM OR VM ME. THANK YOU
Need help with a hack? Ask me anything! I'll be sure to help you!
Reply With Quote
  #111  
Unread February 3rd, 2013, 08:37 AM
Chaos Rush's Avatar
Chaos Rush
Pokémon DarkViolet restarting
 
Join Date: May 2007
Gender: Male
Nature: Adamant
I decided to take a crack at HackMew's ASM challenge, and I succeeded!


This is what I modified the routine to:
Code:
.text
.align 2
.thumb
.thumb_func
.global lesson1

main:
	push {r0-r1, lr}
	ldr r0, .PLAYER_DATA
	ldr r0, [r0]
	ldr r1, .VAR
	ldrh r0, [r0, #0xC]
	strh r0, [r1]	
	ldr r0, .PLAYER_DATA
	ldr r0, [r0]
	ldr r1, .NEXT
	ldrh r0, [r0, #0xA]
	strh r0, [r1]
	pop {r0-r1, pc}


.align 2
.PLAYER_DATA:
	.word 0x0300500C
.VAR:
	.word 0x020270B6 + (0x800D * 2)
.NEXT:
	.word 0x020270B8 + (0x8000 * 2)
And the XSE script:
Code:
#dynamic 0x800000
#org @main
callasm YourASMoffset
buffernumber 0x0 LASTRESULT
buffernumber 0x1 0x8000
msgbox @msg MSG_FACE
end


#org @msg
= Your Trainer ID is [buffer2].\nYour Secret ID is [buffer1].
Going to do my best to get ASM down...
__________________

Pokémon DarkViolet

DS-style 64x64 Pokémon Sprite Resource
oh and you should probably check this out too

Guys, please stop VM/PMing me about ROM hacking questions. I'm not an "expert ROM hacker". I'm an artist.

Non-Pokémon hacks I support:
Sonic Classic Heroes
Sonic 3 Complete
Reply With Quote
  #112  
Unread February 3rd, 2013, 02:46 PM
FBI agent
Imagine something beautiful
 
Join Date: Jan 2013
Location: Isle 4 - Dairy Products
Gender: Male
Quote:
Originally Posted by Chaos Rush View Post
I decided to take a crack at HackMew's ASM challenge, and I succeeded!


Spoiler:
This is what I modified the routine to:
Code:
.text
.align 2
.thumb
.thumb_func
.global lesson1

main:
	push {r0-r1, lr}
	ldr r0, .PLAYER_DATA
	ldr r0, [r0]
	ldr r1, .VAR
	ldrh r0, [r0, #0xC]
	strh r0, [r1]	
	ldr r0, .PLAYER_DATA
	ldr r0, [r0]
	ldr r1, .NEXT
	ldrh r0, [r0, #0xA]
	strh r0, [r1]
	pop {r0-r1, pc}


.align 2
.PLAYER_DATA:
	.word 0x0300500C
.VAR:
	.word 0x020270B6 + (0x800D * 2)
.NEXT:
	.word 0x020270B8 + (0x8000 * 2)
And the XSE script:
Code:
#dynamic 0x800000
#org @main
callasm YourASMoffset
buffernumber 0x0 LASTRESULT
buffernumber 0x1 0x8000
msgbox @msg MSG_FACE
end


#org @msg
= Your Trainer ID is [buffer2].\nYour Secret ID is [buffer1].


Going to do my best to get ASM down...
Spoiler tags, pls!
Also, you don't need to load player data twice.
It should till work without doing this the second time:
ldr r0, .PLAYER_DATA
ldr r0, [r0]

EDIT: I lied, the way you did it, you did need to load it twice (or subtract :D).
__________________
...

Hacks I support:
http://www.pokecommunity.com/showthread.php?t=297199 --Legend of Anbuja
http://www.pokecommunity.com/showthread.php?t=200227 -- Pokemon Rose version

People I work for:
Scripter
Anbuja's_BlooDY -- Legend of Anbuja

FYI:
- You can ask me for scripting help
- I take simple ASM requests

People whom I thank:
Comrade -- For helping me with my bad hack, and for being a good friend
Darthatron -- Helping me get into basic ASM, even though I'm hopeless. (He is heartless stay away).
Anbuja's_BlooDY -- Graphics help, and being a good friend
FBI -- For having the username I wanted
Reply With Quote
  #113  
Unread February 10th, 2013, 04:22 AM
karatekid552's Avatar
karatekid552
Scyther
 
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
Almost all of the reference links for the ASM tutorial are broken. I have found a few of them, would it be alright for me to post them here? Or should I pm them to DrFuji/giradalkia to add to the end of the tut?

Edit: only two are broken.... Wow, I remember that being a lot more last time....

Edit2: I guess since no one has objected it is fine for me to post the links here:


Assembly Wikipedia: (So easy to find it really wasn't broken, but whatever) http://en.wikipedia.org/wiki/Assembly_language

ARM7DTMI Technical Manuel: http://infocenter.arm.com/help/topic...c/DDI0210B.pdf

Tonic: Whirlwind Tour of ARM Assembly: http://www.coranac.com/tonc/text/asm.htm


Hope these help anyone who wants to learn ASM.
__________________
If you didn't do it like a BOSS, you didn't do it RIGHT!
Just some of the more BOSS Pokemon....
People and Hacks I support:

Hacks I own:

Last edited by karatekid552; February 11th, 2013 at 03:36 PM.
Reply With Quote
  #114  
Unread 1 Day Ago, 06:12 PM
Kurapika's Avatar
Kurapika
Grudgebearer
 
Join Date: Feb 2013
Location: Lavendar Town - Morocco
Age: 22
Gender: Male
Nature: Naughty
Since I see people asking questions here, I have a problem using ldr with cmp. I am making a code that compares two words, one located in the RAM and the other located in the ROM. so what I do:
Spoiler:
ldr r1, .word1 ldr r1, [r1] ldr r2, .word2 ldr r2, [r2] cmp r1, r2 beq YayTheyEqualz ...
The problem is, the jump never occurs even when the words are equal... So I tried this:
Spoiler:
ldr r1, .word1 ldrh r1, [r1] ldr r2, .word2 ldrh r2, [r2] cmp r1, r2 beq SecondHalf ... SecondHalf: ldr r1, .word1 ldr r1, [r1, #0x2] ldr r2, .word2 ldrh r2, [r2, #0x2] cmp r1, r2 beq YayTheyEqualz ...
And this 2nd code works correctly but takes more space and it is more complicated. So, I'm wondering if ldr and/or cmr commands have some particular behaviour that makes the first code not working??? Or am I just doing something wrong?
__________________


Last edited by Kurapika; 1 Day Ago at 06:18 PM.
Reply With Quote
  #115  
Unread 1 Day Ago, 11:30 PM
karatekid552's Avatar
karatekid552
Scyther
 
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
Quote:
Originally Posted by Kurapika View Post
Since I see people asking questions here, I have a problem using ldr with cmp. I am making a code that compares two words, one located in the RAM and the other located in the ROM. so what I do:
Spoiler:
ldr r1, .word1 ldr r1, [r1] ldr r2, .word2 ldr r2, [r2] cmp r1, r2 beq YayTheyEqualz ...
The problem is, the jump never occurs even when the words are equal... So I tried this:
Spoiler:
ldr r1, .word1 ldrh r1, [r1] ldr r2, .word2 ldrh r2, [r2] cmp r1, r2 beq SecondHalf ... SecondHalf: ldr r1, .word1 ldr r1, [r1, #0x2] ldr r2, .word2 ldrh r2, [r2, #0x2] cmp r1, r2 beq YayTheyEqualz ...
And this 2nd code works correctly but takes more space and it is more complicated. So, I'm wondering if ldr and/or cmr commands have some particular behaviour that makes the first code not working??? Or am I just doing something wrong?
Would you mind giving us all of the ASM in the regular format? It is really tough the read this way.
__________________
If you didn't do it like a BOSS, you didn't do it RIGHT!
Just some of the more BOSS Pokemon....
People and Hacks I support:

Hacks I own:
Reply With Quote
  #116  
Unread 1 Day Ago, 12:31 AM
Kurapika's Avatar
Kurapika
Grudgebearer
 
Join Date: Feb 2013
Location: Lavendar Town - Morocco
Age: 22
Gender: Male
Nature: Naughty
code 1: code 2: The first one doesn't jump to TheyAreEqualz even when it should, the second code works perfectly for me. (Sorry, for some reason, line skips are removed from my posts ;_; I think it's just my ****** Internet -.-')
__________________

Reply With Quote
  #117  
Unread 1 Day Ago, 02:00 AM
karatekid552's Avatar
karatekid552
Scyther
 
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
Quote:
Originally Posted by Kurapika View Post
code 1: code 2: The first one doesn't jump to TheyAreEqualz even when it should, the second code works perfectly for me. (Sorry, for some reason, line skips are removed from my posts ;_; I think it's just my ****** Internet -.-')
From looking at your code, both routines are loading different things. Parts are loading words and others are loading half-words and neither lines up with the other routine. That is probably where your problem lies. A word is 4 bytes and a half-word is 2 bytes. Take that as you wish.
__________________
If you didn't do it like a BOSS, you didn't do it RIGHT!
Just some of the more BOSS Pokemon....
People and Hacks I support:

Hacks I own:
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. The time now is 04:51 AM.


Style by Perdition Haze, artwork by Sa-Dui.
Like our Facebook Page Follow us on TwitterMessage Board Statistics | © 2002 - 2013 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to Pokémon USA, Inc. and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company, Pokémon USA, Inc., The Pokémon Company International, or Wizards of the Coast. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2013 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 posts belong to the user.