Cleanup
This commit is contained in:
@@ -15,7 +15,6 @@ import mindustry.gen.*;
|
|||||||
import mindustry.type.*;
|
import mindustry.type.*;
|
||||||
import mindustry.world.*;
|
import mindustry.world.*;
|
||||||
import mindustry.world.blocks.payloads.*;
|
import mindustry.world.blocks.payloads.*;
|
||||||
import mindustry.world.blocks.power.*;
|
|
||||||
|
|
||||||
/** An entity that holds a payload. */
|
/** An entity that holds a payload. */
|
||||||
@Component
|
@Component
|
||||||
@@ -23,12 +22,14 @@ abstract class PayloadComp implements Posc, Rotc, Hitboxc, Unitc{
|
|||||||
@Import float x, y, rotation;
|
@Import float x, y, rotation;
|
||||||
@Import UnitType type;
|
@Import UnitType type;
|
||||||
|
|
||||||
private transient @Nullable PowerGraph payloadPower;
|
|
||||||
|
|
||||||
Seq<Payload> payloads = new Seq<>();
|
Seq<Payload> payloads = new Seq<>();
|
||||||
|
|
||||||
//uncomment for insanity
|
//uncomment for insanity
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
||||||
|
private transient @Nullable PowerGraph payloadPower;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(){
|
public void update(){
|
||||||
if(payloadPower != null){
|
if(payloadPower != null){
|
||||||
|
|||||||
@@ -154,7 +154,7 @@ public class Block extends UnlockableContent{
|
|||||||
public boolean alwaysReplace = false;
|
public boolean alwaysReplace = false;
|
||||||
/** if false, this block can never be replaced. */
|
/** if false, this block can never be replaced. */
|
||||||
public boolean replaceable = true;
|
public boolean replaceable = true;
|
||||||
/** The block group. Unless {@link #canReplace} is overriden, blocks in the same group can replace each other. */
|
/** The block group. Unless {@link #canReplace} is overridden, blocks in the same group can replace each other. */
|
||||||
public BlockGroup group = BlockGroup.none;
|
public BlockGroup group = BlockGroup.none;
|
||||||
/** List of block flags. Used for AI indexing. */
|
/** List of block flags. Used for AI indexing. */
|
||||||
public EnumSet<BlockFlag> flags = EnumSet.of();
|
public EnumSet<BlockFlag> flags = EnumSet.of();
|
||||||
|
|||||||
@@ -139,7 +139,8 @@ public class NuclearReactor extends PowerGenerator{
|
|||||||
if((fuel < 5 && heat < 0.5f) || !state.rules.reactorExplosions) return;
|
if((fuel < 5 && heat < 0.5f) || !state.rules.reactorExplosions) return;
|
||||||
|
|
||||||
Effect.shake(6f, 16f, x, y);
|
Effect.shake(6f, 16f, x, y);
|
||||||
Damage.damage(x, y, explosionRadius * tilesize * (float)(fuel / itemCapacity), explosionDamage * 4);
|
// * ((float)fuel / itemCapacity) to scale based on fullness
|
||||||
|
Damage.damage(x, y, explosionRadius * tilesize, explosionDamage * 4);
|
||||||
|
|
||||||
explodeEffect.at(x, y);
|
explodeEffect.at(x, y);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user