Block color pick fix
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 261 B |
@@ -841,6 +841,7 @@ public class Blocks{
|
|||||||
autotile = true;
|
autotile = true;
|
||||||
drawEdgeOut = false;
|
drawEdgeOut = false;
|
||||||
drawEdgeIn = false;
|
drawEdgeIn = false;
|
||||||
|
autotileMidVariants = 2;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
cruxFloor5 = new Floor("crux-floor-5"){{
|
cruxFloor5 = new Floor("crux-floor-5"){{
|
||||||
|
|||||||
@@ -138,10 +138,6 @@ public class PlacementFragment{
|
|||||||
Block tryBlock = build == null ? null : build instanceof ConstructBuild c ? c.current : build.block;
|
Block tryBlock = build == null ? null : build instanceof ConstructBuild c ? c.current : build.block;
|
||||||
Object tryConfig = build == null || !build.block.copyConfig ? null : build.config();
|
Object tryConfig = build == null || !build.block.copyConfig ? null : build.config();
|
||||||
|
|
||||||
if(tryBlock != null && tryBlock.showColorEdit && tryConfig == null){
|
|
||||||
tryConfig = tile.extraData;
|
|
||||||
}
|
|
||||||
|
|
||||||
for(BuildPlan req : player.unit().plans()){
|
for(BuildPlan req : player.unit().plans()){
|
||||||
if(!req.breaking && req.block.bounds(req.x, req.y, Tmp.r1).contains(Core.input.mouseWorld())){
|
if(!req.breaking && req.block.bounds(req.x, req.y, Tmp.r1).contains(Core.input.mouseWorld())){
|
||||||
tryBlock = req.block;
|
tryBlock = req.block;
|
||||||
@@ -157,6 +153,10 @@ public class PlacementFragment{
|
|||||||
tile.floor() != Blocks.air ? tile.floor() : null;
|
tile.floor() != Blocks.air ? tile.floor() : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(tryBlock != null && tryBlock.showColorEdit && tryConfig == null){
|
||||||
|
tryConfig = tile.extraData;
|
||||||
|
}
|
||||||
|
|
||||||
if(tryBlock != null && ((tryBlock.isVisible() && unlocked(tryBlock)) || state.rules.editor)){
|
if(tryBlock != null && ((tryBlock.isVisible() && unlocked(tryBlock)) || state.rules.editor)){
|
||||||
input.block = tryBlock;
|
input.block = tryBlock;
|
||||||
tryBlock.lastConfig = tryConfig;
|
tryBlock.lastConfig = tryConfig;
|
||||||
|
|||||||
Reference in New Issue
Block a user