• 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?".
  • Forum moderator applications are now open! Click here for details.
  • Welcome to PokéCommunity! Register now and join one of the best places on the 'net to talk Pokémon and more! Community members will not see the bottom screen advertisements.
  • Want to share your adventures playing Pokémon?
    Check out our new Travel Journals forum for sharing playthroughs of ROM Hacks, Fan Games, and other Pokémon content!
  • IMPORTANT: Following a takedown request, the following hacks have been delisted from PokéCommunity:

    • Pokémon Glazed
    • Pokémon: Giratina Strikes Back
    • Pokémon Flora Sky
    • Pokémon Stranded
    The downloads and discussion threads for these hacks will no longer be accessible, and staff will be unable to return questions regarding accessing this content.

Adding New Moves and Creating New Move Effects

104
Posts
11
Years
  • Age 32
  • Seen Nov 28, 2023
just wondering, can you change the TM moves with the new (created) moves??
 

Omega Zero

Is back...
444
Posts
14
Years
just wondering, can you change the TM moves with the new (created) moves??

Yes, you need to download Pokemon game editor and use their team snagem item editor tool.

If your wondering how to change the trainers moves you must check the offset *when it asks you to repoint that number*

you must go there in a hex editor and find the moves and replace it with the new hex code because A-trainer won't be able to change it to the new moves itself.
 

MrDollSteak

Formerly known as 11bayerf1
858
Posts
15
Years
just wondering, can you change the TM moves with the new (created) moves??

You can do this very easily with a hex editor.
You need to go to the offsets 45A5A4 and 45A80C
These are the offsets for the TM data. Each TM is made up of two bytes
eg. 08 01
This is equivalent to the index number 108, which is for Focus Punch.
All you need to do is change the two bytes of the TMs that you want to
replace with the index number of your move in the form YYXX.
Eg. 19B will become 9B 01

On an unrelated note I've found fixes for Coil and Quiver Dance that use 0 effect accuracy and 0 actual accuracy

It also allowed me to create Shell Smash.

Here are the codes:


Coil
Spoiler:


Quiver Dance
Spoiler:


Shell Smash
Spoiler:


Using this style of code in conjunction with Solarbeam's code I've found a way to make the Gen 5 growth,
where it raises ATK and SPATK by 1 stage in normal weather and 2 stages in Sunny Weather.

Growth
Spoiler:


The bytes ZZ YY XX and ZZ2 YY2 XX2 point to the execution of the code under the weather,
wherein ZZ YY XX is normal weather, and ZZ2 YY2 XX2 is Sunny Weather.
I normally place them right behind eachother for conveniences sake.
It will use ZZ YY XX in Rain and Sandstorm as well.
 
Last edited:

MrDollSteak

Formerly known as 11bayerf1
858
Posts
15
Years
Here is a list of what you can do by changing this byte. These are the ones that work 100% of the time. Meaning, these effects will ALWAYS happen. There are more (I didn't test from 00-C0) but I'm sure they are the same effects, just with less of a chance of happening. I know 01 has a 10% chance of putting an opponent to sleep, 03 has a 10% chance of burning an opponent, etc...

Spoiler:

I've just started looking into other moves and found that below C0 they aren't the same effects. For example looking at Shadow Ball its effect is:

Spoiler:


Wherein 1A lowers opponent's special defense by 1 stage. It doesn't seem to have a set percentage, you have to set it in PGE. Also looking at Psycho Boost and Overheat they have their effect set at 100 so perhaps these offsets you've listed don't have a 100% chance to happen?

Edit: Further research has revealed that offsets between 01 and 3B roughly follow the same pattern as those listed above but for the opponent. So far all the stat changers correspond as will status changers. Im not sure about recoil or outrage.
 
Last edited:

Jambo51

Glory To Arstotzka
736
Posts
14
Years
  • Seen Jan 28, 2018
Growth
Spoiler:


The bytes ZZ YY XX and ZZ2 YY2 XX2 point to the execution of the code under the weather,
wherein ZZ YY XX is normal weather, and ZZ2 YY2 XX2 is Sunny Weather.
I normally place them right behind eachother for conveniences sake.
It will use ZZ YY XX in Rain and Sandstorm as well.

This won't work as intended. You see, command 2A checks literal values, not bitwise checks (which is how the weather bits work). You're asking it if it's 0x4 than 0x60 (I forget what 0x4 actually is).

What you should be doing is ANDing the address with those bits. However, to my knowledge, there are no such commands in the vanilla game.

As such, your script will only work under very specific circumstances, (when the weather bits are set to 0x60) and not under all Sunny weather types. (It's possible to only have 0x20 set, or only 0x40 set).
 

MrDollSteak

Formerly known as 11bayerf1
858
Posts
15
Years
This won't work as intended. You see, command 2A checks literal values, not bitwise checks (which is how the weather bits work). You're asking it if it's 0x4 than 0x60 (I forget what 0x4 actually is).

What you should be doing is ANDing the address with those bits. However, to my knowledge, there are no such commands in the vanilla game.

As such, your script will only work under very specific circumstances, (when the weather bits are set to 0x60) and not under all Sunny weather types. (It's possible to only have 0x20 set, or only 0x40 set).

Don't worry, I tested it before posting and have had no problems. I got the code from Solarbeam and just changed the information contained at the pointers. I've used it under Sunny Day, Drought Sunny Day, Plain Weather, Rain, Sandstorm and Hail, on every turn, and so far it works 100%
 
Last edited:
4
Posts
13
Years
  • Seen Nov 26, 2016
Here's a code for clear smog:

Spoiler:

Hi! This code doesn't work for me, if I use it with 0 (never miss) accuracy. Can somebody help me, what should I edit that this works fine, like 11bayerf1's codes?
 
104
Posts
11
Years
  • Age 32
  • Seen Nov 28, 2023
Yes, you need to download Pokemon game editor and use their team snagem item editor tool.

If your wondering how to change the trainers moves you must check the offset *when it asks you to repoint that number*

you must go there in a hex editor and find the moves and replace it with the new hex code because A-trainer won't be able to change it to the new moves itself.

You can do this very easily with a hex editor.
You need to go to the offsets 45A5A4 and 45A80C
These are the offsets for the TM data. Each TM is made up of two bytes


hey, thanks dude! :)

EDIT2: Everyone do this too. Update PGE's ini file (Open up PGE, goto Help > Update > ROM ini file). Then, go to where we were changing the pointers for the attack data and such, and there should be a new pointer at the bottom that says "AttackAnimationPointer"..

when i do this, nothing happens. it does say ".ini updated" but nothing really change, the new pointer won't show up. can i edit it manually, like, typing or something? if yes, what and where should i type?

edit: fixed it. it's not AttackAnimationPointer but AttackAnimationTable
 
Last edited:
534
Posts
11
Years
  • Age 26
  • Seen Jul 24, 2023
Hey guys, for some reason, whenever I disable the limiter and play the game, it still says "BULBASAUR used a NORMAL move!" How do I disable it? I've done that step a million times still the same! Also the PP data is just a few, is that right?
 

pawell6

The truthseeker
50
Posts
14
Years
Hey guys I was wondering if someone found code for stealth rock. I tried to find it, but I failed. Please help.
 

MrDollSteak

Formerly known as 11bayerf1
858
Posts
15
Years
Dragon Tail is really starting to annoy me :S

I've been trying to combine the normal attack effect with roar/whirlwind:

Here's my current code

Spoiler:


So far what happens is that the animation will play, the foe is damaged.
Then the animation plays again, and the foe is either sent out or the move
fails. Basically the two parts, the damage and phasing, are disassociated,
and both run of the accuracy of the move (90%) so regardless of whether
the move hits or not, there is still a chance the phase effect will miss.

From looking at the code, all the pointers seem to point to animations, and
the bytes in front of them seem to relate to conditions. For example, if its a
trainer with 1 pokemon, trainer with more, wild pokemon etc.

As such I'm finding it hard what to remove to make the effect run immediately
after the damage.
 

pawell6

The truthseeker
50
Posts
14
Years
Hey guys, it's been awhile since I posted. Anyway using BSP and JPAN's thread about battle scripts I managed to find code for frost breath:

Spoiler:
 

Jambo51

Glory To Arstotzka
736
Posts
14
Years
  • Seen Jan 28, 2018
Don't worry, I tested it before posting and have had no problems. I got the code from Solarbeam and just changed the information contained at the pointers. I've used it under Sunny Day, Drought Sunny Day, Plain Weather, Rain, Sandstorm and Hail, on every turn, and so far it works 100%

I did some research, and I am due you an apology for this. It turns out that 0x4 and 0x5 ARE bitwise checks.

0x4 stands for (if any bits set, jump), and 0x5 stands for (if no bits set, jump). My bad. :( (Note, I checked this against the actual ASM, so I KNOW it's right :P)
 

MrDollSteak

Formerly known as 11bayerf1
858
Posts
15
Years
I did some research, and I am due you an apology for this. It turns out that 0x4 and 0x5 ARE bitwise checks.

0x4 stands for (if any bits set, jump), and 0x5 stands for (if no bits set, jump). My bad. :( (Note, I checked this against the actual ASM, so I KNOW it's right :P)

No worries! It's always good to check, to be honest I don't particularly understand the reasoning behind why it worked, so it's good you've looked into it! Also feel free to use the code for the 649 patch if you would like to!
 
33
Posts
12
Years
  • Seen Dec 17, 2016
I've got a question here.

I'm trying to create the effect for Hurricane, so I basically copied Thunder and replaced the 05 byte (for paralysis) with a 07 (for confusion). I then paste wrote the code to another offset, pointed one of the effect indices to that offset, and then assigned that effect to the attack slot for Hurricane (which I had already created).

The problem is that although Hurricane successfully confuses, it doesn't always hit in the rain, but I pasted the code for Thunder byte-for-byte. So I don't know what's wrong here.

I then decided to test something else: I assigned Thunder's effect to Hurricane, except this time I changed the 05 byte in Thunder to 07. Now Hurricane confuses and always hits in the rain with the effect at this offset, but not with the effect at the copied offset.

The code for Thunder is:
2E 85 3E 02 02 05 35 D0 3D 02 02 00 00 01 00 28 00 69 1D 08

Can anyone help me out?
 

DoesntKnowHowToPlay

Tiny Umbrella with Lots and Lots of Good
265
Posts
12
Years
  • Seen Feb 24, 2024
Thunder's perfect accuracy in rain is a hard-coded effect associated with the slot, not a property of the battle script- the extra junk in the script is to set the variables that make it pierce Fly/Bounce. If you want to make proper Hurricane you'll need to find the check in the accuracy calc (put a breakpoint on Thunder's effect byte and use it in rain.)
 
33
Posts
12
Years
  • Seen Dec 17, 2016
Well, crap. I don't know how to do that (quite yet).

Is Solarbeam skipping its charge turn in strong sunlight also hardcoded to the moveslot?
 
Last edited:
943
Posts
11
Years
Hi! I followed this great tutorial to add new moves a while ago. Now I wanted to customize the descriptions of these new moves.
I found what it looks like the original table of pointers to moves' description, and copied it somewhere else in order to extend it and re-pointed it. But it didn't work, I don't know exactly what I am missing and need some assistance please. Or if someone already knows the pointer to the real table or something please tell me. Or if you know an easier way to edit those description it might work, too.
Thanks in advance! :]


EDIT: Sorry! I just realized I forgot to update the roms.ini with the new pointer. Sorry! ^^'
 
Last edited:
Back
Top