Ask help for making MultiBlock machine

Hello! I’m now trying to make a mod to add something to complete my industrial crafting lines,in order to add more new thing to the modpack TerrafirmaRescue
I’ve successfully registered “examplium” by using your gregapi.api.example.Example_Mod, but I’m stupid to find the things related to MultiBlock machine like “bedrock miner” or “Large XXXXX”
So i come to there to ask help for making some custom large machines in my external mod.

I actually trying to remove GT6U in that modpack and revert to use GT6 because GT6U (and the modpack itself) is actually not update for a long time.But the author added many multiblock machines by editing the GT6 mod itself and I don’t want to do that.

thanks a lot for you help!

3 Likes

So first of all do you know how to make your own MultiTileEntityRegistry and add things to it? That one is quite important to know beforehand. ^^

1 Like

hmm I already read all the codes in Example_Mod.java, so I think I knows that.

2 Likes

You should look at gregtech.tileentity.multiblocks and at gregtech.loaders.b.Loader_MultiTileEntities for seeing how I use it myself.

I would also recommend looking at GT6U for how to arrange the individual Blocks in World.

3 Likes

ok thanks a lot and I will look those thing.

3 Likes

be wary of the !!!LOUD BEEPING NOISE!!! that happens when you code your multis incorrectly…

sure scared me when it first happened xD

2 Likes

Wait WHAT? Why would it beep?!

Edit: Oh I see what you meant, yeah any CRASH will result in the Beeping Noise and the Block turning into an Error Message.

1 Like


meanwhile my adventures forking AbyssalCraft to port the newer Shoggoth models have proved… adventurous

4 Likes

image

the full GIT experience in just one image

4 Likes

that and “i’ve run out of funny quips to make in my commits”
i swear i’ve seen releases on the NTM github almost like that…

4 Likes

something about the garish flashing texture and shrill burglar alarm like noise really scared the hell out of me when i first tried to port GT6u multiblocks into GT6 official xD

EDIT: i’d suggest for you to turn down the volume for the broken tile entities, Greg, but that would negate the entire point wouldn’t it?

2 Likes

:eyes: Shogussy
:brain: activation

2 Likes

Well,I… try to add a test machine based on Large Bath Vet, I try to copy the gregtech.tileentity.multiblocks.MultiTileEntityBath and made a MultiBlockMachine Loader similar to your Loader_MultiTileEntity

My mod isn’t cause game to crash, But I just found nothing about my test machine…When try to build the testMachine, I just found pipes can’t connect to it at all, and it seems failed to build it.

Is there something I did was wrong…?

Edit:I forgot to paste the source file: GitHub - kuzuanpa/kTFRUaddon

2 Likes

Considering you’re making a fork of terrafirmarescue, woulkdn’t it be easier to join the terrafirmarescue discord and ask them directly how they implemented their changes in GT6U? They already speak chinese to begin with, so it’d be easier to explain the issues and problems you’re experiencing and find a solution.

2 Likes

Well It’s may be a good idea but TFR authors has modify the GT6 itself to add some machine other than make some addon mod.I think my problem cannot be resolved by asking them because we are working on different ways.
I guess there is something wrong when registering my machine to gregapi or forgeAPI, the class containing my machine seems all right,maybe.

2 Likes

You created a Multiblock Part, but I dont see any Controller Block in there. The Part Blocks do not connect to ANYTHING until a Controller tells them they can.

2 Likes

Thanks a lot!I’ve just sucessfully registered my MultiBlock machine. :smile_cat:

2 Likes

hmm I come back again :smile_cat:
We all know that controller block needs to check blocks around it to know if the MultiBlock machine has been finished build.
so these code:
if (!ITileEntityMultiBlockController.Util.checkAndSetTarget(this, tX, tY, tZ, 12000, getMultiTileEntityRegistryID(), 0, MultiTileEntityMultiBlockPart.ONLY_ITEM_FLUID))
tSuccess = F;
It’s useful in GT6 and GT6U,but when things comes to addon,I don’t know how to give it a correct “MultiTileEntityRegistryID” to make it detect something in the Gregtech registry instead of mine.

the getMultiTileEntityRegistryID() method seems can only return the RegistryID where the controller block itself was in, I don’t want every block to build machine needs to registered in my mod.

2 Likes

ST.id(gregtechregistry.mBlock) will give you the MTE Registry ID, yes it is literally the Item ID. Don’t forget Item IDs change whenever you load a World, so you cant just store it as a static variable. :wink:

2 Likes

Load a world, join a server, maybe even some other times. Don’t cache the ID’s, lol.

1 Like