Mekanism

Mekanism

111M Downloads

Legacy compatibility in your v8 API IGasHandler for v7

radfast opened this issue ยท 6 comments

commented

ISSUE CLOSED, my bad, see below. Sorry to trouble you.

If you don't then we get crashes: please see: micdoodle8/Galacticraft#1509

And if we update Galacticraft to use the v8 API then it will lose compatibility with v7, but maybe half of our players are still playing Galacticraft with Mekanism v7, or in a modpack locked to that version of Mekanism... Hope you see that Galacticraft having compatibility with either v7 or v8 is a desirable situation.

This could easily be solved if IGasHandler can still include public int receiveGas(ForgeDirection side, GasStack stack); and all implementing tiles simply contain:

public int receiveGas(ForgeDirection side, GasStack stack)
{
this.receiveGas(side, stack, true)
}

If you can't do that I guess we would need a super complicated reflection solution which will be a nightmare to code.

commented

See also #2265, sorry I only just noticed SportFan posted the same issue here and on our issues list.

commented

Same request also for drawGas obviously.

commented

oops. I think maybe we have been using a 7 month out of date version of your API and nobody realized before. please ignore this, we'll update to your latest API. I'm sorry, I had the impression because of what SportsFan reported that this was a new issue only arising in your new v8.

commented

You may have been right, actually. This release has been in the works for a long time, even if the commit is 6 months old it still may have only been merged into master today. If that is the case I'll definitely do what I can to ensure backwards-compatibility.

commented

oh hey, thanks - I don't feel so bad then.

Legacy support for public int receiveGas(ForgeDirection side, GasStack stack) would be great in that case. drawGas is not so important to me as we don't use it in Galacticraft but I guess another mod might?