Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prepare MCAccessBukkitModern (1.13).
- Loading branch information
Showing
6 changed files
with
94 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
...Bukkit/src/main/java/fr/neatmonster/nocheatplus/compat/bukkit/BlockCacheBukkitModern.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package fr.neatmonster.nocheatplus.compat.bukkit; | ||
|
||
import org.bukkit.World; | ||
|
||
/** | ||
* BlockCache for MCAccessBukkitModern. | ||
* | ||
* @author asofold | ||
* | ||
*/ | ||
public class BlockCacheBukkitModern extends BlockCacheBukkit { | ||
|
||
public BlockCacheBukkitModern(World world) { | ||
super(world); | ||
} | ||
|
||
@Override | ||
public int fetchData(int x, int y, int z) { | ||
// TODO: Might fake here too. | ||
return super.fetchData(x, y, z); | ||
} | ||
|
||
@Override | ||
public double[] fetchBounds(int x, int y, int z) { | ||
// TODO: Fetch what's possible to fetch/guess (...). | ||
return super.fetchBounds(x, y, z); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
...atBukkit/src/main/java/fr/neatmonster/nocheatplus/compat/bukkit/MCAccessBukkitModern.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package fr.neatmonster.nocheatplus.compat.bukkit; | ||
|
||
import fr.neatmonster.nocheatplus.config.WorldConfigProvider; | ||
import fr.neatmonster.nocheatplus.utilities.map.BlockCache; | ||
|
||
public class MCAccessBukkitModern extends MCAccessBukkit { | ||
|
||
public MCAccessBukkitModern() { | ||
super(); | ||
} | ||
@Override | ||
public String getMCVersion() { | ||
return "1.13|?"; | ||
} | ||
|
||
@Override | ||
public BlockCache getBlockCache() { | ||
return new BlockCacheBukkitModern(null); | ||
} | ||
|
||
@Override | ||
public void setupBlockProperties(final WorldConfigProvider<?> worldConfigProvider) { | ||
|
||
// TODO: Initialize some blocks and add to this.processedBlocks. | ||
|
||
super.setupBlockProperties(worldConfigProvider); | ||
} | ||
|
||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters