mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2025-07-12 10:38:34 +00:00
Fix major security bugs (3 brushes + superpickaxe)! (#1213)
* Fix major security bugs (3 brushes + superpickaxe)! - Due to some recent changes, FAWE could edit everything in the world, no matter other plugin protections such as PS or WG. - Fix superpickaxe allow to bypass protections => Fix SurvivalModeExtent not taking into account protections plugins due to breaking blocks naturally to get drops. * Adress requests - Revert some unsuitabe changes - Add FAWE diff comments * Clean imports * Adress requests Co-authored-by: NotMyFault <mc.cache@web.de>
This commit is contained in:
@ -50,6 +50,8 @@ import com.sk89q.worldedit.world.weather.WeatherType;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.nio.file.Path;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.Locale;
|
||||
import java.util.Set;
|
||||
|
||||
@ -218,6 +220,18 @@ public interface World extends Extent, Keyed, IChunkCache<IChunkGet> {
|
||||
*/
|
||||
void simulateBlockMine(BlockVector3 position);
|
||||
|
||||
//FAWE start
|
||||
/**
|
||||
* Return items that may drop by destroying this block.
|
||||
*
|
||||
* @param position the position
|
||||
* @return Block drops
|
||||
*/
|
||||
default Collection<BaseItemStack> getBlockDrops(BlockVector3 position) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
//FAWE end
|
||||
|
||||
/**
|
||||
* Gets whether the given {@link BlockState} can be placed here.
|
||||
*
|
||||
|
Reference in New Issue
Block a user