• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[ARCHIVE] Simple Questions (SEARCH BEFORE ASKING A QUESTION)

Status
Not open for further replies.
534
Posts
11
Years
  • Age 26
  • Seen Jul 24, 2023
Hey guys! One question!

Can I give the player a Pokemon in these conditions?

-Player's Party contains only 5 or less Pokemon
-I give him a Pokemon in the PC Storage Box without him knowing
 

karatekid552

What happens if I push it?....
1,771
Posts
11
Years
Hey guys! One question!

Can I give the player a Pokemon in these conditions?

-Player's Party contains only 5 or less Pokemon
-I give him a Pokemon in the PC Storage Box without him knowing

1) Yes. Use the countpokemon command.

2) Sort of. As far as I know, this happens when the party is full and no countpokemon command is used to make sure it isn't full. So, be creative.

(I actually don't know the name of the command off the top of my head. It is either countpokemon, checkparty, or something else. Hit F1 in XSE and scroll through until you see it)
 
534
Posts
11
Years
  • Age 26
  • Seen Jul 24, 2023
1) Yes. Use the countpokemon command.

2) Sort of. As far as I know, this happens when the party is full and no countpokemon command is used to make sure it isn't full. So, be creative.

(I actually don't know the name of the command off the top of my head. It is either countpokemon, checkparty, or something else. Hit F1 in XSE and scroll through until you see it)

Nononononoo.... What I meant was those two in a single event.

When there are 5 or less Pokemon in the Party, it will ignore those and give the Player a Pokemon in Storage Box 1, thus perfectly ignoring the Player's Party count and gives the Player a Pokemon in the PC no matter how many Pokemon he has in his Party.

EDIT: Reworded for more "sense".
 
Last edited:

miksy91

Dark Energy is back in action! ;)
1,480
Posts
15
Years
Nononononoo.... What I meant was those two in a single event.

When there are 5 or less Pokemon in the Party, it will ignore those and give the Player a Pokemon in Storage Box 1, thus perfectly ignoring the Player's Party count and gives the Player a Pokemon in the PC no matter how many Pokemon he has in his Party.

EDIT: Reworded for more "sense".
You simply have to store the variable in address of "current party count" somewhere else in ram, change the value in "current party count" to 06 (or whatever the format is, 06 00 ??), give the pokemon, and load the variable (= "real party count") back to the address where "current party count" is located.

I don't know how well the ram structure is commented about FR, but at least somebody should know where the party pokemon data (and especially, party count) is stored.
If for some odd reason nobody knows, debugging process would be a good way to go for it (which won't be that easy though).
 

DrFuji

[I]Heiki Hecchara‌‌[/I]
1,691
Posts
14
Years
Nononononoo.... What I meant was those two in a single event.

When there are 5 or less Pokemon in the Party, it will ignore those and give the Player a Pokemon in Storage Box 1, thus perfectly ignoring the Player's Party count and gives the Player a Pokemon in the PC no matter how many Pokemon he has in his Party.

EDIT: Reworded for more "sense".

As far as I know there is no way to simple way to deposit a Pokemon directly into the PC so you will have to be creative to get this effect. I was able to achieve this by continuously giving the player a Pokemon until their party is full, give them the desired Pokemon and then remove the extra 'party filler' Pokemon using HackMew's takepokemon routine.

This is what I came up with:

Code:
#dynamic 0x800000

#org @start // Counting the number of party members and assigning the value to 2 variables
countpokemon
copyvar 0x8004 0x800D
copyvar 0x8005 0x8004
goto @Loop1

#org @Loop1 // This segment will keep looping until the player's party is full and then adds one more Pokemon (which will be transferred to the PC)
givepokemon 0x19 0x5 0x0 0x0 0x0 0x0
addvar 0x8005 0x1
compare 0x8005 0x7
if 0x1 goto @Continue
goto @Loop1

#org @Continue // Setting up for the next loop or skipping it entirely if you initially had six Pokemon in your party
copyvar 0x8005 0x8004
setvar 0x8005 0x6
comparevars 0x8005 0x8004
if 0x1 goto @Finish
goto @Loop2

#org @Loop2 // This is subtracting a number based on your starting party size to be compared in the next loop
subvar 0x8005 0x1
comparevars 0x8005 0x8004
if 0x0 goto @8004Set
goto @Loop2

#org @8004Set // Setting 0x8004 to be used in the next loop
setvar 0x8004 0x5
goto @Loop3

#org @Loop3 // This loop takes away all of the extra Pokemon given to the player
callasm 0x810001 // This is where I inserted HackMew's routine in my ROM
subvar 0x8004 0x1
comparevars 0x8005 0x8004
if 0x1 goto @Finish
goto @Loop3

#org @Finish
msgbox @Goodbye 0x2
release
end

#org @Goodbye
= I hope you like your Pikachu!\nIt is in your PC!

It doesn't work correctly if you don't have any Pokemon in your party, but it does put a single Pokemon in your PC in all other cases. I tried to condense it as much as I could (otherwise it would be pretty huge) so sorry for all the loops if they get a bit confusing :P
 
534
Posts
11
Years
  • Age 26
  • Seen Jul 24, 2023
As far as I know there is no way to simple way to deposit a Pokemon directly into the PC so you will have to be creative to get this effect. I was able to achieve this by continuously giving the player a Pokemon until their party is full, give them the desired Pokemon and then remove the extra 'party filler' Pokemon using HackMew's takepokemon routine.

This is what I came up with:

Code:
#dynamic 0x800000

#org @start // Counting the number of party members and assigning the value to 2 variables
countpokemon
copyvar 0x8004 0x800D
copyvar 0x8005 0x8004
goto @Loop1

#org @Loop1 // This segment will keep looping until the player's party is full and then adds one more Pokemon (which will be transferred to the PC)
givepokemon 0x19 0x5 0x0 0x0 0x0 0x0
addvar 0x8005 0x1
compare 0x8005 0x7
if 0x1 goto @Continue
goto @Loop1

#org @Continue // Setting up for the next loop or skipping it entirely if you initially had six Pokemon in your party
copyvar 0x8005 0x8004
setvar 0x8005 0x6
comparevars 0x8005 0x8004
if 0x1 goto @Finish
goto @Loop2

#org @Loop2 // This is subtracting a number based on your starting party size to be compared in the next loop
subvar 0x8005 0x1
comparevars 0x8005 0x8004
if 0x0 goto @8004Set
goto @Loop2

#org @8004Set // Setting 0x8004 to be used in the next loop
setvar 0x8004 0x5
goto @Loop3

#org @Loop3 // This loop takes away all of the extra Pokemon given to the player
callasm 0x810001 // This is where I inserted HackMew's routine in my ROM
subvar 0x8004 0x1
comparevars 0x8005 0x8004
if 0x1 goto @Finish
goto @Loop3

#org @Finish
msgbox @Goodbye 0x2
release
end

#org @Goodbye
= I hope you like your Pikachu!\nIt is in your PC!

It doesn't work correctly if you don't have any Pokemon in your party, but it does put a single Pokemon in your PC in all other cases. I tried to condense it as much as I could (otherwise it would be pretty huge) so sorry for all the loops if they get a bit confusing :P

Thanks for that!

So if I understand right, when a Pokemon is given to the Player with 6 Pokemon in his/her party, it will automatically get transferred to the PC?

I didn't knew that! All the time I was playing Pokemon games and when someone would give you Pokemon, they'd ask you to empty a slot first. Thanks again!
 

kearnseyboy6

Aussie's Toughest Mudder
300
Posts
15
Years
  • Seen Jun 22, 2019
I think the problem may be that jigglypuff's theme is a fanfare. I will change the bytes that define it as a fanfare to a normal song...

And Kearnseyboy6
to solve your problem, after you assemble your song theres a popup. Click yes and it fixes the length issue.

True, "You failed it again" must be a fanfare too which is why mine failed it as well.

If you want to add more, I have read a tut by LAZ which expands song tables but I have no need for it yet.

Your tuts awesome btw!
 

Akiba

[img]http://i.imgur.com/o3RYT4v.png[/img]
4,262
Posts
13
Years
Hey guys! One question!

Can I give the player a Pokemon in these conditions?

-Player's Party contains only 5 or less Pokemon
-I give him a Pokemon in the PC Storage Box without him knowing

In PKSV, there is a giveitemtopc command. XSE likely has it too. You could copy and rewrite it a bit into a 'givepokemontopc' command. Then it would always be accessible through a script editor.
 

Zemekis

The Booze Cruise
22
Posts
11
Years
Quick question!

Can i change what the badges look like? Will I be able to find/change their sprites in unLZ?
 

Akiba

[img]http://i.imgur.com/o3RYT4v.png[/img]
4,262
Posts
13
Years
Quick question!

Can i change what the badges look like? Will I be able to find/change their sprites in unLZ?

Of course, you can check it in an UnLZ index. If you tell me your codebase, I could look it up for you.

FR: 149
EM: 2525
RS: I couldn't fit it yet.
 

AtecainCorp.

Rejishan awake...
1,377
Posts
15
Years
I have three questions.

1. It is possible to add extra Town Map to Pokemon Ruby? I want add Johto Region to them. (DO NOT GIVE ANSWER LEARN ASM - This is the worst answer) Where is routine to displaying maps.

2. How to set and Johto Wild Battle *Which i repleced with Test theme of Littleroot town* To playing in Johto Areas?

3. It is possible to resize amout of abled SPRITES in Pokemon Ruby? I want add all Johto Leaders without only 6 <Unused sprites> of them.

I need Explain and number of thouse routines. And as I said. I do not need answers like "LEARN ASM" It is not simple as you think.
 

Zemekis

The Booze Cruise
22
Posts
11
Years
Of course, you can check it in an UnLZ index. If you tell me your codebase, I could look it up for you.

FR: 149
EM: 2525
RS: I couldn't fit it yet.

Thanks Delta! I'm using FireRed, I don't know why it didn't occur to me to search UnLZ index.


Also, I replaced the sprites for a Pokemon using the Advanced Pokemon Sprite Editor, and checked (using showpokepic, as well as givepokemon) that the sprite was showing properly in-game.
Then I edited him using YAPE, and when I saved my changes things went haywire. Showpokepic only reveals a black box where his sprite was, and in Advanced Sprite Editor it now tells me "data is not LZ77 compressed!". Any idea what happened?

As always, thanks a MILLION for your help guys. Each time I think i'm getting the hang of this, I hit another wall.
 

Akiba

[img]http://i.imgur.com/o3RYT4v.png[/img]
4,262
Posts
13
Years
I have three questions.

1. It is possible to add extra Town Map to Pokemon Ruby? I want add Johto Region to them. (DO NOT GIVE ANSWER LEARN ASM - This is the worst answer) Where is routine to displaying maps.

2. How to set and Johto Wild Battle *Which i repleced with Test theme of Littleroot town* To playing in Johto Areas?

3. It is possible to resize amout of abled SPRITES in Pokemon Ruby? I want add all Johto Leaders without only 6 <Unused sprites> of them.

I need Explain and number of thouse routines. And as I said. I do not need answers like "LEARN ASM" It is not simple as you think.

I could help you, but I don't quite understand what you mean.

1.Town Map? As in a World Map, right? If you don't want to learn ASM, then you could copy and repoint the world map data, then set the script (called from the behavior byte) to display different world maps. It would require a lot of repointing and hex editing, though.

2. I'm not quite sure what this means, but I'll guess at it. To change the music, just compile a Johto sequence into the ROM. Then change the battle music per map in Advance Map.

3. Changing the amount of allowed sprites? Just ignore the last two and never call them.

Thanks Delta! I'm using FireRed, I don't know why it didn't occur to me to search UnLZ index.


Also, I replaced the sprites for a Pokemon using the Advanced Pokemon Sprite Editor, and checked (using showpokepic, as well as givepokemon) that the sprite was showing properly in-game.
Then I edited him using YAPE, and when I saved my changes things went haywire. Showpokepic only reveals a black box where his sprite was, and in Advanced Sprite Editor it now tells me "data is not LZ77 compressed!". Any idea what happened?

As always, thanks a MILLION for your help guys. Each time I think i'm getting the hang of this, I hit another wall.

Maybe you saved separate instances of the ROM?

Some hacking tools are programmed to load a copy of a ROM into memory, edit that, and save it when done. If you are using two separate programs, unless both write directly to the ROM, you'd have to finish one task and start another.
 
Last edited:

Zemekis

The Booze Cruise
22
Posts
11
Years
Maybe you saved separate instances of the ROM?

Some hacking tools are programmed to load a copy of a ROM into memory, edit that, and save it when done. If you are using two separate programs, unless both write directly to the ROM, you'd have to finish one task and start another.

Hmmmm, sounds like a good guess, but unfortunately YAPE was the only program I had open at the time, so that couldn't be it. Hopefully somebody familiar with the LZ77 error will see this soon.
I've attached a photo of the error i'm getting.
Thanks for your time again, Delta.
 

Jambo51

Glory To Arstotzka
736
Posts
14
Years
  • Seen Jan 28, 2018
I have three questions.

1. It is possible to add extra Town Map to Pokemon Ruby? I want add Johto Region to them. (DO NOT GIVE ANSWER LEARN ASM - This is the worst answer) Where is routine to displaying maps.

2. How to set and Johto Wild Battle *Which i repleced with Test theme of Littleroot town* To playing in Johto Areas?

3. It is possible to resize amout of abled SPRITES in Pokemon Ruby? I want add all Johto Leaders without only 6 <Unused sprites> of them.

I need Explain and number of thouse routines. And as I said. I do not need answers like "LEARN ASM" It is not simple as you think.

There are only 2 answers to your first and second questions.

1. Learn ASM and figure out how to do the effect for yourself or
2. Get a willing ASM hacker to help you out.

Both of the first 2 things you want here require ASM (as in, it's not achievable through any other means). It's not my job, nor anyone else's, to do research for your hack on your behalf.

If you don't like this, then tough. Welcome to the real world. I'm sorry to be so harsh, but simply refusing to learn ASM and reiterating your demand for information that likely nobody has (Ruby isn't widely hacked, and almost no ASM hackers hack on Ruby) isn't going to get you anywhere.

Secondly, take it from me, learning to ASM hack is an archetypal example of people turning a molehill into a mountain. It's actually pretty simple to ASM hack at the level of stuff you're doing. Rather than simply telling us it's hard, why not take the word of every ASM hacker I know when they say "it's not as hard as it's made out to be".

As to your third question, that can be achieved by combining some pseudo-ASM (that is to say, limiters research) and a simple table repoint. I don't know where the table is in Ruby, although it's easy enough to find by looking for the pointer to the first trainer sprite in the game (the offset for which can be found by looking at it in unLz.)
 
Last edited:

kearnseyboy6

Aussie's Toughest Mudder
300
Posts
15
Years
  • Seen Jun 22, 2019
As to your third question, that can be achieved by combining some pseudo-ASM (that is to say, limiters research) and a simple table repoint. I don't know where the table is in Ruby, although it's easy enough to find by looking for the pointer to the first trainer sprite in the game (the offset for which can be found by looking at it in unLz.)

Hi, regarding this limiters research, are there any tutorials around here that dive into this topic? It would be cool to know how Hackmew and you guys actually finds limiter bytes as they are quite hidden!
 

kearnseyboy6

Aussie's Toughest Mudder
300
Posts
15
Years
  • Seen Jun 22, 2019
I have a quick question, could someone tell me in detail how I would go about changing the default name selection for my rival in Fire Red?
Download A-text, then search for the default names the search section, "GARY, GREEN... etc" in the order. Add the text then edit it.
 
Status
Not open for further replies.
Back
Top