Draw crater unto plastanium conveyor icon
And remove whitespaces from the emoji one.
|
After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 7.1 KiB After Width: | Height: | Size: 9.1 KiB |
|
Before Width: | Height: | Size: 763 B After Width: | Height: | Size: 762 B |
|
Before Width: | Height: | Size: 726 KiB After Width: | Height: | Size: 727 KiB |
|
Before Width: | Height: | Size: 895 KiB After Width: | Height: | Size: 894 KiB |
|
Before Width: | Height: | Size: 262 KiB After Width: | Height: | Size: 262 KiB |
@@ -21,8 +21,7 @@ import java.io.*;
|
|||||||
import static mindustry.Vars.*;
|
import static mindustry.Vars.*;
|
||||||
|
|
||||||
public class Track extends Block implements Autotiler{
|
public class Track extends Block implements Autotiler{
|
||||||
private TextureRegion[] regions = new TextureRegion[7];
|
private TextureRegion[] regions = new TextureRegion[8];
|
||||||
private TextureRegion crater;
|
|
||||||
|
|
||||||
public float speed = 0f;
|
public float speed = 0f;
|
||||||
|
|
||||||
@@ -48,8 +47,6 @@ public class Track extends Block implements Autotiler{
|
|||||||
for(int i = 0; i < regions.length; i++){
|
for(int i = 0; i < regions.length; i++){
|
||||||
regions[i] = Core.atlas.find(name + "-" + i + "-" + 0);
|
regions[i] = Core.atlas.find(name + "-" + i + "-" + 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
crater = Core.atlas.find("crater");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -83,7 +80,7 @@ public class Track extends Block implements Autotiler{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TextureRegion[] generateIcons(){
|
public TextureRegion[] generateIcons(){
|
||||||
return new TextureRegion[]{Core.atlas.find(name + "-0-0")};
|
return new TextureRegion[]{Core.atlas.find(name + "-0-0"), Core.atlas.find(name + "-7-0")};
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -157,7 +154,7 @@ public class Track extends Block implements Autotiler{
|
|||||||
float rotation = Mathf.lerp(a, b, Interpolation.linear.apply(1f - Mathf.clamp(entity.reload * 2, 0f, 1f)));
|
float rotation = Mathf.lerp(a, b, Interpolation.linear.apply(1f - Mathf.clamp(entity.reload * 2, 0f, 1f)));
|
||||||
|
|
||||||
// draw crater
|
// draw crater
|
||||||
Draw.rect(crater, Tmp.v1.x, Tmp.v1.y, rotation - 90);
|
Draw.rect(regions[7], Tmp.v1.x, Tmp.v1.y, rotation);
|
||||||
|
|
||||||
// failsafe
|
// failsafe
|
||||||
if(entity.items.first() == null) return;
|
if(entity.items.first() == null) return;
|
||||||
|
|||||||