PlotSquared
PlotSquared copied to clipboard
Allow pistons to break blocks at borders
Overview
Description
Pistons are now able to break blocks when pushing against a plot border or plot area border
Submitter Checklist
- [x] Make sure you are opening from a topic branch (/feature/fix/docs/ branch (right side)) and not your main branch.
- [x] Ensure that the pull request title represents the desired changelog entry.
- [x] New public fields and methods are annotated with
@since TODO. - [x] I read and followed the contribution guidelines.
It does not affect the plot border. Nothing will be pushed outside the plot area as the block is broken when being pushed.
This change fixes the current issue that breakable blocks, in my situation sugarcane, next to the border can not be broken by pistons facing against the border.
It is currently possible to break these blocks using pistons as long as the breakable block is not the last in the row.
Here are previews of the change Current behaviour New behaviour Top Bottom comparison
Just realised where my change has a flaw. Am going on camping vacation so I won't be able to make the changes in the coming 2 weeks but will look at fixing it when I am back home.
But yea I see it would have an issue if the border contains a breakable block
Oops forgot to remove comments
Should be good now
The change looks good now, but justification is needed still. Items dropped on the last block on the plot inevetibly land on the border or road, which possibly leads to unwanted side effects for servers. More feedback is needed.
Yea that is true but wouldn't that be the case either way? I guess, if not working like that already, we can implement so blocks breaking keep their drops inside the plot or outside the area
I like the idea - thanks CommandDan!
The change looks good now, but justification is needed still. Items dropped on the last block on the plot inevetibly land on the border or road, which possibly leads to unwanted side effects for servers. More feedback is needed.
Dropping items will not be the problem, I think. You can use the plot and way flags and the kill-road-items option.
With this change, the behavior of the piston looks more "normal".
Np. And yeah that is what I meant for both points
The change looks good now, but justification is needed still. Items dropped on the last block on the plot inevetibly land on the border or road, which possibly leads to unwanted side effects for servers. More feedback is needed.
What would you want to be done regards to the items?
If anything should be done
The change looks good now, but justification is needed still. Items dropped on the last block on the plot inevetibly land on the border or road, which possibly leads to unwanted side effects for servers. More feedback is needed.
What would you want to be done regards to the items?
If anything should be done
I'd say, if kill-road-items is set to true in the config, kill the item when dropping onto the road / border.
Not sure if the position of the final item can be predicted tbh - could be quite hard.
Otherwise, what might be unsafe, is dropping the item based on the first solid block underneath the piston retraction (Using dropItem instead of dropItemNaturally). Basically, accessing the Blocks from the event, calling getDrops on those and drop these in the middle of the lowest block. But feedback regarding that would be highly appreciated, as that solution isn't the best probably.
Yea, I can add the check for kill-road-items