This commit is contained in:
Anuken 2020-05-17 16:17:08 -04:00
parent 7b3a5ad227
commit 4254de01e4
3 changed files with 14 additions and 6 deletions

View file

@ -38,10 +38,11 @@ public abstract class UnlockableContent extends MappableContent{
/** Returns a specific content icon, or the region {contentType}-{name} if not found.*/
public TextureRegion icon(Cicon icon){
if(cicons[icon.ordinal()] == null){
cicons[icon.ordinal()] = Core.atlas.find(getContentType().name() + "-" + name + "-" + icon.name(),
cicons[icon.ordinal()] =
Core.atlas.find(getContentType().name() + "-" + name + "-" + icon.name(),
Core.atlas.find(getContentType().name() + "-" + name + "-full",
Core.atlas.find(getContentType().name() + "-" + name,
Core.atlas.find(name,
Core.atlas.find(getContentType().name() + "-" + name,
Core.atlas.find(name + "1")))));
}
return cicons[icon.ordinal()];

View file

@ -55,6 +55,11 @@ public class FileMapGenerator implements WorldGenerator{
Schematics.placeLoadout(Loadouts.basicShard, tile.x, tile.y);
anyCores = true;
}
//add random decoration
if(Mathf.chance(0.01) && !tile.floor().isLiquid && tile.block() == Blocks.air){
tile.setBlock(tile.floor().decoration);
}
}
if(!anyCores){

View file

@ -15,8 +15,8 @@ import arc.util.*;
import arc.util.ArcAnnotate.*;
import mindustry.content.*;
import mindustry.ctype.*;
import mindustry.game.*;
import mindustry.game.EventType.*;
import mindustry.game.*;
import mindustry.gen.*;
import mindustry.graphics.*;
import mindustry.graphics.g3d.*;
@ -74,7 +74,9 @@ public class PlanetDialog extends FloatingDialog{
}
});
Events.on(ResizeEvent.class, e -> makeBloom());
Events.on(ResizeEvent.class, e -> {
makeBloom();
});
TextButtonStyle style = Styles.cleart;
float bmargin = 6f;
@ -282,9 +284,9 @@ public class PlanetDialog extends FloatingDialog{
if(selectAlpha > 0.01f){
float stroke = 0.026f;
if(sec.hasBase()){
drawSelection(sec, Tmp.c1.set(Team.sharded.color).a(selectAlpha), stroke, -0.01f);
drawSelection(sec, Tmp.c1.set(Team.sharded.color).mul(0.8f).a(selectAlpha), stroke, -0.01f);
}else if(sec.hasEnemyBase()){
drawSelection(sec, Tmp.c1.set(Team.crux.color).a(selectAlpha), stroke, -0.02f);
drawSelection(sec, Tmp.c1.set(Team.crux.color).mul(0.8f).a(selectAlpha), stroke, -0.02f);
}
}
}