Item sprite cleanup

This commit is contained in:
Anuken 2020-10-24 17:18:58 -04:00
parent 79ace277ed
commit 41d388aa7f
31 changed files with 3 additions and 43 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 265 B

After

Width:  |  Height:  |  Size: 322 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 226 B

After

Width:  |  Height:  |  Size: 319 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 315 B

After

Width:  |  Height:  |  Size: 521 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 242 B

After

Width:  |  Height:  |  Size: 354 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 287 B

After

Width:  |  Height:  |  Size: 420 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 337 B

After

Width:  |  Height:  |  Size: 507 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 334 B

After

Width:  |  Height:  |  Size: 469 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 337 B

After

Width:  |  Height:  |  Size: 481 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 247 B

After

Width:  |  Height:  |  Size: 308 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 269 B

After

Width:  |  Height:  |  Size: 360 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 327 B

After

Width:  |  Height:  |  Size: 386 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 294 B

After

Width:  |  Height:  |  Size: 347 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 315 B

After

Width:  |  Height:  |  Size: 380 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 340 B

After

Width:  |  Height:  |  Size: 539 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 336 B

After

Width:  |  Height:  |  Size: 489 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 312 B

After

Width:  |  Height:  |  Size: 458 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 344 B

After

Width:  |  Height:  |  Size: 527 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 346 B

After

Width:  |  Height:  |  Size: 508 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 328 B

After

Width:  |  Height:  |  Size: 484 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 346 B

After

Width:  |  Height:  |  Size: 519 B

View File

@ -581,7 +581,6 @@ settings.clearcampaignsaves.confirm = Are you sure you want to clear all of your
paused = [accent]< Paused >
clear = Clear
banned = [scarlet]Banned
unplaceable.sectorcaptured = [scarlet]Requires captured sector
yes = Yes
no = No
info.title = Info

Binary file not shown.

Before

Width:  |  Height:  |  Size: 562 KiB

After

Width:  |  Height:  |  Size: 556 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 189 KiB

After

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

After

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 MiB

After

Width:  |  Height:  |  Size: 2.9 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 190 KiB

After

Width:  |  Height:  |  Size: 186 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

After

Width:  |  Height:  |  Size: 1.4 MiB

View File

@ -342,7 +342,7 @@ public class PlacementFragment extends Fragment{
topTable.row();
topTable.table(b -> {
b.image(Icon.cancel).padRight(2).color(Color.scarlet);
b.add(!player.isBuilder() ? "@unit.nobuild" : displayBlock.unplaceableMessage()).width(190f).wrap();
b.add(!player.isBuilder() ? "@unit.nobuild" : "@banned").width(190f).wrap();
b.left();
}).padTop(2).left();
}

View File

@ -191,8 +191,6 @@ public class Block extends UnlockableContent{
public float buildCost;
/** Whether this block is visible and can currently be built. */
public BuildVisibility buildVisibility = BuildVisibility.hidden;
/** Defines when this block can be placed. */
public BuildPlaceability buildPlaceability = BuildPlaceability.always;
/** Multiplier for speed of building this block. */
public float buildCostMultiplier = 1f;
/** Multiplier for cost of research in tech tree. */
@ -521,7 +519,7 @@ public class Block extends UnlockableContent{
}
public boolean isPlaceable(){
return isVisible() && buildPlaceability.placeable() && !state.rules.bannedBlocks.contains(this);
return isVisible() && !state.rules.bannedBlocks.contains(this);
}
/** Called when building of this block begins. */
@ -534,11 +532,6 @@ public class Block extends UnlockableContent{
}
/** @return a message detailing why this block can't be placed. */
public String unplaceableMessage(){
return state.rules.bannedBlocks.contains(this) ? Core.bundle.get("banned") : buildPlaceability.message();
}
public boolean isFloor(){
return this instanceof Floor;
}

View File

@ -1,32 +0,0 @@
package mindustry.world.meta;
import arc.*;
import arc.func.*;
import mindustry.*;
import java.util.*;
/**
* Like BuildVisiblity, but defines whether a block can be *placed*, with an extra message.
* This is like defining a conditionally banned block.
* */
public enum BuildPlaceability{
always(() -> true),
sectorCaptured(() -> Vars.state.rules.sector != null && Vars.state.rules.sector.isCaptured());
private final Boolp placeability;
BuildPlaceability(Boolp placeability){
this.placeability = placeability;
}
public boolean placeable(){
return placeability.get();
}
/** @return why this block is banned. */
public String message(){
return Core.bundle.get("unplaceable." + name().toLowerCase(Locale.ROOT));
}
}

View File

@ -9,7 +9,7 @@ public enum BuildVisibility{
debugOnly(() -> false),
sandboxOnly(() -> Vars.state.rules.infiniteResources),
campaignOnly(() -> Vars.state.isCampaign()),
lightingOnly(() -> Vars.state.rules.lighting),
lightingOnly(() -> Vars.state.rules.lighting || Vars.state.isCampaign()),
ammoOnly(() -> Vars.state.rules.unitAmmo);
private final Boolp visible;