Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -71,7 +71,7 @@ public class Blocks{
|
||||
melter, separator, disassembler, sporePress, pulverizer, incinerator, coalCentrifuge,
|
||||
|
||||
//erekir
|
||||
siliconArcFurnace, electrolyzer, oxidationChamber, atmosphericConcentrator, electricHeater, phaseHeater, heatRedirector, slagIncinerator,
|
||||
siliconArcFurnace, electrolyzer, oxidationChamber, atmosphericConcentrator, electricHeater, slagHeater, phaseHeater, heatRedirector, slagIncinerator,
|
||||
carbideCrucible, slagCentrifuge, surgeCrucible, cyanogenSynthesizer, phaseSynthesizer, heatReactor,
|
||||
|
||||
//sandbox
|
||||
@@ -1251,6 +1251,20 @@ public class Blocks{
|
||||
regionRotated1 = 1;
|
||||
consumePower(50f / 60f);
|
||||
}};
|
||||
|
||||
slagHeater = new HeatProducer("slag-heater"){{
|
||||
requirements(Category.crafting, with(Items.tungsten, 50, Items.oxide, 20, Items.beryllium, 20));
|
||||
|
||||
researchCostMultiplier = 4f;
|
||||
|
||||
drawer = new DrawMulti(new DrawRegion("-bottom"), new DrawLiquidTile(Liquids.slag), new DrawDefault(), new DrawHeatOutput());
|
||||
size = 3;
|
||||
liquidCapacity = 40f;
|
||||
rotateDraw = false;
|
||||
regionRotated1 = 1;
|
||||
consumeLiquid(Liquids.slag, 40f / 60f);
|
||||
heatOutput = 6f;
|
||||
}};
|
||||
|
||||
phaseHeater = new HeatProducer("phase-heater"){{
|
||||
requirements(Category.crafting, with(Items.oxide, 30, Items.carbide, 30, Items.beryllium, 30));
|
||||
|
||||
@@ -197,6 +197,10 @@ public class ErekirTechTree{
|
||||
});
|
||||
});
|
||||
|
||||
node(slagHeater, () -> {
|
||||
|
||||
});
|
||||
|
||||
node(atmosphericConcentrator, Seq.with(new OnSector(four)), () -> {
|
||||
node(cyanogenSynthesizer, Seq.with(new OnSector(four)), () -> {
|
||||
|
||||
|
||||
@@ -148,7 +148,7 @@ public class SectorPresets{
|
||||
new TextMarker("Use [accent]cliff crushers[] to mine sand.", 262f * 8f, 88f * 8f)
|
||||
),
|
||||
new BuildCountObjective(Blocks.tankFabricator, 1).withMarkers(
|
||||
new TextMarker("Use [accent]units[] to explore the map, defend buildings, and go on the offensive.\n Research and place a [accent]fabricator[]", 258f * 8f, 116f * 8f)
|
||||
new TextMarker("Use [accent]units[] to explore the map, defend buildings, and go on the offensive.\n Research and place a [accent]tank fabricator[].", 258f * 8f, 116f * 8f)
|
||||
),
|
||||
new UnitCountObjective(UnitTypes.stell, 1).withMarkers(
|
||||
new TextMarker("Produce a unit.\nUse the \"?\" button to see selected factory requirements.", 258f * 8f, 116f * 8f)
|
||||
@@ -160,7 +160,7 @@ public class SectorPresets{
|
||||
new TextMarker("Units are effective, but [accent]turrets[] provide better defensive capabilities if used effectively.\n Place a [accent]Breach[] turret.\nTurrets require [accent]ammo[].", 258f * 8f, 114f * 8f)
|
||||
),
|
||||
new BuildCountObjective(Blocks.berylliumWall, 6).withMarkers(
|
||||
new TextMarker("[accent]Walls[] can prevent oncoming damage from reaching buildings\nPlace some [accent]beryllium walls[] around the turret.", 276f * 8f, 133f * 8f)
|
||||
new TextMarker("[accent]Walls[] can prevent oncoming damage from reaching buildings.\nPlace some [accent]beryllium walls[] around the turret.", 276f * 8f, 133f * 8f)
|
||||
),
|
||||
new TimerObjective("@objective.enemiesapproaching",30 * 60).withMarkers(
|
||||
new TextMarker("Enemy incoming, prepare to defend.", 276f * 8f, 133f * 8f)
|
||||
|
||||
@@ -613,6 +613,10 @@ abstract class BuildingComp implements Posc, Teamc, Healthc, Buildingc, Timerc,
|
||||
Fx.unitDrop.at(unit);
|
||||
}
|
||||
|
||||
public boolean canWithdraw(){
|
||||
return true;
|
||||
}
|
||||
|
||||
public boolean canUnload(){
|
||||
return block.unloadable;
|
||||
}
|
||||
@@ -1342,11 +1346,6 @@ abstract class BuildingComp implements Posc, Teamc, Healthc, Buildingc, Timerc,
|
||||
public ItemModule flowItems(){
|
||||
return items;
|
||||
}
|
||||
|
||||
public boolean displayable(){
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void display(Table table){
|
||||
//display the block stuff
|
||||
|
||||
@@ -4,5 +4,9 @@ import arc.scene.ui.layout.*;
|
||||
|
||||
/** An interface for things that can be displayed when hovered over. */
|
||||
public interface Displayable{
|
||||
default boolean displayable(){
|
||||
return true;
|
||||
}
|
||||
|
||||
void display(Table table);
|
||||
}
|
||||
|
||||
@@ -70,6 +70,8 @@ public class BlockInventoryFragment{
|
||||
}
|
||||
|
||||
private void takeItem(int requested){
|
||||
if(!build.canWithdraw()) return;
|
||||
|
||||
//take everything
|
||||
int amount = Math.min(requested, player.unit().maxAccepted(lastItem));
|
||||
|
||||
|
||||
@@ -577,7 +577,7 @@ public class PlacementFragment{
|
||||
if(Core.scene.hasMouse() || topTable.hit(v.x, v.y, false) != null) return null;
|
||||
|
||||
//check for a unit
|
||||
Unit unit = Units.closestOverlap(player.team(), Core.input.mouseWorldX(), Core.input.mouseWorldY(), 5f, u -> !u.isLocal());
|
||||
Unit unit = Units.closestOverlap(player.team(), Core.input.mouseWorldX(), Core.input.mouseWorldY(), 5f, u -> !u.isLocal() && u.displayable());
|
||||
//if cursor has a unit, display it
|
||||
if(unit != null) return unit;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user