Merge branch 'master' into crater
# Conflicts: # core/assets/sprites/sprites2.png
This commit is contained in:
@@ -180,6 +180,7 @@ public class Renderer implements ApplicationListener{
|
||||
}
|
||||
|
||||
graphics.clear(clearColor);
|
||||
Draw.reset();
|
||||
|
||||
//TODO 'animated water' is a bad name for this setting
|
||||
if(Core.settings.getBool("animatedwater") || Core.settings.getBool("animatedshields")){
|
||||
@@ -204,7 +205,7 @@ public class Renderer implements ApplicationListener{
|
||||
blocks.floor.endDraw();
|
||||
});
|
||||
|
||||
Draw.drawRange(Layer.blockBuilding, () -> Draw.shader(Shaders.blockbuild, false), Draw::shader);
|
||||
Draw.drawRange(Layer.blockBuilding, () -> Draw.shader(Shaders.blockbuild, true), Draw::shader);
|
||||
|
||||
if(state.rules.lighting){
|
||||
Draw.draw(Layer.light, lights::draw);
|
||||
|
||||
@@ -8,7 +8,6 @@ import arc.graphics.gl.*;
|
||||
import static mindustry.Vars.renderer;
|
||||
|
||||
public enum CacheLayer{
|
||||
//TODO water animation breaks when tar/slag is present
|
||||
water{
|
||||
@Override
|
||||
public void begin(){
|
||||
|
||||
@@ -23,7 +23,7 @@ public class Layer{
|
||||
//things drawn over blocks (intermediate layer)
|
||||
blockOver = 35,
|
||||
|
||||
//blocks currently in progress *shaders used* TODO perhaps put shaders into their own category
|
||||
//blocks currently in progress *shaders used*
|
||||
blockBuilding = 40,
|
||||
|
||||
//ground units
|
||||
|
||||
@@ -135,6 +135,8 @@ public class MinimapRenderer implements Disposable{
|
||||
}
|
||||
|
||||
public void update(Tile tile){
|
||||
if(world.isGenerating()) return;
|
||||
|
||||
int color = colorFor(world.tile(tile.x, tile.y));
|
||||
pixmap.draw(tile.x, pixmap.getHeight() - 1 - tile.y, color);
|
||||
|
||||
|
||||
@@ -169,14 +169,7 @@ public class BuildBlock extends Block{
|
||||
|
||||
@Override
|
||||
public void draw(){
|
||||
//When breaking, don't draw the previous block... since it's the thing you were breaking
|
||||
if(cblock != null && previous == cblock){
|
||||
return;
|
||||
}
|
||||
|
||||
if(previous == null || cblock == null) return;
|
||||
|
||||
if(Core.atlas.isFound(previous.icon(Cicon.full))){
|
||||
if(!(previous == null || cblock == null || previous == cblock) && Core.atlas.isFound(previous.icon(Cicon.full))){
|
||||
Draw.rect(previous.icon(Cicon.full), x, y, previous.rotate ? tile.rotation() * 90 : 0);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user