mirror of
https://github.com/ClassiCube/MCGalaxy.git
synced 2025-09-22 03:55:18 -04:00
Make /draw draw over all blocks, not only non-air.
If you want the old behaviour, just do /brush replace /draw mode [radius] <height> air to get it.
This commit is contained in:
parent
cb4c1b5c00
commit
a77a264b37
@ -49,9 +49,8 @@ namespace MCGalaxy.Drawing.Ops {
|
||||
|
||||
double curRadius = Radius * ((double)curHeight / (double)height);
|
||||
int dist = xx * xx + zz * zz;
|
||||
if (dist > curRadius * curRadius) continue;
|
||||
|
||||
if (Level.IsAirAt(x, y, z)) output(Place(x, y, z, brush));
|
||||
if (dist > curRadius * curRadius) continue;
|
||||
output(Place(x, y, z, brush));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -82,10 +81,8 @@ namespace MCGalaxy.Drawing.Ops {
|
||||
|
||||
double curRadius = Radius * ((double)curHeight / (double)height);
|
||||
int dist = xx * xx + zz * zz;
|
||||
if (dist > curRadius * curRadius || dist < (curRadius - 1) * (curRadius - 1))
|
||||
continue;
|
||||
|
||||
if (Level.IsAirAt(x, y, z)) output(Place(x, y, z, brush));
|
||||
if (dist > curRadius * curRadius || dist < (curRadius - 1) * (curRadius - 1)) continue;
|
||||
output(Place(x, y, z, brush));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -115,7 +112,6 @@ namespace MCGalaxy.Drawing.Ops {
|
||||
double curRadius = Radius * ((double)curHeight / (double)height);
|
||||
int dist = xx * xx + zz * zz;
|
||||
if (dist > curRadius * curRadius) continue;
|
||||
if (!Level.IsAirAt(x, y, z)) continue;
|
||||
|
||||
bool layer = dist >= (curRadius - 1) * (curRadius - 1);
|
||||
block.BlockID = layer ? Block.Grass : Block.StillLava;
|
||||
|
@ -48,9 +48,8 @@ namespace MCGalaxy.Drawing.Ops {
|
||||
if (curHeight == 0) continue;
|
||||
|
||||
double curRadius = Radius * ((double)curHeight / (double)height);
|
||||
if (Math.Abs(xx) > curRadius || Math.Abs(zz) > curRadius) continue;
|
||||
|
||||
if (Level.IsAirAt(x, y, z)) output(Place(x, y, z, brush));
|
||||
if (Math.Abs(xx) > curRadius || Math.Abs(zz) > curRadius) continue;
|
||||
output(Place(x, y, z, brush));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -83,8 +82,7 @@ namespace MCGalaxy.Drawing.Ops {
|
||||
int absx = Math.Abs(xx), absz = Math.Abs(zz);
|
||||
if (absx > curRadius || absz > curRadius) continue;
|
||||
if (absx < (curRadius - 1) && absz < (curRadius - 1)) continue;
|
||||
|
||||
if (Level.IsAirAt(x, y, z)) output(Place(x, y, z, brush));
|
||||
output(Place(x, y, z, brush));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user