mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-02-22 04:28:27 +07:00
Cleanup
This commit is contained in:
parent
542555d721
commit
047652154e
@ -119,8 +119,12 @@ public abstract class ClientLauncher extends ApplicationCore implements Platform
|
||||
@Override
|
||||
public void update(){
|
||||
if(!finished){
|
||||
loader.draw();
|
||||
if(loader != null){
|
||||
loader.draw();
|
||||
}
|
||||
if(assets.update(1000 / loadingFPS)){
|
||||
loader.dispose();
|
||||
loader = null;
|
||||
Log.info("Total time to load: @", Time.timeSinceMillis(beginTime));
|
||||
for(ApplicationListener listener : modules){
|
||||
listener.init();
|
||||
|
@ -21,7 +21,7 @@ import mindustry.graphics.g3d.*;
|
||||
|
||||
import static arc.Core.*;
|
||||
|
||||
public class LoadRenderer{
|
||||
public class LoadRenderer implements Disposable{
|
||||
private static final Color color = new Color(Pal.accent).lerp(Color.black, 0.5f);
|
||||
private static final Color colorRed = Pal.breakInvalid.lerp(Color.black, 0.3f);
|
||||
private static final String red = "[#" + colorRed + "]";
|
||||
@ -42,14 +42,9 @@ public class LoadRenderer{
|
||||
private long lastFrameTime;
|
||||
|
||||
{
|
||||
//fx.addEffect(new CrtFilter());
|
||||
|
||||
fx.addEffect(new VignettingFilter(false));
|
||||
//fx.addEffect(new NoiseFilter(0.1f, 1f));
|
||||
fx.addEffect(new BloomFilter());
|
||||
}
|
||||
|
||||
{
|
||||
bars = new Bar[]{
|
||||
new Bar("s_proc#", OS.cores / 16f, OS.cores < 4),
|
||||
new Bar("c_aprog", () -> assets != null, () -> assets.getProgress(), () -> false),
|
||||
@ -64,6 +59,12 @@ public class LoadRenderer{
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public void dispose(){
|
||||
mesh.dispose();
|
||||
fx.dispose();
|
||||
}
|
||||
|
||||
public void draw(){
|
||||
if(!preview){
|
||||
if(lastFrameTime == 0){
|
||||
|
Loading…
Reference in New Issue
Block a user