Cleanup
This commit is contained in:
@@ -1,8 +1,6 @@
|
|||||||
package mindustry.content;
|
package mindustry.content;
|
||||||
|
|
||||||
import arc.*;
|
|
||||||
import arc.graphics.*;
|
import arc.graphics.*;
|
||||||
import arc.graphics.g2d.*;
|
|
||||||
import arc.struct.*;
|
import arc.struct.*;
|
||||||
import mindustry.*;
|
import mindustry.*;
|
||||||
import mindustry.ctype.*;
|
import mindustry.ctype.*;
|
||||||
@@ -97,36 +95,9 @@ public class Blocks implements ContentList{
|
|||||||
public void load(){
|
public void load(){
|
||||||
//region environment
|
//region environment
|
||||||
|
|
||||||
air = new Floor("air"){
|
air = new AirBlock("air");
|
||||||
{
|
|
||||||
alwaysReplace = true;
|
|
||||||
hasShadow = false;
|
|
||||||
useColor = false;
|
|
||||||
wall = this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override public void drawBase(Tile tile){}
|
spawn = new SpawnBlock("spawn");
|
||||||
@Override public void load(){}
|
|
||||||
@Override public void init(){}
|
|
||||||
@Override public boolean isHidden(){ return true; }
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TextureRegion[] variantRegions(){
|
|
||||||
if(variantRegions == null){
|
|
||||||
variantRegions = new TextureRegion[]{Core.atlas.find("clear")};
|
|
||||||
}
|
|
||||||
return variantRegions;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
spawn = new OverlayFloor("spawn"){
|
|
||||||
{
|
|
||||||
variants = 0;
|
|
||||||
needsSurface = false;
|
|
||||||
}
|
|
||||||
@Override
|
|
||||||
public void drawBase(Tile tile){}
|
|
||||||
};
|
|
||||||
|
|
||||||
cliff = new Cliff("cliff"){{
|
cliff = new Cliff("cliff"){{
|
||||||
inEditor = false;
|
inEditor = false;
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ import mindustry.gen.*;
|
|||||||
import mindustry.graphics.*;
|
import mindustry.graphics.*;
|
||||||
|
|
||||||
public class LightningBulletType extends BulletType{
|
public class LightningBulletType extends BulletType{
|
||||||
protected Color lightningColor = Pal.lancerLaser;
|
public Color lightningColor = Pal.lancerLaser;
|
||||||
protected int lightningLength = 25, lightningLengthRand = 0;
|
public int lightningLength = 25, lightningLengthRand = 0;
|
||||||
|
|
||||||
public LightningBulletType(){
|
public LightningBulletType(){
|
||||||
super(0.0001f, 1f);
|
super(0.0001f, 1f);
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ public class LiquidTurret extends Turret{
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Initializes accepted ammo map. Format: [liquid1, bullet1, liquid2, bullet2...] */
|
/** Initializes accepted ammo map. Format: [liquid1, bullet1, liquid2, bullet2...] */
|
||||||
protected void ammo(Object... objects){
|
public void ammo(Object... objects){
|
||||||
ammoTypes = OrderedMap.of(objects);
|
ammoTypes = OrderedMap.of(objects);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,43 @@
|
|||||||
|
package mindustry.world.blocks.environment;
|
||||||
|
|
||||||
|
import arc.*;
|
||||||
|
import arc.graphics.g2d.*;
|
||||||
|
import mindustry.annotations.Annotations.*;
|
||||||
|
import mindustry.world.*;
|
||||||
|
|
||||||
|
public class AirBlock extends Floor{
|
||||||
|
|
||||||
|
public AirBlock(String name){
|
||||||
|
super(name);
|
||||||
|
alwaysReplace = true;
|
||||||
|
hasShadow = false;
|
||||||
|
useColor = false;
|
||||||
|
wall = this;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void drawBase(Tile tile){}
|
||||||
|
|
||||||
|
@OverrideCallSuper
|
||||||
|
@Override
|
||||||
|
public void load(){}
|
||||||
|
|
||||||
|
@OverrideCallSuper
|
||||||
|
@Override
|
||||||
|
public void init(){
|
||||||
|
decoration = this;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isHidden(){
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public TextureRegion[] variantRegions(){
|
||||||
|
if(variantRegions == null){
|
||||||
|
variantRegions = new TextureRegion[]{Core.atlas.find("clear")};
|
||||||
|
}
|
||||||
|
return variantRegions;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -6,7 +6,7 @@ import arc.math.*;
|
|||||||
import mindustry.world.*;
|
import mindustry.world.*;
|
||||||
|
|
||||||
public class Boulder extends Block{
|
public class Boulder extends Block{
|
||||||
protected int variants;
|
public int variants;
|
||||||
|
|
||||||
public Boulder(String name){
|
public Boulder(String name){
|
||||||
super(name);
|
super(name);
|
||||||
|
|||||||
@@ -0,0 +1,15 @@
|
|||||||
|
package mindustry.world.blocks.environment;
|
||||||
|
|
||||||
|
import mindustry.world.*;
|
||||||
|
|
||||||
|
public class SpawnBlock extends OverlayFloor{
|
||||||
|
|
||||||
|
public SpawnBlock(String name){
|
||||||
|
super(name);
|
||||||
|
variants = 0;
|
||||||
|
needsSurface = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void drawBase(Tile tile){}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user