’Cause all games were better on the GBC

You are not logged in.

#1 2018-10-28 18:58:56

Registered: 2017-10-05
Post 24/64

Pokecrystal - need help with Battle_Commands.asm

So I've been messing around with Pokecrystal, and added some new functions to Battle_Commands.asm. The new functions make the file too big though. So I made a new file called Battle_Commands2.asm, moved some stuff from the bottom of the main file to this second file, and in main.asm where the include statements are set up with the banks, I added Battle_Commands2.asm to the bank right before the one containing the first Battle_Commands.asm. However, when testing it out, entering battle has some strange effects. Selecting FIGHT causes a substitute to appear, then a string of A characters fill the text box, and the game softlocks. So is it not possible for Battle_Commands to be split into different banks? The file is so large that it typically has a bank all to itself, so I had to put the new file in a seperate bank. Thanks.


#2 2018-10-31 19:07:54

Registered: 2010-10-16
Post 451/459

Re: Pokecrystal - need help with Battle_Commands.asm

This sounds more like the code you added has some bugs or you shifted the RAM layout or something. What exactly did you add and what do you want to accomplish?


#3 2018-10-31 19:23:35

Registered: 2009-11-25
Post 3,569/3,665

Re: Pokecrystal - need help with Battle_Commands.asm

Given that you split code between two banks, it could also be a case of trying to call code from inside another bank without using farcall, so it's reading unrelated code at the same address in the bank you're actually in, leading to weird effects.

I am not very active on this forum. I only pop in from time to time.


Board footer

Powered by FluxBB