Jump to content

1.7.10 Custom 1 Block High Door w/ Redstone Powering w/ Double Doors


Lecapria

Recommended Posts

Hello all. I'm trying to make my door only 1 block high. And while I can get it only 1 block high, and I can get it to activate via redstone, and get it to work like double doors, I can't get all of them to work TOGETHER. I either have a 1 block tall door that's kinda buggy, or i have a 2 block high double door that can activate with redstone.

 

        par0World.setBlock(par1, par2, par3, par5Block, par4, 2);

        par0World.setBlock(par1, par2 + 1, par3, par5Block, 8 | (flag2 ? 1 : 0), 2);

        par0World.notifyBlocksOfNeighborChange(par1, par2, par3, par5Block);

        par0World.notifyBlocksOfNeighborChange(par1, par2 + 1, par3, par5Block);

 

Where that "+1" is makes all the difference.. With it, I have a 2 block high door that can be a double door and WORKS with redstone, while without it, i get a single block door that can be a double door that does NOT work with redstone. If I leave out ALL the code from the Item class, I have a 1 block door that CAN work with redstone, but can't be double doors.

 

I need it 1 block high, can be double doors, and can work with redstone... Anyone know a solution?

 

My custom BlockDoor class is almost exactly the same as the vanilla BlockDoor class (the only difference being it doesnt need a block underneath it), and my custom ItemDoor class is exactly the same for the vanilla ItemDoor as well

Link to comment
Share on other sites

Remove that line entirely.

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.

Link to comment
Share on other sites

when i do that it makes it 1 block high, and no double doors

 

You do know what that one line does, right?

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.

Link to comment
Share on other sites

when i do that it makes it 1 block high, and no double doors

 

You do know what that one line does, right?

it places the upper half of the door. it also holds the key to double doors. I thought maybe by lowering the up half of the door down a block, that it would work right but it won't work with redstone when i do that.

Link to comment
Share on other sites

No, actually it doesn't.  All it does is change the block-above to being the top half of a door with the correct metadata.  The next line,

notifyBlocksOfNeighborChange

, is what makes double-doors work.

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.

Link to comment
Share on other sites

No, actually it doesn't.  All it does is change the block-above to being the top half of a door with the correct metadata.  The next line,

notifyBlocksOfNeighborChange

, is what makes double-doors work.

I've tried it several times. when i ixnay that line, its 1 tall, but no double doors
Link to comment
Share on other sites

  • 2 weeks later...

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.