For a long time I've had this idea for what I assumed would be a very basic starter mod, but one I hadn't seen anyone create. Once I got Eclipse set up and started digging, I found out it may be harder than I thought. However, I still think it will be a worthwhile mod to pursue. I have more experience in Python, but I'm able to read and muddle through in Java.
I'm looking for a way to create an interaction between any spawner and a vanilla hopper without creating a full-fledged replacement for either. Ideally, it would work on modded spawners too. If someone could point me in the right direction, I'd really appreciate it.
The trouble I'm running into is that neither has a Forge event that I can find. diesieben07 wrote a pull request for adding a 'MobSpawnerSpawn' event, but it was rejected. If I were editing Minecraft core, I'd just modify the tick() methods. If it were Python, I'd just replace the 'tick' method with my own code at runtime.
I'm going to dig in to see if there is a place I can inject a simple replacement class, but I'm not optimistic. I may need to take a step back and look at an easier starting place for my modding debut.
EDIT: I'm thinking it might be possible to tweak net.minecraft.world.spawner.AbstractSpawner to suit and then replace spawnerLogic in net.minecraft.tileentity.MobSpawnerTileEntity? I'm not sure how that is instantiated yet.