>>50531932They're handed random IVs and the Hidden Ability. The only thing retained is their moveset, the thing that has *zero* game logic complication.
It also relies on internal storage of the ROM, accessing both game's data on one piece of hardware where it can shuffle things pretty much at-will, something you couldn't do between GBA and GBC because you *have to* go through the Link Cable to transfer any data.
You could do this on the DS, because it has separate ports to actually hold the separate games on one system to completely bypass any communication protocol issues by being able to run arbitrary transformations. Which is *exactly* how they handled gen 3 to gen 4.
For gen 2 to gen 3, the actual releases, you *have to* work with the trading function because that's the only outbound data transfer that gen 2 has, with any alternative requiring a peripheral for the sole purpose of intergenerational compatibility.