Skip to content

Commit

Permalink
fix#2
Browse files Browse the repository at this point in the history
  • Loading branch information
Twcash committed Feb 25, 2025
1 parent 8214fc4 commit 9628f47
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
8 changes: 8 additions & 0 deletions core/src/mindustry/content/Blocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -1527,23 +1527,31 @@ public static void load(){
requirements(Category.defense, with(Items.copper, 6));
health = 80 * wallHealthMultiplier;
researchCostMultiplier = 0.1f;
breakable = true;
destructible = false;
}};

copperWallLarge = new Wall("copper-wall-large"){{
requirements(Category.defense, ItemStack.mult(copperWall.requirements, 4));
health = 80 * 4 * wallHealthMultiplier;
size = 2;
breakable = false;
destructible = true;
}};

titaniumWall = new Wall("titanium-wall"){{
requirements(Category.defense, with(Items.titanium, 6));
health = 110 * wallHealthMultiplier;
breakable = false;
destructible = false;
}};

titaniumWallLarge = new Wall("titanium-wall-large"){{
requirements(Category.defense, ItemStack.mult(titaniumWall.requirements, 4));
health = 110 * wallHealthMultiplier * 4;
size = 2;
breakable = true;
destructible = true;
}};

plastaniumWall = new Wall("plastanium-wall"){{
Expand Down
2 changes: 1 addition & 1 deletion core/src/mindustry/world/Block.java
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public class Block extends UnlockableContent implements Senseable{
/** for static blocks only: if true, tile data() is saved in world data. */
public boolean saveData;
/** whether you can break this with rightclick */
public boolean breakable;
public boolean breakable = true;
/** if true, this block will be broken by certain units stepping/moving over it */
public boolean unitMoveBreakable;
/** whether to add this block to brokenblocks */
Expand Down
4 changes: 2 additions & 2 deletions core/src/mindustry/world/Tile.java
Original file line number Diff line number Diff line change
Expand Up @@ -421,15 +421,15 @@ public boolean passable(){

/** Whether this block was placed by a player/unit. */
public boolean synthetic(){
return block.update || block.breakable || block.destructible;
return block.update || block.destructible || block.breakable;
}

public boolean solid(){
return block.solid || floor.solid || (build != null && build.checkSolid());
}

public boolean breakable(){
return block.breakable || block.update;
return block.breakable;
}

/** @return whether the floor on this tile deals damage or can be drowned on. */
Expand Down

0 comments on commit 9628f47

Please sign in to comment.