Revert "Attempt to remove unused regions"
This reverts commit 4f5b737f7c
.
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 750 B After Width: | Height: | Size: 751 B |
Before Width: | Height: | Size: 961 KiB After Width: | Height: | Size: 961 KiB |
Before Width: | Height: | Size: 1.1 MiB After Width: | Height: | Size: 1.1 MiB |
Before Width: | Height: | Size: 332 KiB After Width: | Height: | Size: 333 KiB |
@ -10,7 +10,9 @@ import mindustry.type.*;
|
||||
import mindustry.world.*;
|
||||
|
||||
public class CompressedConveyor extends ArmoredConveyor{
|
||||
private TextureRegion[] regions = new TextureRegion[6];
|
||||
protected TextureRegion start;
|
||||
public TextureRegion end;
|
||||
|
||||
protected static int cooldown = 10;
|
||||
|
||||
public CompressedConveyor(String name){
|
||||
@ -21,9 +23,15 @@ public class CompressedConveyor extends ArmoredConveyor{
|
||||
|
||||
@Override
|
||||
public void load(){
|
||||
for(int i = 0; i < regions.length; i++){
|
||||
regions[i] = Core.atlas.find(name + "-" + i);
|
||||
int i;
|
||||
for(i = 0; i < regions.length; i++){
|
||||
for(int j = 0; j < 4; j++){
|
||||
regions[i][j] = Core.atlas.find(name + "-" + i + "-" + 0);
|
||||
}
|
||||
}
|
||||
|
||||
start = Core.atlas.find(name + "-5-0");
|
||||
end = Core.atlas.find(name + "-6-0");
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -31,8 +39,8 @@ public class CompressedConveyor extends ArmoredConveyor{
|
||||
super.draw(tile);
|
||||
|
||||
if(start(tile) && end(tile)) return;
|
||||
if(start(tile)) Draw.rect(regions[5], tile.drawx(), tile.drawy(), tile.rotation() * 90);
|
||||
if( end(tile)) Draw.rect(regions[6], tile.drawx(), tile.drawy(), tile.rotation() * 90);
|
||||
if(start(tile)) Draw.rect(start, tile.drawx(), tile.drawy(), tile.rotation() * 90);
|
||||
if( end(tile)) Draw.rect( end, tile.drawx(), tile.drawy(), tile.rotation() * 90);
|
||||
}
|
||||
|
||||
protected boolean start(Tile tile){
|
||||
|