Renamed Texture enums with correct case

This commit is contained in:
Anuken
2020-06-21 12:20:02 -04:00
parent 93ae73abb6
commit 934db24d3b
9 changed files with 15 additions and 25 deletions

View File

@@ -474,16 +474,6 @@ public class Control implements ApplicationListener, Loadable{
if(state.isGame()){ if(state.isGame()){
input.update(); input.update();
if(state.isCampaign()){
for(Tilec tile : state.teams.cores(player.team())){
for(Item item : content.items()){
if(tile.items().has(item)){
item.unlock();
}
}
}
}
if(state.rules.tutorial){ if(state.rules.tutorial){
tutorial.update(); tutorial.update();
} }

View File

@@ -44,7 +44,7 @@ public class BlockRenderer implements Disposable{
shadowEvents.clear(); shadowEvents.clear();
lastCamY = lastCamX = -99; //invalidate camera position so blocks get updated lastCamY = lastCamX = -99; //invalidate camera position so blocks get updated
shadows.getTexture().setFilter(TextureFilter.Linear, TextureFilter.Linear); shadows.getTexture().setFilter(TextureFilter.linear, TextureFilter.linear);
shadows.resize(world.width(), world.height()); shadows.resize(world.width(), world.height());
shadows.begin(); shadows.begin();
Core.graphics.clear(Color.white); Core.graphics.clear(Color.white);
@@ -62,7 +62,7 @@ public class BlockRenderer implements Disposable{
Draw.color(); Draw.color();
shadows.end(); shadows.end();
dark.getTexture().setFilter(TextureFilter.Linear, TextureFilter.Linear); dark.getTexture().setFilter(TextureFilter.linear, TextureFilter.linear);
dark.resize(world.width(), world.height()); dark.resize(world.width(), world.height());
dark.begin(); dark.begin();
Core.graphics.clear(Color.white); Core.graphics.clear(Color.white);

View File

@@ -59,7 +59,7 @@ public class CubemapMesh implements Disposable{
public CubemapMesh(Cubemap map){ public CubemapMesh(Cubemap map){
this.map = map; this.map = map;
this.map.setFilter(TextureFilter.Linear); this.map.setFilter(TextureFilter.linear);
this.mesh = new Mesh(true, vertices.length, 0, this.mesh = new Mesh(true, vertices.length, 0,
new VertexAttribute(Usage.position, 3, "a_position") new VertexAttribute(Usage.position, 3, "a_position")
); );

View File

@@ -15,7 +15,7 @@ public class Pixelator implements Disposable{
private float px, py, pre; private float px, py, pre;
{ {
buffer.getTexture().setFilter(TextureFilter.Nearest, TextureFilter.Nearest); buffer.getTexture().setFilter(TextureFilter.nearest, TextureFilter.nearest);
} }
public void drawPixelate(){ public void drawPixelate(){

View File

@@ -203,8 +203,8 @@ public class Shaders{
super(frag, "screenspace"); super(frag, "screenspace");
Core.assets.load("sprites/noise.png", Texture.class).loaded = t -> { Core.assets.load("sprites/noise.png", Texture.class).loaded = t -> {
((Texture)t).setFilter(TextureFilter.Linear); ((Texture)t).setFilter(TextureFilter.linear);
((Texture)t).setWrap(TextureWrap.Repeat); ((Texture)t).setWrap(TextureWrap.repeat);
}; };
} }

View File

@@ -165,7 +165,7 @@ public class Mods implements Loadable{
} }
} }
TextureFilter filter = Core.settings.getBool("linear") ? TextureFilter.Linear : TextureFilter.Nearest; TextureFilter filter = Core.settings.getBool("linear") ? TextureFilter.linear : TextureFilter.nearest;
//flush so generators can use these sprites //flush so generators can use these sprites
packer.flush(filter, Core.atlas); packer.flush(filter, Core.atlas);
@@ -452,7 +452,7 @@ public class Mods implements Loadable{
content.init(); content.init();
content.load(); content.load();
content.loadColors(); content.loadColors();
Core.atlas.getTextures().each(t -> t.setFilter(Core.settings.getBool("linear") ? TextureFilter.Linear : TextureFilter.Nearest)); Core.atlas.getTextures().each(t -> t.setFilter(Core.settings.getBool("linear") ? TextureFilter.linear : TextureFilter.nearest));
requiresReload = false; requiresReload = false;
loadIcons(); loadIcons();

View File

@@ -127,8 +127,8 @@ public class Fonts{
scaled.add(parameter.fontParameters); scaled.add(parameter.fontParameters);
} }
parameter.fontParameters.magFilter = TextureFilter.Linear; parameter.fontParameters.magFilter = TextureFilter.linear;
parameter.fontParameters.minFilter = TextureFilter.Linear; parameter.fontParameters.minFilter = TextureFilter.linear;
parameter.fontParameters.packer = UI.packer; parameter.fontParameters.packer = UI.packer;
return super.loadSync(manager, fileName, file, parameter); return super.loadSync(manager, fileName, file, parameter);
} }
@@ -175,7 +175,7 @@ public class Fonts{
atlas.disposePixmap(texture); atlas.disposePixmap(texture);
page.setDirty(true); page.setDirty(true);
page.updateTexture(TextureFilter.Linear, TextureFilter.Linear, false); page.updateTexture(TextureFilter.linear, TextureFilter.linear, false);
} }
public static TextureRegionDrawable getGlyph(BitmapFont font, char glyph){ public static TextureRegionDrawable getGlyph(BitmapFont font, char glyph){

View File

@@ -29,7 +29,7 @@ public class SchematicsDialog extends BaseDialog{
public SchematicsDialog(){ public SchematicsDialog(){
super("$schematics"); super("$schematics");
Core.assets.load("sprites/schematic-background.png", Texture.class).loaded = t -> { Core.assets.load("sprites/schematic-background.png", Texture.class).loaded = t -> {
((Texture)t).setWrap(TextureWrap.Repeat); ((Texture)t).setWrap(TextureWrap.repeat);
}; };
shouldPause = true; shouldPause = true;

View File

@@ -338,7 +338,7 @@ public class SettingsMenuDialog extends SettingsDialog{
graphics.checkPref("animatedshields", !mobile); graphics.checkPref("animatedshields", !mobile);
} }
if(!ios){ if(!ios){
graphics.checkPref("bloom", !mobile, val -> renderer.toggleBloom(val)); graphics.checkPref("bloom", true, val -> renderer.toggleBloom(val));
}else{ }else{
Core.settings.put("bloom", false); Core.settings.put("bloom", false);
} }
@@ -351,14 +351,14 @@ public class SettingsMenuDialog extends SettingsDialog{
graphics.checkPref("linear", true, b -> { graphics.checkPref("linear", true, b -> {
for(Texture tex : Core.atlas.getTextures()){ for(Texture tex : Core.atlas.getTextures()){
TextureFilter filter = b ? TextureFilter.Linear : TextureFilter.Nearest; TextureFilter filter = b ? TextureFilter.linear : TextureFilter.nearest;
tex.setFilter(filter, filter); tex.setFilter(filter, filter);
} }
}); });
if(Core.settings.getBool("linear")){ if(Core.settings.getBool("linear")){
for(Texture tex : Core.atlas.getTextures()){ for(Texture tex : Core.atlas.getTextures()){
TextureFilter filter = TextureFilter.Linear; TextureFilter filter = TextureFilter.linear;
tex.setFilter(filter, filter); tex.setFilter(filter, filter);
} }
} }