Posted December 11, 20204 yr I'm trying to figure out how to make a muliblock with gaps. What I'm trying to do is have the base block in the center and then have a gap then a ring of blocks around it. (Similar to nuclearcraft's fusion reactor). For the sake of this post I'm going to say the muliblock pattern is as follows: XAAAB Where X is the base block A is air B is an outside block A second condition I want to have is that there must be air between the center and outside block. Normally I would validate the multiblock when a block is updated and whenever a block is destroyed but if a block is placed in the area that is supposed to be air how would I detect that. Some methods I've thought of so far is - detect normally and once the block is valid check every x ticks to make sure the interior is still air. This would probably cause lag - detect block events and if a block is formed there then destroy the multiblock. The drawback on this would be I'd have to listen to every block events and check if it's contained inside a multiblock and if a mod doesn't trigger a block events when forming or destroying a block then my structure won't update. Would y'all have any ideas on this?
December 11, 20204 yr Check how the torches and blocks like that manages to break according to the neighborhood changes (updatePostPlacement).
December 11, 20204 yr Author 22 minutes ago, poopoodice said: Check how the torches and blocks like that manages to break according to the neighborhood changes (updatePostPlacement). I'd consider this but there would be an issue when a block, that's not a direct neighbor, is updated. For example if we have two blocks that have 3 blocks of air in-between no method will be called on the two blocks if we place a block in the middle air block.
December 12, 20204 yr Every block that is part of your structure should know where in that structure it is, relative to the center, and when it breaks, it should notify the center. https://github.com/Draco18s/ReasonableRealism/blob/1.14.4/src/main/java/com/draco18s/harderores/block/WindvaneBlock.java#L72 Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
December 12, 20204 yr Author 7 minutes ago, Draco18s said: Every block that is part of your structure should know where in that structure it is, relative to the center, and when it breaks, it should notify the center. https://github.com/Draco18s/ReasonableRealism/blob/1.14.4/src/main/java/com/draco18s/harderores/block/WindvaneBlock.java#L72 The issue is that the structure requires air blocks. Every part of the block that is in the structure is aware, except because I don't control air blocks I can't have air blocks notify the center when they are replaced.
December 12, 20204 yr Create your own invisible, replacable, isAir block that gets placed in the air spaces. Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
December 12, 20204 yr Author 4 minutes ago, Draco18s said: Create your own invisible, replacable, isAir block that gets placed in the air spaces. That's a great idea!
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.