Skeetendo

’Cause all games were better on the GBC

You are not logged in.

#1 2012-10-13 12:05:05

Gallego13
Member
Registered: 2011-12-11
Post 64/94

[Theory] Adding abilities to Gen II

I don't remember when, but I thought this some time ago and despite I don't know very much about assembly, it looked doable. The idea is to add abilities (like in Gen III/IV/V) to Gen II and I would do it like this:

First, every Pokémon would have one only ability (ex: Entei would have Pressure), each ability would be given a byte, so when the game checks the number, it would be something like: 07, 08 and 09 call bit 01, which loads Torrent ability's assembly. The next step would be to extend the Pokémon battle assembly code to add a routine that would check for the ability every turn. That routine would check first the number of ally Pokémon that is battling and load its ability from other offset; then it would do the same with the foe one. Abilities would have the same assembly type that attacks, so I think there wouldn't be any problem with that. I will give you a full example of how would it work:

•Battle starts: Gyarados vs Charizard.
•Turn 1: the battle routine checks Gyarados' number. As it's #130 (82) it would set bit 03 (that could be Intimidate's one).
•Then, the routine would check the bit that was previously set and load intimidate's assembly from another offset (something like “if bit = 03, call 0xABCDEF”).
•Intimidate would work like Growl, reducing attack by 1, but it would also check whether if he was called to battle in that turn or not. Then, the text saying “Gyarados' intimidate cuts Charizard's attack” would be called and the battle will continue normally.

I don't know very much about assembly, so I might not have used the correct words. Also this theory might have (and probably has) some mistakes, but I wanted to explain my theory to get some answers to know if this is possible or not.

Offline

#2 2012-10-13 17:48:51

Sawakita
Administrator
Registered: 2010-10-16
Post 319/364

Re: [Theory] Adding abilities to Gen II

Adding this kind of features is clearly possible; a more relevant question might be how much time and effort would such a thing require.

About the idea itself, it might be just me, but you seem a bit unclear about the concept of bit and byte:

Gallego13 wrote:

each ability would be given a byte, so when the game checks the number, it would be something like: 07, 08 and 09 call bit 01

If each abolity is represented by one byte (thus allowing 0xFF different abilites at most) why would you then use different octet values ("07, 08 and 09...") to have the same effect ("call bit 01")? What do you actually mean here?

Gallego13 wrote:

the battle routine checks Gyarados' number. As it's #130 (82) it would set bit 03 (that could be Intimidate's one)

Now, here it seems that abilities are not given a byte, they are bound to pokemon IDs. But why do you set bits then? How many bytes are you going to need in RAM, in order to store enabled and disabled ability effects?

Wouldn't it make more sense if you read abilities directly from the base data structure content of the involved pokemon, and implementing a pointer table of as many routines as existing abilities? Instead of setting bits in RAM? Assigning a bit fo each ability in RAM would take a relatively large space unless you're going to implement very few abilities (say 8 or 16).
You would have to add a branch in the routine that runs when the battle starts, when pokemon are switched and also on each turn (I don't know much about this "abilities" feature but I understand that they cover quite a large range of situations).

Offline

#3 2012-10-13 18:13:01

Mateo
Member
From: The Sims 4
Registered: 2009-11-25
Post 1,710/3,503

Re: [Theory] Adding abilities to Gen II

Also, don't forget about abilities that do things on the overworld, like Zigzagoon's Pickup ability.

Offline

#4 2012-10-13 18:21:56

stag019
Idea Killer
Registered: 2011-01-05
Post 225/630

Re: [Theory] Adding abilities to Gen II

Or the fact certain Pokemon of the same species can have a different ability than another one.


You can try to hide yourself in this world of pretend; when the paper's crumpled up, it can't be perfect again.

Offline

#5 2012-10-13 18:33:15

Gallego13
Member
Registered: 2011-12-11
Post 65/94

Re: [Theory] Adding abilities to Gen II

Sawakita wrote:

Adding this kind of features is clearly possible; a more relevant question might be how much time and effort would such a thing require.

About the idea itself, it might be just me, but you seem a bit unclear about the concept of bit and byte:

Gallego13 wrote:

each ability would be given a byte, so when the game checks the number, it would be something like: 07, 08 and 09 call bit 01

If each abolity is represented by one byte (thus allowing 0xFF different abilites at most) why would you then use different octet values ("07, 08 and 09...") to have the same effect ("call bit 01")? What do you actually mean here?

Gallego13 wrote:

the battle routine checks Gyarados' number. As it's #130 (82) it would set bit 03 (that could be Intimidate's one)

Now, here it seems that abilities are not given a byte, they are bound to pokemon IDs. But why do you set bits then? How many bytes are you going to need in RAM, in order to store enabled and disabled ability effects?

Wouldn't it make more sense if you read abilities directly from the base data structure content of the involved pokemon, and implementing a pointer table of as many routines as existing abilities? Instead of setting bits in RAM? Assigning a bit fo each ability in RAM would take a relatively large space unless you're going to implement very few abilities (say 8 or 16).
You would have to add a branch in the routine that runs when the battle starts, when pokemon are switched and also on each turn (I don't know much about this "abilities" feature but I understand that they cover quite a large range of situations).

As I said, I don't know very much about this and it's hard for me to explain my ideas :P
What I wanted to say is that it seems doable to make a routine that checks for an ability depending on the pokémon number. I don't know if my “method” was a good one or just nonsense, as it seems now, but the main idea is not bad though (or that's what I think).

Mateo wrote:

Also, don't forget about abilities that do things on the overworld, like Zigzagoon's Pickup ability.

You got me there, that would require some more stuff that I can't even figure how to do.

stag019 wrote:

Or the fact certain Pokemon of the same species can have a different ability than another one.

I already thought about that, that's why I said that each Pokémon would only have one ability, just to make it easier.

Offline

Board footer

Powered by FluxBB