Go Back   The PokéCommunity Forums > ROM Hacking > ROM Hacking Hub > Beginner’s Lounge
Reload this Page [ARCHIVE] Simple Questions (SEARCH BEFORE ASKING A QUESTION)

Notices
For all updates, view the main page.

Beginner’s Lounge Where all good (and bad) ideas start. This is the Beginner’s Lounge, where if you need a helping hand or want to develop your small ideas, you bring it here. We won't bite.



Closed Thread
 
Thread Tools
  #24076    
Old March 3rd, 2013 (11:16 PM).
miksy91's Avatar
miksy91 miksy91 is offline
Dark Energy is back in action! ;)
 
Join Date: Oct 2008
Location: A small country in the North
Gender: Male
Nature: Relaxed
Posts: 1,327
Quote originally posted by karatekid552:
Most likely, it is a part of the routine that is carried out when you tell your pokemon to attack. It probobly runs though and sees your highest badge, then branches off, checks if the pokemon's and your IDs match, then, if not, compares the levels and sees if the pokemon is higher, if so, it goes on to calculate the chance of the pokemon not obeying. If any one of the checks passes, the routine return to the starting point and runs as normal. I have not a clue as to where said routine is located though:/. I just stared learning ASM and still have trouble finding things like that. I wish I could help more.
These kind of routines are often found with debugging. If you've got "nothing" to begin with, you might want to first look for the asm routine used for giving you a badge. For this, you also use debugger by tracking down the routine used by that "givebadge X" command.

If I was to do that myself, I would start looking what is executed when you talk to a person event which does nothing more than give you a certain badge and execute "return to gameplay" then.

Once you've found the asm routine used to give you a badge, you'll also find where in ram 1 is written and next, you start debugging the obeying routine using this ram address as a breakpoint. The program will stop executing code when this ram address is looked for during the code which, like you said, happens next to the code of comparing the ID of the pokemon attacking to the ID of the player.

You modify the routine there and... job finished.
__________________
My Rom Hack




Learn how to hack GB/C games:

Check my GameBoy/Color hacking videos in Youtube
-The video set uses Pokemon Silver (U) rom for demonstrations
  #24077    
Old March 4th, 2013 (01:56 AM).
Jambo51's Avatar
Jambo51 Jambo51 is offline
Glory To Arstotzka
 
Join Date: Jun 2009
Gender: Male
Nature: Quiet
Posts: 730
Quote originally posted by karatekid552:
Most likely, it is a part of the routine that is carried out when you tell your pokemon to attack. It probobly runs though and sees your highest badge, then branches off, checks if the pokemon's and your IDs match, then, if not, compares the levels and sees if the pokemon is higher, if so, it goes on to calculate the chance of the pokemon not obeying. If any one of the checks passes, the routine return to the starting point and runs as normal. I have not a clue as to where said routine is located though:/. I just stared learning ASM and still have trouble finding things like that. I wish I could help more.
Having looked at the code which takes care of this, I can tell you you're nearly 100% right. The code is pretty simple, it checks the flags which are tied to the badges, and branches if they're set. It then compares the Pokémon's level against a hard coded value, which would be easy to change with a simple hex edit. It then performs a random if the Pokémon's OTID doesn't match yours. If I remember right, it's a weighted random. That is, the higher over the level cap, the more likely it is to disobey. However, what would be better would be rewriting if to support more flags and level caps. Reading from tables is always a good way to support such extendability.
__________________
Hey guys, please check out my recreations of the gen 1 and 2 music on my custom engine at my SoundCloud! - Here!
  #24078    
Old March 4th, 2013 (02:21 AM). Edited March 4th, 2013 by karatekid552.
karatekid552's Avatar
karatekid552 karatekid552 is offline
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Posts: 1,767
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Quote originally posted by destinedjagold:


I've encountered the same problem during my hacking time with Life of Guardians, and yes, I believe there is a limit of how many NPCs are to be displayed on the screen. :\
This I know is a definable. The game can only have so many OAMs displayed at once.

Quote originally posted by Jambo51:
Having looked at the code which takes care of this, I can tell you you're nearly 100% right. The code is pretty simple, it checks the flags which are tied to the badges, and branches if they're set. It then compares the Pokémon's level against a hard coded value, which would be easy to change with a simple hex edit. It then performs a random if the Pokémon's OTID doesn't match yours. If I remember right, it's a weighted random. That is, the higher over the level cap, the more likely it is to disobey. However, what would be better would be rewriting if to support more flags and level caps. Reading from tables is always a good way to support such extendability.
Awesome, my guessing skills are getting better. I was actually banking on the hope that you or Darth would come along and see this and give me some help.:p Now to find it....

Quote originally posted by miksy91:
These kind of routines are often found with debugging. If you've got "nothing" to begin with, you might want to first look for the asm routine used for giving you a badge. For this, you also use debugger by tracking down the routine used by that "givebadge X" command.

If I was to do that myself, I would start looking what is executed when you talk to a person event which does nothing more than give you a certain badge and execute "return to gameplay" then.

Once you've found the asm routine used to give you a badge, you'll also find where in ram 1 is written and next, you start debugging the obeying routine using this ram address as a breakpoint. The program will stop executing code when this ram address is looked for during the code which, like you said, happens next to the code of comparing the ID of the pokemon attacking to the ID of the player.

You modify the routine there and... job finished.
I know how to debug and modify routines. It's more of a where do I start? kind of thing.:p So, thanks for giving me that clue, I'll see if I can find it!
__________________

Paired with Simba
  #24079    
Old March 4th, 2013 (02:05 PM).
Flame999's Avatar
Flame999 Flame999 is offline
 
Join Date: Nov 2008
Location: Lavaridge Town
Gender: Male
Nature: Calm
Posts: 97
How would I go about gender based rivals as I plan to put two gender based rival Green/Red & Kris/Ethan and I have no idea how to do that so if you could point the way that would be great
__________________
Pokemon Fire Red Hack
-3rd Gen game
- more rival
- New Tiles
- New Trainer sprites
- New Map for Hoenn (replace Sevii islands)
Finished making the Hoenn & Kanto Gym leaders
Finished making the Hoenn & Kanto Elite four and Champions

  #24080    
Old March 4th, 2013 (02:51 PM).
awipe1's Avatar
awipe1 awipe1 is offline
 
Join Date: Aug 2012
Gender: Male
Posts: 210
I have a stupid question that i'm pretty sure I know the answer to already, but is there away to add more memory to your ROM? I have a very bad feeling that I will run out of varibales and offsets eventually if I make my game. I just don't want to be in half way through my game then realise that I can't make anymroe because I have ran out of variables and memory.
__________________
Check out my Pokemon Rom! Click the Image Below!
  #24081    
Old March 4th, 2013 (05:24 PM). Edited March 4th, 2013 by karatekid552.
karatekid552's Avatar
karatekid552 karatekid552 is offline
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Posts: 1,767
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Quote originally posted by Flame999:
How would I go about gender based rivals as I plan to put two gender based rival Green/Red & Kris/Ethan and I have no idea how to do that so if you could point the way that would be great
A command called "checkgender" will help you. Just set it up so that based upon which gender, it runs different scripts, activates different battles, and, in turn, creates gender based rivals. Full documentation for it can be found in diegoisawesome's XSE tutorial.

Quote originally posted by awipe1:
I have a stupid question that i'm pretty sure I know the answer to already, but is there away to add more memory to your ROM? I have a very bad feeling that I will run out of varibales and offsets eventually if I make my game. I just don't want to be in half way through my game then realise that I can't make anymroe because I have ran out of variables and memory.
No way that I know of to add more variables and memory in the RAM, but you can increase the rom size from 16mb to 32mb using a function in XSE version 1.1.1, it is in one of the top menus.
__________________

Paired with Simba
  #24082    
Old March 4th, 2013 (06:07 PM).
FBI agent's Avatar
FBI agent FBI agent is offline
If my PM box is full, VM instead :x
 
Join Date: Jan 2013
Location: Unknown Island
Gender: Male
Posts: 831
Quote originally posted by awipe1:
I have a stupid question that i'm pretty sure I know the answer to already, but is there away to add more memory to your ROM? I have a very bad feeling that I will run out of varibales and offsets eventually if I make my game. I just don't want to be in half way through my game then realise that I can't make anymroe because I have ran out of variables and memory.
If you run out of variables you can always allocate some free space for custom variables and use writebytetooffset.

Also, you can expand your ROM if you want (there's actually tools to do it), but from what I've heard, it's a risky process.
__________________
...

My name forum name is FBI Agent, though you can call me FBI because it's shorter.

Some of my stuff:
ASM request/resource thread
ASM tutorials thread
ASM Workshop
  #24083    
Old March 4th, 2013 (08:22 PM).
Mr. Whiscash's Avatar
Mr. Whiscash Mr. Whiscash is offline
Unegged Hatch
 
Join Date: Sep 2008
Gender: Male
Nature: Sassy
Posts: 89
Is there an easy way to edit the evolution method of a Pokemon in Platinum? Because it turns out the tool I'm using has the evolution method window just for show.
__________________
  #24084    
Old March 5th, 2013 (04:27 AM). Edited March 5th, 2013 by ChaosBringer41.
ChaosBringer41 ChaosBringer41 is offline
 
Join Date: Nov 2010
Gender: Male
Posts: 34
Sorry if this is in the wrong part of the forum, but here goes:
How can I insert resized DS Pokemon sprites into, say, Fire Red?
- I want three of the starter choices from the DS games as the starter choices in one of my hacks - a 'this is how I want to play' type hack, not a total rewrite like Shiny Gold -

I tried using the Search function, but for some reason, it didn't show any results for inserting sprites, nevermind where to look for them.

Turtwig, Piplup, Emboar and their evolutions, if anyone is wondering - I want ones that ultimately have two Types.
__________________
I don't always know what I'm doing. Life is more interesting that way.
  #24085    
Old March 5th, 2013 (06:22 AM).
ep!c ep!c is offline
Banned
 
Join Date: Mar 2013
Gender: Male
Posts: 124
Send a message via Skype™ to ep!c
All LZ77 compressed graphics can be inserted with the UNLZ oder NLZ GBA.
The Pokémon must be located in the UNLZ somewhere around 1200-1400..
  #24086    
Old March 5th, 2013 (07:19 AM).
Aryan143's Avatar
Aryan143 Aryan143 is offline
The Fennekin Fan!
 
Join Date: Jul 2012
Location: Delhi, India
Age: 15
Gender: Male
Nature: Modest
Posts: 756
Hey I have a problem. I just installed a new window yesterday and I updated my .NET framework but I am having a problem to run these programs:

NSE( both classic and 2.X)
YAPE
All the editors in the Wichu Sprite Editor series

It shows an error report. Can someone help me? They were working fine on the previous Windows
__________________
Check out my gaming company:

  #24087    
Old March 5th, 2013 (08:05 AM).
LocksmithArmy's Avatar
LocksmithArmy LocksmithArmy is offline
Mew!
 
Join Date: Feb 2013
Age: 26
Gender: Male
Posts: 402
what is the error report... specifically,... screenshot it or write down all the words...
__________________
  #24088    
Old March 5th, 2013 (12:36 PM).
karatekid552's Avatar
karatekid552 karatekid552 is offline
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Posts: 1,767
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Quote originally posted by ep!c:
All LZ77 compressed graphics can be inserted with the UNLZ oder NLZ GBA.
The Pokémon must be located in the UNLZ somewhere around 1200-1400..
That is probably the hardest way to do it besides hex editing them in yourself:p.

I know you have been gone for a while, so I'll let you know that Wichu released a set of Pokemon sprite editors called the Advance Series. These work amazing for sprites of just pokemon, and the sprites are not required to be indexed:D. For other sprites, NSE Classic and NSE 2.X can handle just about any compressed or uncompressed image, provided you know the location of their image and palette.
__________________

Paired with Simba
  #24089    
Old March 5th, 2013 (06:43 PM).
Aryan143's Avatar
Aryan143 Aryan143 is offline
The Fennekin Fan!
 
Join Date: Jul 2012
Location: Delhi, India
Age: 15
Gender: Male
Nature: Modest
Posts: 756
Here is the error image I am getting:



This is same on all these programs
__________________
Check out my gaming company:

  #24090    
Old March 5th, 2013 (07:06 PM).
tajaros's Avatar
tajaros tajaros is offline
Hi I'm dawg
 
Join Date: Apr 2012
Location: Philippines
Age: 16
Gender: Male
Nature: Timid
Posts: 857
Send a message via Windows Live Messenger to tajaros
Quote originally posted by Aryan143:
Here is the error image I am getting:



This is same on all these programs
What OS are you running?

Also if the new .NET Framework doesn't work for you try the older versions.
__________________
  #24091    
Old March 5th, 2013 (07:19 PM).
Aryan143's Avatar
Aryan143 Aryan143 is offline
The Fennekin Fan!
 
Join Date: Jul 2012
Location: Delhi, India
Age: 15
Gender: Male
Nature: Modest
Posts: 756
Quote originally posted by tajaros:
What OS are you running?

Also if the new .NET Framework doesn't work for you try the older versions.
I am using Windows XP SP3 and I have tried the older .NET Frameworks plus it worked on the old Windows
__________________
Check out my gaming company:

  #24092    
Old March 5th, 2013 (07:25 PM).
tajaros's Avatar
tajaros tajaros is offline
Hi I'm dawg
 
Join Date: Apr 2012
Location: Philippines
Age: 16
Gender: Male
Nature: Timid
Posts: 857
Send a message via Windows Live Messenger to tajaros
Quote originally posted by Aryan143:
I am using Windows XP SP3 and I have tried the older .NET Frameworks plus it worked on the old Windows
Try redownloading the programs, it should work properly I think. I had this problem before and the only thing that fixed it is by downloading an older version of .NET Framework.
__________________
  #24093    
Old March 5th, 2013 (07:34 PM). Edited March 5th, 2013 by Aryan143.
Aryan143's Avatar
Aryan143 Aryan143 is offline
The Fennekin Fan!
 
Join Date: Jul 2012
Location: Delhi, India
Age: 15
Gender: Male
Nature: Modest
Posts: 756
Quote originally posted by tajaros:
Try redownloading the programs, it should work properly I think. I had this problem before and the only thing that fixed it is by downloading an older version of .NET Framework.
Ok thanks, I will try it.

EDIT: I tried the old framework and bang, it worked again. Thanks a lot tajaros!
__________________
Check out my gaming company:

  #24094    
Old March 5th, 2013 (09:12 PM).
Noossab Blue's Avatar
Noossab Blue Noossab Blue is offline
 
Join Date: Dec 2012
Location: USA
Gender: Female
Nature: Quirky
Posts: 243
So...I want to edit the text of Oak's tutorial battle in A-text, but when I did my game glitched out and crashed. I tried it again with special text marked but it didn't help...

I did repoint a few of the strings...is that the problem? Or is it something else?

Quote originally posted by Jambo51:
Having looked at the code which takes care of this, I can tell you you're nearly 100% right. The code is pretty simple, it checks the flags which are tied to the badges, and branches if they're set. It then compares the Pokémon's level against a hard coded value, which would be easy to change with a simple hex edit. It then performs a random if the Pokémon's OTID doesn't match yours. If I remember right, it's a weighted random. That is, the higher over the level cap, the more likely it is to disobey. However, what would be better would be rewriting if to support more flags and level caps. Reading from tables is always a good way to support such extendability.
So...basically I need to be able to ASM Hack to do it?
__________________
IGN: Anna/Noossab Blue
3DS FC: 3196 3609 8450

Thanks to SilverGrey for the awesome banner! Click to see!
Current as of 1/31/14: I updated again!

  #24095    
Old March 5th, 2013 (10:48 PM).
destinedjagold's Avatar
destinedjagold destinedjagold is offline
Oh Hai Thar~ 'ω'
Silver Tier
 
Join Date: May 2007
Location: Philippines
Gender: Male
Nature: Careful
Posts: 7,247
Quote originally posted by Noossab Blue:
So...I want to edit the text of Oak's tutorial battle in A-text, but when I did my game glitched out and crashed. I tried it again with special text marked but it didn't help...

I did repoint a few of the strings...is that the problem? Or is it something else?
A-Text causes many problems if you repoint stuff.
If you want to edit the text with the use of that tool, then you need to stay within the available character limit.

If you really need to put a longer text, then you need to manually repoint his dialogue through hex editing.
__________________


3DS FC: 0061-1111-6462
TSV: 1364(X), 0790(OR)

~Serge,
Chrono Cross


  #24096    
Old March 6th, 2013 (02:12 AM).
karatekid552's Avatar
karatekid552 karatekid552 is offline
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Posts: 1,767
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Quote originally posted by Noossab Blue:
So...basically I need to be able to ASM Hack to do it?
You need to have ASM skills to find it. From there it is just simple byte changes with a hex editor. I plan on giving this more of a look when I find the time.
__________________

Paired with Simba
  #24097    
Old March 6th, 2013 (04:51 AM).
ep!c ep!c is offline
Banned
 
Join Date: Mar 2013
Gender: Male
Posts: 124
Send a message via Skype™ to ep!c
To find the routine requires NOT ASM skills.
To interprate the routine requires it neither too maybe, because its maybe one single number for the level..
  #24098    
Old March 6th, 2013 (09:32 AM).
Noossab Blue's Avatar
Noossab Blue Noossab Blue is offline
 
Join Date: Dec 2012
Location: USA
Gender: Female
Nature: Quirky
Posts: 243
Quote originally posted by destinedjagold:


A-Text causes many problems if you repoint stuff.
If you want to edit the text with the use of that tool, then you need to stay within the available character limit.

If you really need to put a longer text, then you need to manually repoint his dialogue through hex editing.
Ok, thanks for that info. I'll just shorten what I had to say.

Quote originally posted by karatekid552:
You need to have ASM skills to find it. From there it is just simple byte changes with a hex editor. I plan on giving this more of a look when I find the time.
I greatly appreciate it sir.
__________________
IGN: Anna/Noossab Blue
3DS FC: 3196 3609 8450

Thanks to SilverGrey for the awesome banner! Click to see!
Current as of 1/31/14: I updated again!

  #24099    
Old March 6th, 2013 (06:03 PM).
kearnseyboy6's Avatar
kearnseyboy6 kearnseyboy6 is offline
Aussie's Toughest Mudder
 
Join Date: Dec 2008
Posts: 294
Hi guys, I am wondering if there is anyway to ADD new map banks. I know there are over 100 of them but is there a way to add new ones without having to modify them. Eg: If I change PALLET TOWN the town name changes all the map names. Does this make sense? Or can I add new map headers?
  #24100    
Old March 6th, 2013 (07:12 PM).
Noossab Blue's Avatar
Noossab Blue Noossab Blue is offline
 
Join Date: Dec 2012
Location: USA
Gender: Female
Nature: Quirky
Posts: 243
Ok, so I edited the Oak Tutorial in A-text without repointing...and it still glitches out and restarts the game...
__________________
IGN: Anna/Noossab Blue
3DS FC: 3196 3609 8450

Thanks to SilverGrey for the awesome banner! Click to see!
Current as of 1/31/14: I updated again!

Closed Thread
Quick Reply

Sponsored Links

You may also like.. (Beta)
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 03:31 PM.