Block renaming done

This commit is contained in:
Anuken
2022-05-06 14:35:06 -04:00
parent 7540b1c10a
commit 0c1926ade6
9 changed files with 16 additions and 11 deletions

View File

@@ -143,7 +143,7 @@ public class Blocks{
//TODO names
refabricator,
advancedReconstructor,
primeRefabricator,
tankAssembler, shipAssembler, mechAssembler,
basicAssemblerModule,
@@ -4239,7 +4239,8 @@ public class Blocks{
);
}};
advancedReconstructor = new Reconstructor("advanced-reconstructor"){{
//yes very silly name
primeRefabricator = new Reconstructor("prime-refabricator"){{
requirements(Category.units, with(Items.thorium, 250, Items.oxide, 200, Items.tungsten, 200, Items.silicon, 400));
regionSuffix = "-dark";

View File

@@ -299,7 +299,7 @@ public class ErekirTechTree{
node(UnitTypes.locus);
//TODO
node(advancedReconstructor, () -> {
node(primeRefabricator, () -> {
node(UnitTypes.precept);
node(UnitTypes.anthicus);
node(UnitTypes.obviate);

View File

@@ -38,6 +38,7 @@ public class BlockRenderer{
//TODO I don't like this system
private Seq<UpdateRenderState> updateFloors = new Seq<>(UpdateRenderState.class);
private boolean hadMapLimit;
private int lastCamX, lastCamY, lastRangeX, lastRangeY;
private float brokenFade = 0f;
private FrameBuffer shadows = new FrameBuffer();
@@ -67,6 +68,7 @@ public class BlockRenderer{
shadowEvents.clear();
updateFloors.clear();
lastCamY = lastCamX = -99; //invalidate camera position so blocks get updated
hadMapLimit = state.rules.limitMapArea;
shadows.getTexture().setFilter(TextureFilter.linear, TextureFilter.linear);
shadows.resize(world.width(), world.height());
@@ -99,8 +101,12 @@ public class BlockRenderer{
updateDarkness();
});
//sometimes darkness gets disabled.
Events.run(Trigger.newGame, () -> {
updateDarkness();
if(hadMapLimit && !state.rules.limitMapArea){
updateDarkness();
renderer.minimap.updateAll();
}
});
Events.on(TilePreChangeEvent.class, event -> {