Block renaming
This commit is contained in:
|
Before Width: | Height: | Size: 226 B After Width: | Height: | Size: 226 B |
Binary file not shown.
|
Before Width: | Height: | Size: 210 B |
@@ -461,8 +461,6 @@ block.lancer.name=Lancer
|
|||||||
block.conveyor.name=Conveyor
|
block.conveyor.name=Conveyor
|
||||||
block.titanium-conveyor.name=Titanium Conveyor
|
block.titanium-conveyor.name=Titanium Conveyor
|
||||||
block.junction.name=Junction
|
block.junction.name=Junction
|
||||||
block.splitter.name=Router
|
|
||||||
block.splitter.description=Outputs items into three different directions once they are recieved.
|
|
||||||
block.router.name=Router
|
block.router.name=Router
|
||||||
block.router.description=Splits items into all 4 directions. Can store items as a buffer.
|
block.router.description=Splits items into all 4 directions. Can store items as a buffer.
|
||||||
block.distributor.name=Distributor
|
block.distributor.name=Distributor
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ public class Recipes implements ContentList{
|
|||||||
|
|
||||||
//starter lead transporation
|
//starter lead transporation
|
||||||
new Recipe(distribution, DistributionBlocks.junction, new ItemStack(Items.lead, 2));
|
new Recipe(distribution, DistributionBlocks.junction, new ItemStack(Items.lead, 2));
|
||||||
new Recipe(distribution, DistributionBlocks.splitter, new ItemStack(Items.lead, 6));
|
new Recipe(distribution, DistributionBlocks.router, new ItemStack(Items.lead, 6));
|
||||||
|
|
||||||
//advanced carbide transporation
|
//advanced carbide transporation
|
||||||
new Recipe(distribution, DistributionBlocks.distributor, new ItemStack(Items.carbide, 8), new ItemStack(Items.tungsten, 8));
|
new Recipe(distribution, DistributionBlocks.distributor, new ItemStack(Items.carbide, 8), new ItemStack(Items.tungsten, 8));
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import io.anuke.mindustry.world.blocks.distribution.*;
|
|||||||
|
|
||||||
public class DistributionBlocks extends BlockList implements ContentList{
|
public class DistributionBlocks extends BlockList implements ContentList{
|
||||||
public static Block conveyor, titaniumconveyor, distributor, junction,
|
public static Block conveyor, titaniumconveyor, distributor, junction,
|
||||||
bridgeConveyor, phaseConveyor, sorter, splitter, overflowGate, massDriver;
|
bridgeConveyor, phaseConveyor, sorter, router, overflowGate, massDriver;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void load(){
|
public void load(){
|
||||||
@@ -39,9 +39,9 @@ public class DistributionBlocks extends BlockList implements ContentList{
|
|||||||
|
|
||||||
sorter = new Sorter("sorter");
|
sorter = new Sorter("sorter");
|
||||||
|
|
||||||
splitter = new Splitter("splitter");
|
router = new Router("router");
|
||||||
|
|
||||||
distributor = new Splitter("distributor"){{
|
distributor = new Router("distributor"){{
|
||||||
size = 2;
|
size = 2;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import io.anuke.mindustry.world.Tile;
|
|||||||
import io.anuke.ucore.core.Timers;
|
import io.anuke.ucore.core.Timers;
|
||||||
import io.anuke.ucore.util.Mathf;
|
import io.anuke.ucore.util.Mathf;
|
||||||
|
|
||||||
public class OverflowGate extends Splitter{
|
public class OverflowGate extends Router{
|
||||||
|
|
||||||
public OverflowGate(String name){
|
public OverflowGate(String name){
|
||||||
super(name);
|
super(name);
|
||||||
|
|||||||
@@ -10,10 +10,10 @@ import io.anuke.mindustry.world.Tile;
|
|||||||
import io.anuke.mindustry.world.meta.BlockGroup;
|
import io.anuke.mindustry.world.meta.BlockGroup;
|
||||||
import io.anuke.ucore.core.Timers;
|
import io.anuke.ucore.core.Timers;
|
||||||
|
|
||||||
public class Splitter extends Block{
|
public class Router extends Block{
|
||||||
protected float speed = 8f;
|
protected float speed = 8f;
|
||||||
|
|
||||||
public Splitter(String name){
|
public Router(String name){
|
||||||
super(name);
|
super(name);
|
||||||
solid = true;
|
solid = true;
|
||||||
update = true;
|
update = true;
|
||||||
@@ -36,7 +36,7 @@ public class Splitter extends Block{
|
|||||||
entity.time += 1f/speed * Timers.delta();
|
entity.time += 1f/speed * Timers.delta();
|
||||||
Tile target = getTileTarget(tile, entity.lastItem, entity.lastInput, false);
|
Tile target = getTileTarget(tile, entity.lastItem, entity.lastInput, false);
|
||||||
|
|
||||||
if(target != null && (entity.time >= 1f || !(target.block() instanceof Splitter))){
|
if(target != null && (entity.time >= 1f || !(target.block() instanceof Router))){
|
||||||
getTileTarget(tile, entity.lastItem, entity.lastInput, true);
|
getTileTarget(tile, entity.lastItem, entity.lastInput, true);
|
||||||
target.block().handleItem(entity.lastItem, target, Edges.getFacingEdge(tile, target));
|
target.block().handleItem(entity.lastItem, target, Edges.getFacingEdge(tile, target));
|
||||||
entity.items.remove(entity.lastItem, 1);
|
entity.items.remove(entity.lastItem, 1);
|
||||||
Reference in New Issue
Block a user