More changes
This commit is contained in:
@@ -113,7 +113,7 @@ public class CraftingManager
|
|||||||
{
|
{
|
||||||
GameRegistry.addRecipe(new ItemStack(mod_pocketDim.itemGoldDimDoor,1), new Object[]
|
GameRegistry.addRecipe(new ItemStack(mod_pocketDim.itemGoldDimDoor,1), new Object[]
|
||||||
{
|
{
|
||||||
" x ", " y ", " x ", 'x', mod_pocketDim.itemGoldDoor, 'y', Item.eyeOfEnder
|
" ", "xyx", " ", 'x', mod_pocketDim.itemGoldDoor, 'y', Item.eyeOfEnder
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
if (properties.CraftingGoldDoorAllowed)
|
if (properties.CraftingGoldDoorAllowed)
|
||||||
|
|||||||
@@ -379,7 +379,9 @@ public class Schematic {
|
|||||||
for (dx = 0; dx < width; dx++)
|
for (dx = 0; dx < width; dx++)
|
||||||
{
|
{
|
||||||
//In the future, we might want to make this more efficient by building whole chunks at a time
|
//In the future, we might want to make this more efficient by building whole chunks at a time
|
||||||
if(blocks[index]!=0)
|
//Ignore air blocks
|
||||||
|
//TODO
|
||||||
|
//if(blocks[index]!=0)
|
||||||
{
|
{
|
||||||
setBlockDirectly(world, x + dx, y + dy, z + dz, blocks[index], metadata[index]);
|
setBlockDirectly(world, x + dx, y + dy, z + dz, blocks[index], metadata[index]);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -299,12 +299,20 @@ public class TileEntityRift extends TileEntity
|
|||||||
|
|
||||||
public void grow(DDProperties properties)
|
public void grow(DDProperties properties)
|
||||||
{
|
{
|
||||||
if (worldObj.isRemote || hasGrownRifts || !properties.RiftSpreadEnabled || random.nextInt(3) == 0)
|
if (worldObj.isRemote || hasGrownRifts || !properties.RiftSpreadEnabled || random.nextInt(5) == 0)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
NewDimData dimension = PocketManager.getDimensionData(worldObj);
|
NewDimData dimension = PocketManager.getDimensionData(worldObj);
|
||||||
|
|
||||||
|
if(random.nextInt(dimension.findRiftsInRange(this.worldObj, 5, xCoord, yCoord, zCoord).size()+1)<2)
|
||||||
|
{
|
||||||
|
if(random.nextInt(7)!=0)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
DimLink link = dimension.getLink(xCoord, yCoord, zCoord);
|
DimLink link = dimension.getLink(xCoord, yCoord, zCoord);
|
||||||
|
|
||||||
if (countAncestorLinks(link) > MAX_ANCESTOR_LINKS)
|
if (countAncestorLinks(link) > MAX_ANCESTOR_LINKS)
|
||||||
@@ -335,6 +343,7 @@ public class TileEntityRift extends TileEntity
|
|||||||
{
|
{
|
||||||
dimension.createChildLink(x, y, z, link);
|
dimension.createChildLink(x, y, z, link);
|
||||||
hasGrownRifts = true;
|
hasGrownRifts = true;
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -51,7 +51,9 @@ public abstract class BaseGateway
|
|||||||
* but it doesnt work. It seems like it should, though. Odd.
|
* but it doesnt work. It seems like it should, though. Odd.
|
||||||
*
|
*
|
||||||
* The other issue is with the .schematic itself. It looks like we are exporting quite a few air blocks with the real blocks.
|
* The other issue is with the .schematic itself. It looks like we are exporting quite a few air blocks with the real blocks.
|
||||||
* This may be a limitation of our export function, as it wasnt really meant for this. I added a line in the generate function to skip air blocks completely.
|
* This may be a limitation of our export function, as it wasnt really meant for this.
|
||||||
|
*
|
||||||
|
* I added a line in the generate function to skip air blocks completely, but commented it out so you can see it carrying air blocks along. Its in schematic.copyToWorld
|
||||||
* Should also speed up generation time.
|
* Should also speed up generation time.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
@@ -65,11 +67,11 @@ public abstract class BaseGateway
|
|||||||
schematic.applyFilter(filter);
|
schematic.applyFilter(filter);
|
||||||
doorLocation = filter.getEntranceDoorLocation();
|
doorLocation = filter.getEntranceDoorLocation();
|
||||||
orientation = filter.getEntranceOrientation();
|
orientation = filter.getEntranceOrientation();
|
||||||
schematic.copyToWorld(world, x-doorLocation.getX(), y-doorLocation.getY(), z-doorLocation.getZ());
|
schematic.copyToWorld(world, x-schematic.getWidth()+doorLocation.getX(), y-schematic.getHeight()+doorLocation.getY(), z-schematic.getLength()+doorLocation.getZ());
|
||||||
|
|
||||||
for(int c = 0; c<240; c++)
|
for(int c = 0; c<240; c++)
|
||||||
{
|
{
|
||||||
world.setBlock(x-doorLocation.getX(), y-doorLocation.getY()+c, z-doorLocation.getZ(),Block.glowStone.blockID);
|
world.setBlock(x, y+c, z,Block.glowStone.blockID);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user