progress
Before Width: | Height: | Size: 414 B After Width: | Height: | Size: 414 B |
Before Width: | Height: | Size: 402 B After Width: | Height: | Size: 402 B |
Before Width: | Height: | Size: 292 B After Width: | Height: | Size: 292 B |
Before Width: | Height: | Size: 313 B After Width: | Height: | Size: 313 B |
Before Width: | Height: | Size: 271 B After Width: | Height: | Size: 271 B |
Before Width: | Height: | Size: 297 B After Width: | Height: | Size: 297 B |
Before Width: | Height: | Size: 411 B After Width: | Height: | Size: 411 B |
Before Width: | Height: | Size: 410 B After Width: | Height: | Size: 410 B |
Before Width: | Height: | Size: 271 B After Width: | Height: | Size: 271 B |
Before Width: | Height: | Size: 303 B After Width: | Height: | Size: 303 B |
Before Width: | Height: | Size: 289 B After Width: | Height: | Size: 289 B |
Before Width: | Height: | Size: 3.6 KiB After Width: | Height: | Size: 3.6 KiB |
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 2.7 KiB |
Before Width: | Height: | Size: 741 KiB After Width: | Height: | Size: 761 KiB |
Before Width: | Height: | Size: 129 KiB After Width: | Height: | Size: 130 KiB |
Before Width: | Height: | Size: 284 KiB After Width: | Height: | Size: 279 KiB |
@ -465,6 +465,10 @@ public class UI implements ApplicationListener, Loadable{
|
||||
}
|
||||
});
|
||||
}
|
||||
dialog.keyDown(KeyCode.enter, () -> {
|
||||
dialog.hide();
|
||||
confirmed.run();
|
||||
});
|
||||
dialog.keyDown(KeyCode.escape, dialog::hide);
|
||||
dialog.keyDown(KeyCode.back, dialog::hide);
|
||||
dialog.show();
|
||||
|
@ -230,6 +230,7 @@ public class BlockRenderer implements Disposable{
|
||||
|
||||
Draw.z(Layer.block);
|
||||
|
||||
if(block != Blocks.air){
|
||||
block.drawBase(tile);
|
||||
|
||||
if(entity != null){
|
||||
@ -249,62 +250,8 @@ public class BlockRenderer implements Disposable{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
public void drawBlocks(Layer stopAt){
|
||||
int startIdx = iterateidx;
|
||||
for(; iterateidx < requestidx; iterateidx++){
|
||||
BlockRequest request = requests.get(iterateidx);
|
||||
|
||||
if(request.layer.ordinal() > stopAt.ordinal()){
|
||||
break;
|
||||
}
|
||||
|
||||
if(request.layer == Layer.power){
|
||||
if(iterateidx - startIdx > 0 && request.tile.pos() == requests.get(iterateidx - 1).tile.pos()){
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
Block block = request.tile.block();
|
||||
boolean isEnd = (request.layer == Layer.block && block.layer == null) || request.layer == block.layer;
|
||||
|
||||
if(request.layer == Layer.block){
|
||||
block.drawBase(request.tile);
|
||||
if(request.tile.entity != null && request.tile.entity.damaged()){
|
||||
request.tile.entity.drawCracks();
|
||||
}
|
||||
if(block.synthetic() && request.tile.entity != null && request.tile.team() != player.team()){
|
||||
request.tile.entity.drawTeam();
|
||||
}
|
||||
|
||||
}else if(request.layer == Layer.lights && request.tile.entity != null){
|
||||
request.tile.entity.drawLight();
|
||||
}else if(request.layer == block.layer){
|
||||
block.drawLayer(request.tile);
|
||||
}else if(request.layer == block.layer2){
|
||||
block.drawLayer2(request.tile);
|
||||
}
|
||||
|
||||
if(isEnd && request.tile.entity != null && displayStatus && block.consumes.any()){
|
||||
request.tile.entity.drawStatus();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void addRequest(Tile tile, Layer layer){
|
||||
if(requestidx >= requests.size){
|
||||
requests.add(new BlockRequest());
|
||||
}
|
||||
BlockRequest r = requests.get(requestidx);
|
||||
if(r == null){
|
||||
requests.set(requestidx, r = new BlockRequest());
|
||||
}
|
||||
r.tile = tile;
|
||||
r.layer = layer;
|
||||
requestidx++;
|
||||
}*/
|
||||
|
||||
@Override
|
||||
public void dispose(){
|
||||
shadows.dispose();
|
||||
|