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.


Reply
 
Thread Tools
  #1    
Old January 27th, 2010, 08:10 AM
Giga Universe's Avatar
Giga Universe
Working on a tool.
 
Join Date: Aug 2007
Location: South Africa
Age: 19
Gender: Male
Nature: Calm
Send a message via ICQ to Giga Universe Send a message via AIM to Giga Universe Send a message via Yahoo to Giga Universe Send a message via Skype™ to Giga Universe
Here is a topic that I have been mildly interested in. The idea is to built a script that can be activated during the game play, that allows the player to provide a custom name for a reoccurring character. I built a script that uses a nickname Pokémon Script, and stores the name on one of the buffers. However, I encountered two problems. First, the string buffers 1-3 are commonly used, and therefore would overwrite your rivals names. Second, using the nickname Pokémon Script provides more than 7 characters for the name, and would be inconvenient in dialogue. So, maybe someone could build a mod on the nickname script to force it to store the text in the RAM, usable like a buffer, and force the nickname script to only allow 7 characters? Since I have no ASM experience (I understand basic concepts, but can't code), I cannot investigate this further...
__________________
Reply With Quote
  #2    
Old January 27th, 2010, 09:12 PM
liuyanghejerry's Avatar
liuyanghejerry
Trainer
 
Join Date: Jan 2008
Location: China,Xi'an
Nature: Calm
Send a message via ICQ to liuyanghejerry Send a message via Windows Live Messenger to liuyanghejerry Send a message via Yahoo to liuyanghejerry
I don't understand you well.
But using writebytetooffset/loadbytefrompointer/bufferstring commands may help you.
__________________
Zel,thethethethe,LU-HO,Darthatron,HackMew,ZodiacDaGreat,Juan,score_under,JPAN,Tamah-chan,I really appreciate your kindness and your help!:D


I did something that really bad.But made all Chinese can hack Pokemon, too.If you guys hate me, I totally understand,but cannot do anything but force to keep everything.
If there must be someone to undertake all spit and curse, it must be me.
Reply With Quote
  #3    
Old January 28th, 2010, 03:32 AM
HackMew's Avatar
HackMew
Mewtwo Strikes Back
 
Join Date: Jun 2006
Using buffers is definitely not a good idea, indeed. Also, since the naming special works for Pokémon only, it needs to be hacked to eventually implement a custom rival/etc. naming. Aside from that, having custom names requires some reserved memory area for them. I'm thinking of variables, as with 4 variables you have 8 bytes which means 7 letters + string terminator (0xFF). Then, to use the name you could use the bufferstring command pointing to the first chosen variable address. Even though I never tried using bufferstring with a RAM pointer, it should work fine theoretically.
__________________

Last edited by HackMew; October 23rd, 2010 at 12:47 AM.
Reply With Quote
  #4    
Old January 28th, 2010, 11:13 AM
NarutoActor's Avatar
NarutoActor
The rocks cry out to me
Community Supporter
 
Join Date: Jan 2009
Location: Brooklyn/Marlboro
Age: 20
Gender: Female
Nature: Bashful
Send a message via AIM to NarutoActor Send a message via Windows Live Messenger to NarutoActor
hmm... here is an idea, when it comes to memory can't you just over-ride the old nick name with the new one?
__________________
~There are those people who understand hex, F the rest
Reply With Quote
  #5    
Old January 29th, 2010, 08:33 AM
Giga Universe's Avatar
Giga Universe
Working on a tool.
 
Join Date: Aug 2007
Location: South Africa
Age: 19
Gender: Male
Nature: Calm
Send a message via ICQ to Giga Universe Send a message via AIM to Giga Universe Send a message via Yahoo to Giga Universe Send a message via Skype™ to Giga Universe
Making progress. Using Hackmew's suggestion of using variables, which hold 2 characters each, I created a simple script, which uses setvars to set bytes to make up the word 'Giverse'.
Code:
#dynamic 0x800000

#org @start
setvar 0x8000 0xDDC1 'store the Gi
setvar 0x8001 0xD9EA 'store the ve
setvar 0x8002 0xE7E6 'store the rs
setvar 0x8003 0xFFD9 'store the e and the stop (0xFF)
bufferstring 0x1 0x020370B8 'buffer data located at 0x8000 - 0x8003
message @1 0x6
end

#org @1
= \v\h03
So, you can buffer a RAM address, it works perfectly. All that needs to be done is make an ASM routine that stores the chosen name to a variable, and then limit the choice of characters to 7.


EDIT:

Modified the above script. It copies text stored in buffer 1 directly from the RAM into the variable storage space. It has a custom nickname screen. But it does not limit to 7 characters. Right now, it shows a Bulbsaur instead of a Overworld, and says: "What will Balbasuar's nickname be?"
Code:
#dynamic 0x800000

#org @start
givepokemon 0x1 0x1 0x1 0x0 0x0 0x0
call 0x1A74EB
copybyte 0x020370B8 0x0202428c
copybyte 0x020370B9 0x0202428d
copybyte 0x020370BA 0x0202428e
copybyte 0x020370BB 0x0202428f
copybyte 0x020370BC 0x02024290
copybyte 0x020370BD 0x02024291
copybyte 0x020370BE 0x02024292
copybyte 0x020370BF 0x02024293
writebytetooffset 0xFF 0x020370C0
bufferstring 0x1 0x020370B8 'buffer data located at 0x8000 - 0x8003
message @1 0x6
special 0x0EF
end

#org @1
= Hello, my name is \v\h03!
__________________

Last edited by Giga Universe; January 29th, 2010 at 10:22 AM.
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
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 07:15 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.