Added RTG generator
Before Width: | Height: | Size: 279 B After Width: | Height: | Size: 220 B |
BIN
core/assets-raw/sprites/blocks/rtgenerator.png
Normal file
After Width: | Height: | Size: 295 B |
Before Width: | Height: | Size: 652 B After Width: | Height: | Size: 652 B |
@ -585,6 +585,13 @@ blocks/router
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/rtgenerator
|
||||
rotate: false
|
||||
xy: 421, 140
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/shadow
|
||||
rotate: false
|
||||
xy: 347, 153
|
||||
@ -594,7 +601,7 @@ blocks/shadow
|
||||
index: -1
|
||||
blocks/shieldgenerator
|
||||
rotate: false
|
||||
xy: 437, 283
|
||||
xy: 437, 273
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -608,21 +615,21 @@ blocks/shotgunturret
|
||||
index: -1
|
||||
blocks/shrub
|
||||
rotate: false
|
||||
xy: 437, 253
|
||||
xy: 301, 124
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/shrubshadow
|
||||
rotate: false
|
||||
xy: 301, 124
|
||||
xy: 311, 123
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/smelter
|
||||
rotate: false
|
||||
xy: 311, 123
|
||||
xy: 321, 123
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -636,28 +643,28 @@ blocks/sniperturret
|
||||
index: -1
|
||||
blocks/sorter
|
||||
rotate: false
|
||||
xy: 321, 123
|
||||
xy: 331, 123
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/steelconveyor
|
||||
rotate: false
|
||||
xy: 331, 123
|
||||
xy: 341, 123
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/steelconveyormove
|
||||
rotate: false
|
||||
xy: 341, 123
|
||||
xy: 447, 335
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/steelwall
|
||||
rotate: false
|
||||
xy: 447, 335
|
||||
xy: 457, 335
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -671,49 +678,49 @@ blocks/stone
|
||||
index: -1
|
||||
blocks/stone1
|
||||
rotate: false
|
||||
xy: 457, 335
|
||||
xy: 467, 335
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/stone2
|
||||
rotate: false
|
||||
xy: 467, 335
|
||||
xy: 477, 335
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/stone3
|
||||
rotate: false
|
||||
xy: 477, 335
|
||||
xy: 487, 335
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/stoneblock
|
||||
rotate: false
|
||||
xy: 487, 335
|
||||
xy: 431, 150
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/stoneblock2
|
||||
rotate: false
|
||||
xy: 431, 150
|
||||
xy: 431, 140
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/stoneblock3
|
||||
rotate: false
|
||||
xy: 431, 140
|
||||
xy: 490, 431
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/stonedrill
|
||||
rotate: false
|
||||
xy: 490, 431
|
||||
xy: 490, 421
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -727,28 +734,28 @@ blocks/stoneedge
|
||||
index: -1
|
||||
blocks/stonewall
|
||||
rotate: false
|
||||
xy: 490, 421
|
||||
xy: 486, 411
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/teleporter
|
||||
rotate: false
|
||||
xy: 486, 411
|
||||
xy: 486, 401
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/teleporter-top
|
||||
rotate: false
|
||||
xy: 486, 401
|
||||
xy: 486, 391
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/thermalgenerator
|
||||
rotate: false
|
||||
xy: 486, 391
|
||||
xy: 496, 411
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -769,49 +776,49 @@ blocks/titancannon-icon
|
||||
index: -1
|
||||
blocks/titanium1
|
||||
rotate: false
|
||||
xy: 496, 411
|
||||
xy: 496, 401
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/titanium2
|
||||
rotate: false
|
||||
xy: 496, 401
|
||||
xy: 496, 391
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/titanium3
|
||||
rotate: false
|
||||
xy: 496, 391
|
||||
xy: 493, 381
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/titaniumdrill
|
||||
rotate: false
|
||||
xy: 493, 381
|
||||
xy: 503, 381
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/titaniumpurifier
|
||||
rotate: false
|
||||
xy: 503, 381
|
||||
xy: 493, 371
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/titaniumshieldwall
|
||||
rotate: false
|
||||
xy: 493, 371
|
||||
xy: 503, 371
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/titaniumwall
|
||||
rotate: false
|
||||
xy: 503, 371
|
||||
xy: 499, 361
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -825,7 +832,7 @@ blocks/titaniumwall-large
|
||||
index: -1
|
||||
blocks/titaniumwall-large-icon
|
||||
rotate: false
|
||||
xy: 499, 361
|
||||
xy: 499, 351
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -839,35 +846,35 @@ blocks/turret
|
||||
index: -1
|
||||
blocks/uranium1
|
||||
rotate: false
|
||||
xy: 497, 331
|
||||
xy: 367, 136
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/uranium2
|
||||
rotate: false
|
||||
xy: 367, 136
|
||||
xy: 367, 126
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/uranium3
|
||||
rotate: false
|
||||
xy: 367, 126
|
||||
xy: 377, 131
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/uraniumdrill
|
||||
rotate: false
|
||||
xy: 377, 131
|
||||
xy: 387, 131
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
blocks/water
|
||||
rotate: false
|
||||
xy: 387, 131
|
||||
xy: 397, 131
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -1210,28 +1217,28 @@ mechs/player
|
||||
index: -1
|
||||
shell
|
||||
rotate: false
|
||||
xy: 421, 140
|
||||
xy: 437, 283
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
shot
|
||||
rotate: false
|
||||
xy: 437, 273
|
||||
xy: 437, 263
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
shot-long
|
||||
rotate: false
|
||||
xy: 437, 263
|
||||
xy: 437, 253
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
titanshell
|
||||
rotate: false
|
||||
xy: 499, 351
|
||||
xy: 499, 341
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
@ -1762,7 +1769,7 @@ weapons/railgun
|
||||
index: -1
|
||||
weapons/triblaster
|
||||
rotate: false
|
||||
xy: 499, 341
|
||||
xy: 497, 331
|
||||
size: 8, 8
|
||||
orig: 8, 8
|
||||
offset: 0, 0
|
||||
|
Before Width: | Height: | Size: 48 KiB After Width: | Height: | Size: 48 KiB |
@ -100,7 +100,7 @@ public class Control extends Module{
|
||||
|
||||
spawns = Array.with(
|
||||
new EnemySpawn(TitanEnemy.class){{
|
||||
after = 3;
|
||||
after = 4;
|
||||
spacing = 2;
|
||||
scaling = 5;
|
||||
}},
|
||||
|
@ -17,7 +17,6 @@ public enum Recipe{
|
||||
titaniumwalllarge(defense, DefenseBlocks.titaniumwalllarge, stack(Item.titanium, 8)),
|
||||
duriumwalllarge(defense, DefenseBlocks.diriumwalllarge, stack(Item.dirium, 8)),
|
||||
titaniumshieldwall(defense, DefenseBlocks.titaniumshieldwall, stack(Item.titanium, 2)),
|
||||
shieldgenerator(defense, DefenseBlocks.shieldgenerator, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
|
||||
conveyor(distribution, DistributionBlocks.conveyor, stack(Item.stone, 1)),
|
||||
steelconveyor(distribution, DistributionBlocks.steelconveyor, stack(Item.steel, 1)),
|
||||
@ -60,11 +59,15 @@ public enum Recipe{
|
||||
coalgenerator(power, ProductionBlocks.coalgenerator, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
thermalgenerator(power, ProductionBlocks.thermalgenerator, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
combustiongenerator(power, ProductionBlocks.combustiongenerator, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
rtgenerator(power, ProductionBlocks.rtgenerator, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
nuclearreactor(power, ProductionBlocks.nuclearReactor, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
powerbooster(power, DistributionBlocks.powerbooster, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
powerlaser(power, DistributionBlocks.powerlaser, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
powerlaserrouter(power, DistributionBlocks.powerlaserrouter, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
teleporter(power, DistributionBlocks.teleporter, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
|
||||
shieldgenerator(power, DefenseBlocks.shieldgenerator, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
|
||||
teleporter(distribution, DistributionBlocks.teleporter, stack(Item.titanium, 10), stack(Item.dirium, 10)),
|
||||
|
||||
healturret(power, DefenseBlocks.repairturret, stack(Item.iron, 30)),
|
||||
megahealturret(power, DefenseBlocks.megarepairturret, stack(Item.iron, 20), stack(Item.steel, 30)),
|
||||
|
@ -46,7 +46,9 @@ public class DistributionBlocks{
|
||||
|
||||
},
|
||||
liquidjunction = new LiquidJunction("liquidjunction"){
|
||||
|
||||
{
|
||||
formalName = "liquid junction";
|
||||
}
|
||||
},
|
||||
liquiditemjunction = new LiquidItemJunction("liquiditemjunction"){
|
||||
{
|
||||
|
@ -239,7 +239,7 @@ public class ProductionBlocks{
|
||||
formalName = "thermal generator";
|
||||
//TODO
|
||||
generateLiquid = Liquid.lava;
|
||||
inputLiquid = 5f;
|
||||
inputLiquid = 20f;
|
||||
generatePower = 1f;
|
||||
powerCapacity = 40f;
|
||||
}
|
||||
@ -254,7 +254,7 @@ public class ProductionBlocks{
|
||||
formalName = "combustion generator";
|
||||
//TODO
|
||||
generateLiquid = Liquid.oil;
|
||||
inputLiquid = 8f;
|
||||
inputLiquid = 14f;
|
||||
generatePower = 1f;
|
||||
powerCapacity = 40f;
|
||||
}
|
||||
@ -264,6 +264,21 @@ public class ProductionBlocks{
|
||||
return "Generates power from oil.";
|
||||
}
|
||||
},
|
||||
rtgenerator = new ItemPowerGenerator("rtgenerator"){
|
||||
{
|
||||
//TODO make this generate slowly
|
||||
formalName = "radioisotope generator";
|
||||
generateItem = Item.uranium;
|
||||
generateAmount = 10f;
|
||||
powerCapacity = 40f;
|
||||
generateTime = 50f;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String description(){
|
||||
return "Generates small amounts of power from uranium.";
|
||||
}
|
||||
},
|
||||
nuclearReactor = new LiquidItemPowerGenerator("nuclearreactor"){
|
||||
{
|
||||
//TODO
|
||||
|
@ -8,11 +8,13 @@ import io.anuke.mindustry.entities.TileEntity;
|
||||
import io.anuke.mindustry.resource.Item;
|
||||
import io.anuke.mindustry.world.Tile;
|
||||
import io.anuke.ucore.core.Effects;
|
||||
import io.anuke.ucore.core.Timers;
|
||||
|
||||
public class ItemPowerGenerator extends Generator{
|
||||
public int itemCapacity = 20;
|
||||
public Item generateItem;
|
||||
public float generateAmount;
|
||||
public float generateTime = 2f;
|
||||
|
||||
public ItemPowerGenerator(String name) {
|
||||
super(name);
|
||||
@ -37,7 +39,7 @@ public class ItemPowerGenerator extends Generator{
|
||||
public void update(Tile tile){
|
||||
PowerEntity entity = tile.entity();
|
||||
|
||||
if(entity.hasItem(generateItem) && tryAddPower(tile, generateAmount)){
|
||||
if(Timers.get(tile, "generate", generateTime) && entity.hasItem(generateItem) && tryAddPower(tile, generateAmount)){
|
||||
Effects.effect(Fx.generate, tile.entity);
|
||||
entity.removeItem(generateItem, 1);
|
||||
}
|
||||
|