improve builder logic, push en_US.lang
This commit is contained in:
parent
66002611b3
commit
75815174a9
|
@ -546,6 +546,9 @@ bc_update.download=§cDownload from http://www.mod-buildcraft.com/download
|
|||
bc_update.once=This message only displays once
|
||||
bc_update.again=Type '/buildcraft version' if you want to see it again
|
||||
|
||||
chat.buildcraft.quarry.tooSmall=[BuildCraft] Quarry size is outside of chunkloading bounds or too small %d %d (%d)
|
||||
chat.buildcraft.quarry.chunkloadInfo=[BuildCraft] The quarry at %d %d %d will keep %d chunks loaded
|
||||
|
||||
command.buildcraft.version=BuildCraft %s for Minecraft %s (Latest: %s).
|
||||
command.buildcraft.changelog_header=Changelog for BuildCraft %s:
|
||||
|
||||
|
|
|
@ -11,7 +11,6 @@ package buildcraft.builders.schematics;
|
|||
import java.util.LinkedList;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import buildcraft.api.blueprints.IBuilderContext;
|
||||
import buildcraft.api.blueprints.SchematicBlock;
|
||||
|
@ -52,11 +51,6 @@ public class SchematicRail extends SchematicBlock {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canPlaceInWorld(IBuilderContext context, int x, int y, int z) {
|
||||
return y > 0 && World.doesBlockHaveSolidTopSurface(context.world(), x, y - 1, z);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void placeInWorld(IBuilderContext context, int x, int y, int z, LinkedList<ItemStack> stacks) {
|
||||
context.world().setBlock(x, y, z, block, 0, 3);
|
||||
|
|
|
@ -11,6 +11,7 @@ import buildcraft.api.blueprints.IBuilderContext;
|
|||
public class BuilderItemMetaPair {
|
||||
public Item item;
|
||||
public int meta;
|
||||
public int position = 0;
|
||||
|
||||
public BuilderItemMetaPair(ItemStack stack) {
|
||||
if (stack != null) {
|
||||
|
|
|
@ -19,7 +19,7 @@ import net.minecraft.world.WorldSettings;
|
|||
import buildcraft.core.lib.fluids.Tank;
|
||||
|
||||
public class BuildingSlotMapIterator {
|
||||
private static final int MAX_PER_ITEM = 80;
|
||||
private static final int MAX_PER_ITEM = 64;
|
||||
private final Map<BuilderItemMetaPair, List<BuildingSlotBlock>> slots;
|
||||
private final Set<BuilderItemMetaPair> availablePairs = new HashSet<BuilderItemMetaPair>();
|
||||
private final int[] buildStageOccurences;
|
||||
|
@ -67,6 +67,7 @@ public class BuildingSlotMapIterator {
|
|||
pair = impIterator.next();
|
||||
if (isCreative || availablePairs.contains(pair)) {
|
||||
current = slots.get(pair);
|
||||
position = pair.position;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -84,6 +85,11 @@ public class BuildingSlotMapIterator {
|
|||
}
|
||||
position++;
|
||||
}
|
||||
if (returnsThisCurrent >= MAX_PER_ITEM) {
|
||||
pair.position = position;
|
||||
} else if (position >= current.size()) {
|
||||
pair.position = 0;
|
||||
}
|
||||
findNewCurrent();
|
||||
}
|
||||
return null;
|
||||
|
|
Loading…
Reference in a new issue