Revert "Added support for command blocks in Nukkit."

This reverts commit ba9aff2a8a.
This commit is contained in:
Dominik Renzel 2019-09-22 23:19:42 +02:00
parent d3cc84c026
commit a3cb8af95d
6 changed files with 893 additions and 902 deletions

View File

@ -152,9 +152,6 @@ public class FaweCache {
int id = i >> 4; int id = i >> 4;
int data = i & 0xf; int data = i & 0xf;
if (FaweCache.hasNBT(id)) { if (FaweCache.hasNBT(id)) {
if (id == 137 || id == 188 || id == 189){
System.out.println("Has NBT: " + id + " Data: " + data);
}
CACHE_BLOCK[i] = new ImmutableNBTBlock(id, data); CACHE_BLOCK[i] = new ImmutableNBTBlock(id, data);
} else if (FaweCache.hasData(id)) { } else if (FaweCache.hasData(id)) {
CACHE_BLOCK[i] = new ImmutableBlock(id, data); CACHE_BLOCK[i] = new ImmutableBlock(id, data);
@ -547,6 +544,8 @@ public class FaweCache {
case 185: case 185:
case 186: case 186:
case 187: case 187:
case 188:
case 189:
case 190: case 190:
case 191: case 191:
case 192: case 192:
@ -659,8 +658,6 @@ public class FaweCache {
case 142: case 142:
case 27: case 27:
case 137: case 137:
case 188:
case 189:
case 52: case 52:
case 154: case 154:
case 84: case 84:
@ -865,6 +862,8 @@ public class FaweCache {
case 185: case 185:
case 186: case 186:
case 187: case 187:
case 188:
case 189:
case 190: case 190:
case 191: case 191:
case 192: case 192:

View File

@ -315,6 +315,8 @@ public abstract class CharFaweChunk<T, V extends FaweQueue> extends FaweChunk<T>
case 172: case 172:
case 173: case 173:
case 174: case 174:
case 188:
case 189:
case 190: case 190:
case 191: case 191:
case 192: case 192:
@ -328,9 +330,6 @@ public abstract class CharFaweChunk<T, V extends FaweQueue> extends FaweChunk<T>
case 10: case 10:
case 54: case 54:
case 146: case 146:
case 137:
case 188:
case 189:
case 61: case 61:
case 65: case 65:
case 68: // removed case 68: // removed

View File

@ -137,7 +137,9 @@ public abstract class FaweChunk<T> implements Callable<FaweChunk> {
* @param layer * @param layer
* @return char[] or null * @return char[] or null
*/ */
public @Nullable char[] getIdArray(int layer) { public
@Nullable
char[] getIdArray(int layer) {
char[] ids = new char[4096]; char[] ids = new char[4096];
int by = layer << 4; int by = layer << 4;
int index = 0; int index = 0;
@ -297,7 +299,8 @@ public abstract class FaweChunk<T> implements Callable<FaweChunk> {
* *
* @return * @return
* @see com.boydti.fawe.util.MathMan#unpair16x (get0) => x * @see com.boydti.fawe.util.MathMan#unpair16x (get0) => x
* @see com.boydti.fawe.util.MathMan#unpair16y (get0) => z get1 => y * @see com.boydti.fawe.util.MathMan#unpair16y (get0) => z
* get1 => y
*/ */
public abstract Map<Short, CompoundTag> getTiles(); public abstract Map<Short, CompoundTag> getTiles();

View File

@ -1,8 +1,5 @@
package com.boydti.fawe.object.extent; package com.boydti.fawe.object.extent;
import java.util.List;
import java.util.Map;
import com.boydti.fawe.FaweCache; import com.boydti.fawe.FaweCache;
import com.boydti.fawe.object.FaweQueue; import com.boydti.fawe.object.FaweQueue;
import com.boydti.fawe.object.HasFaweQueue; import com.boydti.fawe.object.HasFaweQueue;
@ -24,6 +21,8 @@ import com.sk89q.worldedit.regions.Region;
import com.sk89q.worldedit.util.Location; import com.sk89q.worldedit.util.Location;
import com.sk89q.worldedit.world.World; import com.sk89q.worldedit.world.World;
import com.sk89q.worldedit.world.biome.BaseBiome; import com.sk89q.worldedit.world.biome.BaseBiome;
import java.util.List;
import java.util.Map;
public class FastWorldEditExtent extends AbstractDelegateExtent implements HasFaweQueue { public class FastWorldEditExtent extends AbstractDelegateExtent implements HasFaweQueue {
@ -38,7 +37,6 @@ public class FastWorldEditExtent extends AbstractDelegateExtent implements HasFa
this.maxY = world.getMaxY(); this.maxY = world.getMaxY();
} }
@Override
public FaweQueue getQueue() { public FaweQueue getQueue() {
return queue; return queue;
} }
@ -225,6 +223,8 @@ public class FastWorldEditExtent extends AbstractDelegateExtent implements HasFa
case 172: case 172:
case 173: case 173:
case 174: case 174:
case 188:
case 189:
case 190: case 190:
case 191: case 191:
case 192: case 192:
@ -376,8 +376,6 @@ public class FastWorldEditExtent extends AbstractDelegateExtent implements HasFa
case 142: case 142:
case 27: case 27:
case 137: case 137:
case 188:
case 189:
case 52: case 52:
case 154: case 154:
case 84: case 84:
@ -426,7 +424,6 @@ public class FastWorldEditExtent extends AbstractDelegateExtent implements HasFa
case 233: case 233:
case 234: case 234:
default: { default: {
CompoundTag nbt = block.getNbtData(); CompoundTag nbt = block.getNbtData();
if (nbt != null) { if (nbt != null) {
return queue.setBlock(x, y, z, id, block.getData(), nbt); return queue.setBlock(x, y, z, id, block.getData(), nbt);

View File

@ -214,8 +214,6 @@ public class CuboidClipboard {
case 142: case 142:
case 27: case 27:
case 137: case 137:
case 188:
case 189:
case 52: case 52:
case 154: case 154:
case 84: case 84:
@ -345,6 +343,8 @@ public class CuboidClipboard {
case 172: case 172:
case 173: case 173:
case 174: case 174:
case 188:
case 189:
case 190: case 190:
case 191: case 191:
case 192: { case 192: {

View File

@ -98,13 +98,6 @@ public class BundledBlockData {
List<BlockEntry> entries = gson.fromJson(data, new TypeToken<List<BlockEntry>>() { List<BlockEntry> entries = gson.fromJson(data, new TypeToken<List<BlockEntry>>() {
}.getType()); }.getType());
for (BlockEntry entry : entries) { for (BlockEntry entry : entries) {
if (entry.legacyId == 210){
entry.legacyId = 188;
} else if (entry.legacyId == 211){
entry.legacyId = 189;
}
System.out.println("BundledBlockData::Adding block entry: " + entry.id + " (" + entry.legacyId + ")");
add(entry, overwrite); add(entry, overwrite);
} }
} }