mirror of
https://github.com/Anuken/Mindustry.git
synced 2024-11-11 14:56:10 +03:00
Bugfixes
This commit is contained in:
parent
d0b2f63553
commit
d611dd107a
@ -215,7 +215,7 @@ public class TODOPlanetGenerator extends PlanetGenerator{
|
||||
|
||||
FloatArray frequencies = new FloatArray();
|
||||
for(int i = 0; i < ores.size; i++){
|
||||
frequencies.add(rand.random(-0.09f, 0.01f));
|
||||
frequencies.add(rand.random(-0.09f, 0.01f) - i * 0.01f);
|
||||
}
|
||||
|
||||
pass((x, y) -> {
|
||||
|
@ -9,6 +9,7 @@ import arc.input.*;
|
||||
import arc.math.*;
|
||||
import arc.math.geom.*;
|
||||
import arc.scene.event.*;
|
||||
import arc.scene.ui.TextButton.*;
|
||||
import arc.scene.ui.layout.*;
|
||||
import arc.util.*;
|
||||
import arc.util.ArcAnnotate.*;
|
||||
@ -85,10 +86,20 @@ public class PlanetDialog extends FloatingDialog{
|
||||
makeBloom();
|
||||
});
|
||||
|
||||
cam.fov = 60f;
|
||||
|
||||
addCloseButton();
|
||||
buttons.addImageTextButton("$techtree", Icon.tree, () -> ui.tech.show()).size(230f, 64f);
|
||||
buttons.defaults().size(220f, 64f).pad(0f);
|
||||
|
||||
TextButtonStyle style = Styles.cleart;
|
||||
float bmargin = 6f;
|
||||
|
||||
//TODO names
|
||||
buttons.addImageTextButton("$back", Icon.left, style, this::hide).margin(bmargin);
|
||||
buttons.addImageTextButton("Tech", Icon.tree, style, () -> ui.tech.show()).margin(bmargin);
|
||||
buttons.addImageTextButton("Launch", Icon.upOpen, style, this::hide).margin(bmargin);
|
||||
buttons.addImageTextButton("Database", Icon.book, style, () -> ui.database.show()).margin(bmargin);
|
||||
buttons.addImageTextButton("Resources", Icon.file, style, this::hide).margin(bmargin);
|
||||
|
||||
cam.fov = 60f;
|
||||
|
||||
camRelative.set(0, 0f, camLength);
|
||||
projector.setScaling(1f / 150f);
|
||||
|
@ -39,7 +39,7 @@ public class ItemBridge extends Block{
|
||||
hasItems = true;
|
||||
unloadable = false;
|
||||
group = BlockGroup.transportation;
|
||||
//point2 config is relative
|
||||
//point2 config is relative
|
||||
config(Point2.class, (tile, i) -> ((ItemBridgeEntity)tile).link = Point2.pack(i.x + tile.tileX(), i.y + tile.tileY()));
|
||||
//integer is not
|
||||
config(Integer.class, (tile, i) -> ((ItemBridgeEntity)tile).link = i);
|
||||
@ -117,7 +117,7 @@ public class ItemBridge extends Block{
|
||||
return false;
|
||||
}
|
||||
|
||||
return other.block() == this && (!checkDouble || other.<ItemBridgeEntity>ent().link != tile.pos());
|
||||
return other.block() == this && (other.team() == tile.team() || tile.block() != this) && (!checkDouble || other.<ItemBridgeEntity>ent().link != tile.pos());
|
||||
}
|
||||
|
||||
public Tile findLink(int x, int y){
|
||||
|
@ -64,7 +64,6 @@ public class Floor extends Block{
|
||||
public Block decoration = Blocks.air;
|
||||
|
||||
protected TextureRegion[][] edges;
|
||||
protected byte eq = 0;
|
||||
protected Array<Block> blenders = new Array<>();
|
||||
protected IntSet blended = new IntSet();
|
||||
protected TextureRegion edgeRegion;
|
||||
@ -183,7 +182,6 @@ public class Floor extends Block{
|
||||
protected void drawEdges(Tile tile, boolean sameLayer){
|
||||
blenders.clear();
|
||||
blended.clear();
|
||||
eq = 0;
|
||||
|
||||
for(int i = 0; i < 8; i++){
|
||||
Point2 point = Geometry.d8[i];
|
||||
@ -192,11 +190,10 @@ public class Floor extends Block{
|
||||
if(blended.add(other.floor().id)){
|
||||
blenders.add(other.floor());
|
||||
}
|
||||
eq |= (1 << i);
|
||||
}
|
||||
}
|
||||
|
||||
blenders.sort((a, b) -> Integer.compare(a.id, b.id));
|
||||
blenders.sort(a -> a.id);
|
||||
|
||||
for(Block block : blenders){
|
||||
for(int i = 0; i < 8; i++){
|
||||
|
@ -25,7 +25,7 @@ public class ArmoredConduit extends Conduit{
|
||||
return otherblock.outputsLiquid && blendsArmored(tile, rotation, otherx, othery, otherrot, otherblock);
|
||||
}
|
||||
|
||||
public class ArmoredConduitEntity extends TileEntity{
|
||||
public class ArmoredConduitEntity extends ConduitEntity{
|
||||
@Override
|
||||
public void draw(){
|
||||
super.draw();
|
||||
@ -39,7 +39,7 @@ public class ArmoredConduit extends Conduit{
|
||||
|
||||
@Override
|
||||
public boolean acceptLiquid(Tilec source, Liquid liquid, float amount){
|
||||
return super.acceptLiquid(source, liquid, amount) && (source.block() instanceof Conduit) || Edges.getFacingEdge(source.tile(), tile).relativeTo(tile) == tile.rotation();
|
||||
return super.acceptLiquid(source, liquid, amount) && (source.block() instanceof Conduit) || Edges.getFacingEdge(source.tile(), tile).absoluteRelativeTo(tile.x, tile.y) == tile.rotation();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ public class LiquidExtendingBridge extends ExtendingItemBridge{
|
||||
group = BlockGroup.liquids;
|
||||
}
|
||||
|
||||
public class LiquidExtendingBridgeEntity extends ItemBridgeEntity{
|
||||
public class LiquidExtendingBridgeEntity extends ExtendingItemBridgeEntity{
|
||||
@Override
|
||||
public void updateTile(){
|
||||
time += cycleSpeed * delta();
|
||||
|
@ -1,3 +1,7 @@
|
||||
if(JavaVersion.current() != JavaVersion.VERSION_1_8){
|
||||
throw new GradleException("!!! YOU MUST USE JAVA 8 TO COMPILE AND RUN MINDUSTRY !!! Read the README. Your version: ${System.properties["java.version"]}")
|
||||
}
|
||||
|
||||
include 'desktop', 'core', 'server', 'ios', 'annotations', 'tools', 'tests'
|
||||
|
||||
def use = { ... names ->
|
||||
|
Loading…
Reference in New Issue
Block a user