When I generate the desired bricks via script, some of them you can see, but I don't think they technically exists(it's usually every other one).
Also, you get the overlap error whenever you try planting a brick next to one of them. But you don't get it if you manually plant one of the bricks.
function BlockMiner_createRandomMineable(%pos)
{
if(getRandom(1, 100) <= 85)
{
%mineable = BlockMiner_getCurrLayer(%pos);
%layer = true;
}
else
{
%mineable = BlockMiner_getRandomOre(%pos);
if(%mineable == -1)
{
%mineable = BlockMiner_getCurrLayer(%pos);
%layer = true;
}
}
if(%mineable == -1)
{
echo("\c2BlockMiner_createRandomMineable - Something went very wrong!");
return;
}
if(%layer)
{
%color = $BlockMiner::LayerData[%mineable, "colorID"];
%fx = $BlockMiner::LayerData[%mineable, "colorFX"] == -1 ? 0 : $BlockMiner::LayerData[%mineable, "colorFX"];
%shapeFX = $BlockMiner::LayerData[%mineable, "shapeFX"] == -1 ? 0 : $BlockMiner::LayerData[%mineable, "shapeFX"];
}
else
{
%color = $BlockMiner::OreData[%mineable, "colorID"];
%fx = $BlockMiner::OreData[%mineable, "colorFX"] == -1 ? 0 : $BlockMiner::OreData[%mineable, "colorFX"];
%shapeFX = $BlockMiner::OreData[%mineable, "shapeFX"] == -1 ? 0 : $BlockMiner::OreData[%mineable, "shapeFX"];
}
%brick = new fxDTSBrick()
{
datablock = brickBlockMinerOreData;
position = %pos;
rotation = "0 0 0 0";
colorID = %color;
scale = "1 1 1";
angleID = 0;
colorFxID = %fx;
shapeFxID = %shapeFX;
isPlanted = 1;
isBaseplate = 1;
client = -1;
stackBL_ID = -1;
isMineable = true;
mineable = %mineable;
};
if(%layer)
{
%brick.mineableName = $BlockMiner::LayerData[%mineable, "uiName"];
%brick.health = $BlockMiner::LayerData[%mineable, "health"];
%brick.minLevel = $BlockMiner::LayerData[%mineable, "minLevel"];
%brick.dirtAmount = $BlockMiner::LayerData[%mineable, "dirtAmt"];
}
else
{
%brick.mineableName = $BlockMiner::OreData[%mineable, "uiName"];
%brick.health = $BlockMiner::OreData[%mineable, "health"];
%brick.minLevel = $BlockMiner::OreData[%mineable, "minLevel"];
%brick.value = $BlockMiner::OreData[%mineable, "value"];
%brick.maxVein = $BlockMiner::OreData[%mineable, "maxVein"];
}
%brick.setTrusted(0);
%error = %brick.plant();
echo("ERROR:" SPC %error);
//Brick ERRORS.
//0 = None.
//1 = Overlap.
//2 = Float.
//3 = Stuck.
//5 = Buried.
//Too far doesn't give an error number. Dunno why.
//No idea what error numbers Flood, Limit, Too Loud, or Unstable had.
if(%error != 0 && %error != 2 && %error != 3 && %error != 5)
{
echo("\c2DELETE");
//%brick.schedule(0, delete);
//return -1;
}
if(%layer)
{
%brick.setPrintByName($BlockMiner::LayerData[%mineable, "printUI"]);
%brick.setEmitter($BlockMiner::LayerData[%mineable, "emitter"]);
%brick.setLight($BlockMiner::LayerData[%mineable, "light"]);
}
else
{
%brick.setPrintByName($BlockMiner::OreData[%mineable, "printUI"]);
%brick.setEmitter($BlockMiner::OreData[%mineable, "emitter"]);
%brick.setLight($BlockMiner::OreData[%mineable, "light"]);
}
BrickGroup_888888.add(%brick);
$Server::BrickCount++;
return %brick;
}