Merge remote-tracking branch 'origin/master'
# Conflicts: # core/src/io/anuke/mindustry/core/Renderer.java
This commit is contained in:
@@ -51,7 +51,7 @@ public class Sectors{
|
||||
if(!headless){
|
||||
sector.saveID = control.saves.addSave("sector-" + sector.packedPosition()).index;
|
||||
}
|
||||
world.sectors().save();
|
||||
world.sectors.save();
|
||||
world.setSector(sector);
|
||||
sector.currentMission().onBegin();
|
||||
}else if(SaveIO.breakingVersions.contains(sector.getSave().getBuild())){
|
||||
@@ -169,7 +169,7 @@ public class Sectors{
|
||||
//gen tiles in sector
|
||||
for (int x = 0; x < sectorSize; x++) {
|
||||
for (int y = 0; y < sectorSize; y++) {
|
||||
world.generator().generateTile(result, sx + sector.x, sy + sector.y, x, y, true, null, ores);
|
||||
world.generator.generateTile(result, sx + sector.x, sy + sector.y, x, y, true, null, ores);
|
||||
newTiles[sx * sectorSize + x][sy * sectorSize + y] = new Tile(x + sx * sectorSize, y + sy*sectorSize, result.floor.id, result.wall.id, (byte)0, (byte)0, result.elevation);
|
||||
}
|
||||
}
|
||||
@@ -405,8 +405,8 @@ public class Sectors{
|
||||
int toX = x * sectorSize / sectorImageSize;
|
||||
int toY = y * sectorSize / sectorImageSize;
|
||||
|
||||
GenResult result = world.generator().generateTile(sector.x, sector.y, toX, toY, false);
|
||||
world.generator().generateTile(secResult, sector.x, sector.y, toX, ((y+1) * sectorSize / sectorImageSize), false, null, null);
|
||||
GenResult result = world.generator.generateTile(sector.x, sector.y, toX, toY, false);
|
||||
world.generator.generateTile(secResult, sector.x, sector.y, toX, ((y+1) * sectorSize / sectorImageSize), false, null, null);
|
||||
|
||||
int color = ColorMapper.colorFor(result.floor, result.wall, Team.none, result.elevation, secResult.elevation > result.elevation ? (byte)(1 << 6) : (byte)0);
|
||||
pixmap.drawPixel(x, pixmap.getHeight() - 1 - y, color);
|
||||
|
||||
@@ -49,7 +49,7 @@ public class TutorialSector{
|
||||
for(int x = 0; x < world.width(); x++){
|
||||
for(int y = 0; y < world.height(); y++){
|
||||
Tile tile = world.tile(x, y);
|
||||
world.generator().generateTile(res, 0, 0, x, y, true, null, ores);
|
||||
world.generator.generateTile(res, 0, 0, x, y, true, null, ores);
|
||||
if(!tile.hasCliffs()){
|
||||
tile.setFloor((Floor) res.floor);
|
||||
}
|
||||
|
||||
@@ -187,7 +187,7 @@ public class WorldGenerator{
|
||||
SeedRandom rnd = new SeedRandom(sector.getSeed());
|
||||
Generation gena = new Generation(sector, tiles, tiles.length, tiles[0].length, rnd);
|
||||
Array<GridPoint2> spawnpoints = sector.currentMission().getSpawnPoints(gena);
|
||||
Array<Item> ores = world.sectors().getOres(sector.x, sector.y);
|
||||
Array<Item> ores = world.sectors.getOres(sector.x, sector.y);
|
||||
|
||||
for(int x = 0; x < width; x++){
|
||||
for(int y = 0; y < height; y++){
|
||||
|
||||
@@ -13,11 +13,11 @@ public class ExpandMission extends ActionMission{
|
||||
|
||||
runner = () -> {
|
||||
if(headless){
|
||||
world.sectors().expandSector(world.getSector(), expandX, expandY);
|
||||
world.sectors.expandSector(world.getSector(), expandX, expandY);
|
||||
done = true;
|
||||
}else{
|
||||
ui.loadLogic(() -> {
|
||||
world.sectors().expandSector(world.getSector(), expandX, expandY);
|
||||
world.sectors.expandSector(world.getSector(), expandX, expandY);
|
||||
done = true;
|
||||
});
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ public class WaveMission extends Mission{
|
||||
public void onBegin(){
|
||||
super.onBegin();
|
||||
|
||||
world.pathfinder().activateTeamPath(waveTeam);
|
||||
world.pathfinder.activateTeamPath(waveTeam);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user