What happens if a pokeball is destroyed having a pokemon inside?
I imagine the Pokémon would simply pop out. There is one episode, Pokémon Food Fight, in which Ash breaks his Snorlax’s Pokéball by dropping it on a rock – the ball isn’t destroyed, but it does stop working. Snorlax immediately comes out. In general Pokémon seem to maintain some degree of awareness while inside a Pokéball and can emerge on their own if they particularly want to, so I suspect that, whatever weird energy state they’re in while inside a ball, it’s not particularly stable, and has to be maintained by the ball’s mechanisms to keep them from just immediately returning to physical form.