Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement BlockPistonRetractEvent #1014

Merged
merged 1 commit into from
Feb 5, 2019
Merged

Implement BlockPistonRetractEvent #1014

merged 1 commit into from
Feb 5, 2019

Conversation

Red-Teapot
Copy link
Contributor

Addresses #922

Although I have a couple of questions.

BlockPistonRetractEvent.java, lines 23-24:

     * Get an immutable list of the blocks which will be moved by the
     * extending.

Should there be 'retracting' instead of 'extending'?

Is the list of moved blocks as the event parameter needed at all? Isn't just one block enough? Pistons can't move more than one block when retracting anyways.

@mastercoms
Copy link
Member

Hi, I believe the comment should be retracting!

Also, slime blocks allow pistons to pull multiple blocks:

When a slime block is pushed or pulled by a piston it will attempt to move, in the same direction, all adjacent blocks.

https://minecraft.gamepedia.com/Slime_Block#Pistons

@Red-Teapot
Copy link
Contributor Author

Forgot about slime blocks, thanks. Although it seems like slime blocks are not pushed properly yet. Maybe I'll try to implement slime pushing then but I'm not sure if I can do that.

@mastercoms
Copy link
Member

You don't have to, would be out of the scope of this PR currently. Just wanted to let you know why the list exists 😉

But it's your choice if you want to include that functionality, I'm happy to accept it as part of this PR.

@Red-Teapot
Copy link
Contributor Author

I can't fix the comment since it's in Glowkit.

I think I'll create a separate PR when/if I implement slime pushing so it would be named properly and won't hang here.

@mastercoms mastercoms merged commit 7951f06 into GlowstoneMC:dev Feb 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants