Compare commits
27 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a83c0b2e9a | ||
|
|
8f853c8f18 | ||
|
|
b4071f6dcb | ||
|
|
6b70418861 | ||
|
|
de0235ad94 | ||
|
|
c278c632b3 | ||
|
|
6392330e70 | ||
|
|
160ae4e244 | ||
|
|
a6c9bd3182 | ||
|
|
801eadd8a8 | ||
|
|
211dab1297 | ||
|
|
0c3b39ffdc | ||
|
|
c31f88a318 | ||
|
|
e9eb981782 | ||
|
|
83bde8a781 | ||
|
|
52f352bf94 | ||
|
|
b419a96d69 | ||
|
|
eb3d5b62f5 | ||
|
|
1c5f578d88 | ||
|
|
db3aae1388 | ||
|
|
0b08eb72a6 | ||
|
|
cbc81376be | ||
|
|
27e9901d05 | ||
|
|
532c36677c | ||
|
|
0c20c6ecb7 | ||
|
|
fbb3240ebb | ||
|
|
855957b099 |
@@ -52,6 +52,11 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
config.depth = 0;
|
config.depth = 0;
|
||||||
Platform.instance = new Platform(){
|
Platform.instance = new Platform(){
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void hide(){
|
||||||
|
moveTaskToBack(true);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void openDonations(){
|
public void openDonations(){
|
||||||
showDonations();
|
showDonations();
|
||||||
|
|||||||
@@ -342,67 +342,49 @@ no = No
|
|||||||
info.title = Info
|
info.title = Info
|
||||||
error.title = [crimson]An error has occured
|
error.title = [crimson]An error has occured
|
||||||
error.crashtitle = An error has occured
|
error.crashtitle = An error has occured
|
||||||
blocks.outputspeed = Drill Speed: {0}/
|
blocks.input = Input
|
||||||
blocks.efficiency = Efficiency: {0}%
|
blocks.output = Output
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
blocks.booster = Booster
|
||||||
blocks.blockinfo = Block Info
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.powerbalance = Power: {0}
|
|
||||||
blocks.poweroutput = Power Output: {0}
|
|
||||||
blocks.powercapacity = Power Capacity
|
blocks.powercapacity = Power Capacity
|
||||||
blocks.powershot = Power/Shot
|
blocks.powershot = Power/Shot
|
||||||
blocks.targetsair = Targets Air
|
blocks.targetsair = Targets Air
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Range
|
blocks.shootrange = Range
|
||||||
blocks.size = Size
|
blocks.size = Size
|
||||||
blocks.liquidcapacity = Liquid Capacity
|
blocks.liquidcapacity = Liquid Capacity
|
||||||
blocks.maxitemssecond = Max Items
|
|
||||||
blocks.powerrange = Power Range
|
blocks.powerrange = Power Range
|
||||||
blocks.poweruse = Power Use
|
blocks.poweruse = Power Use
|
||||||
blocks.powerdamage = Power/Damage
|
blocks.powerdamage = Power/Damage
|
||||||
blocks.inputitemcapacity = Input Item Capacity
|
|
||||||
blocks.outputitemcapacity = Output Item Capacity
|
|
||||||
blocks.itemcapacity = Item Capacity
|
blocks.itemcapacity = Item Capacity
|
||||||
blocks.basepowergeneration = Base Power Generation
|
blocks.basepowergeneration = Base Power Generation
|
||||||
blocks.powertransferspeed = Power Transfer
|
blocks.productiontime = Production Time
|
||||||
blocks.craftspeed = Production Speed
|
|
||||||
blocks.repairtime = Block Full Repair Time
|
blocks.repairtime = Block Full Repair Time
|
||||||
|
blocks.speedincrease = Speed Increase
|
||||||
blocks.range = Range
|
blocks.range = Range
|
||||||
blocks.inputliquid = Input Liquid
|
|
||||||
blocks.inputliquidaux = Aux Liquid
|
|
||||||
blocks.inputitem = Input Item
|
|
||||||
blocks.inputitems = Input Items
|
|
||||||
blocks.outputitem = Output Item
|
|
||||||
blocks.drilltier = Drillables
|
blocks.drilltier = Drillables
|
||||||
blocks.drillspeed = Base Drill Speed
|
blocks.drillspeed = Base Drill Speed
|
||||||
|
blocks.boosteffect = Boost Effect
|
||||||
blocks.maxunits = Max Active Units
|
blocks.maxunits = Max Active Units
|
||||||
blocks.liquidoutput = Liquid Output
|
|
||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
|
||||||
blocks.liquiduse = Liquid Use
|
|
||||||
blocks.coolant = Coolant
|
|
||||||
blocks.liquid = Liquid
|
|
||||||
blocks.coolantuse = Coolant Use
|
|
||||||
blocks.inputliquidfuel = Fuel Liquid
|
|
||||||
blocks.liquidfueluse = Liquid Fuel Use
|
|
||||||
blocks.boostitem = Boost Item
|
|
||||||
blocks.boostliquid = Boost Liquid
|
|
||||||
blocks.health = Health
|
blocks.health = Health
|
||||||
blocks.heat = Heat
|
|
||||||
blocks.power = Power
|
|
||||||
blocks.progress = Build Progress
|
|
||||||
blocks.spawned = Units: {0}/{1}
|
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
|
||||||
blocks.inaccuracy = Inaccuracy
|
blocks.inaccuracy = Inaccuracy
|
||||||
blocks.shots = Shots
|
blocks.shots = Shots
|
||||||
blocks.reload = Shots/Second
|
blocks.reload = Shots/Second
|
||||||
blocks.inputfuel = Fuel
|
|
||||||
blocks.fuelburntime = Fuel Burn Time
|
|
||||||
blocks.inputcapacity = Input capacity
|
|
||||||
blocks.outputcapacity = Output capacity
|
|
||||||
blocks.ammo = Ammo
|
blocks.ammo = Ammo
|
||||||
|
|
||||||
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
|
bar.efficiency = Efficiency: {0}%
|
||||||
|
bar.powerbalance = Power: {0}
|
||||||
|
bar.poweroutput = Power Output: {0}
|
||||||
|
bar.items = Items: {0}
|
||||||
|
bar.liquid = Liquid
|
||||||
|
bar.heat = Heat
|
||||||
|
bar.power = Power
|
||||||
|
bar.progress = Build Progress
|
||||||
|
bar.spawned = Units: {0}/{1}
|
||||||
|
|
||||||
bullet.damage = [stat]{0}[lightgray] damage
|
bullet.damage = [stat]{0}[lightgray] damage
|
||||||
bullet.splashdamage = [stat]{0}[lightgray] area dmg ~[stat] {1}[lightgray] tiles
|
bullet.splashdamage = [stat]{0}[lightgray] area dmg ~[stat] {1}[lightgray] tiles
|
||||||
bullet.incendiary = [stat]incendiary
|
bullet.incendiary = [stat]incendiary
|
||||||
@@ -423,6 +405,9 @@ unit.liquidunits = liquid units
|
|||||||
unit.powerunits = power units
|
unit.powerunits = power units
|
||||||
unit.degrees = degrees
|
unit.degrees = degrees
|
||||||
unit.seconds = seconds
|
unit.seconds = seconds
|
||||||
|
unit.persecond = /sec
|
||||||
|
unit.timesspeed = x speed
|
||||||
|
unit.percent = %
|
||||||
unit.items = items
|
unit.items = items
|
||||||
category.general = General
|
category.general = General
|
||||||
category.power = Power
|
category.power = Power
|
||||||
@@ -565,7 +550,7 @@ liquid.oil.name = Oil
|
|||||||
liquid.cryofluid.name = Cryofluid
|
liquid.cryofluid.name = Cryofluid
|
||||||
mech.alpha-mech.name = Alpha
|
mech.alpha-mech.name = Alpha
|
||||||
mech.alpha-mech.weapon = Heavy Repeater
|
mech.alpha-mech.weapon = Heavy Repeater
|
||||||
mech.alpha-mech.ability = None
|
mech.alpha-mech.ability = Regeneration
|
||||||
mech.alpha-mech.description = The standard mech. Has decent speed and damage output.
|
mech.alpha-mech.description = The standard mech. Has decent speed and damage output.
|
||||||
mech.delta-mech.name = Delta
|
mech.delta-mech.name = Delta
|
||||||
mech.delta-mech.weapon = Arc Generator
|
mech.delta-mech.weapon = Arc Generator
|
||||||
@@ -600,9 +585,10 @@ unit.speed = [LIGHT_GRAY]Speed: {0}
|
|||||||
mech.weapon = [LIGHT_GRAY]Weapon: {0}
|
mech.weapon = [LIGHT_GRAY]Weapon: {0}
|
||||||
mech.health = [LIGHT_GRAY]Health: {0}
|
mech.health = [LIGHT_GRAY]Health: {0}
|
||||||
mech.itemcapacity = [LIGHT_GRAY]Item Capacity: {0}
|
mech.itemcapacity = [LIGHT_GRAY]Item Capacity: {0}
|
||||||
mech.minespeed = [LIGHT_GRAY]Mining Speed: {0}
|
mech.minespeed = [LIGHT_GRAY]Mining Speed: {0}%
|
||||||
mech.minepower = [LIGHT_GRAY]Mining Power: {0}
|
mech.minepower = [LIGHT_GRAY]Mining Power: {0}
|
||||||
mech.ability = [LIGHT_GRAY]Ability: {0}
|
mech.ability = [LIGHT_GRAY]Ability: {0}
|
||||||
|
mech.buildspeed = [LIGHT_GRAY]Building Speed: {0}%
|
||||||
liquid.heatcapacity = [LIGHT_GRAY]Heat Capacity: {0}
|
liquid.heatcapacity = [LIGHT_GRAY]Heat Capacity: {0}
|
||||||
liquid.viscosity = [LIGHT_GRAY]Viscosity: {0}
|
liquid.viscosity = [LIGHT_GRAY]Viscosity: {0}
|
||||||
liquid.temperature = [LIGHT_GRAY]Temperature: {0}
|
liquid.temperature = [LIGHT_GRAY]Temperature: {0}
|
||||||
@@ -864,7 +850,7 @@ block.silicon-smelter.description = Reduces sand with highly pure coal in order
|
|||||||
block.plastanium-compressor.description = Produces plastanium from oil and titanium.
|
block.plastanium-compressor.description = Produces plastanium from oil and titanium.
|
||||||
block.phase-weaver.description = Produces phase fabric from radioactive thorium and high amounts of sand.
|
block.phase-weaver.description = Produces phase fabric from radioactive thorium and high amounts of sand.
|
||||||
block.alloy-smelter.description = Produces surge alloy from titanium, lead, silicon and copper.
|
block.alloy-smelter.description = Produces surge alloy from titanium, lead, silicon and copper.
|
||||||
block.pulverizer.description = Crushes stone into sand. Useful when there is a lack of natural sand.
|
block.pulverizer.description = Crushes scrap into sand. Useful when there is a lack of natural sand.
|
||||||
block.pyratite-mixer.description = Mixes coal, lead and sand into highly flammable pyratite.
|
block.pyratite-mixer.description = Mixes coal, lead and sand into highly flammable pyratite.
|
||||||
block.blast-mixer.description = Uses oil for transforming pyratite into the less flammable but more explosive blast compound.
|
block.blast-mixer.description = Uses oil for transforming pyratite into the less flammable but more explosive blast compound.
|
||||||
block.cryofluidmixer.description = Combines water and titanium into cryofluid which is much more efficient for cooling.
|
block.cryofluidmixer.description = Combines water and titanium into cryofluid which is much more efficient for cooling.
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Ne
|
|||||||
info.title = Informace
|
info.title = Informace
|
||||||
error.title = [crimson]Objevila se chyba
|
error.title = [crimson]Objevila se chyba
|
||||||
error.crashtitle = Objevila se chyba
|
error.crashtitle = Objevila se chyba
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Informace o bloku
|
blocks.blockinfo = Informace o bloku
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Kapacita energie
|
blocks.powercapacity = Kapacita energie
|
||||||
blocks.powershot = Energie na výstřel
|
blocks.powershot = Energie na výstřel
|
||||||
blocks.targetsair = Zaměřuje vzdušné jednotky
|
blocks.targetsair = Zaměřuje vzdušné jednotky
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Dostřel
|
blocks.shootrange = Dostřel
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Výstup tekutin
|
|||||||
blocks.liquidoutputspeed = Rychlost výstupu tekutin
|
blocks.liquidoutputspeed = Rychlost výstupu tekutin
|
||||||
blocks.liquiduse = Spotřebuje tekutin
|
blocks.liquiduse = Spotřebuje tekutin
|
||||||
blocks.coolant = Chlazení
|
blocks.coolant = Chlazení
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Spotřeba chlazení
|
blocks.coolantuse = Spotřeba chlazení
|
||||||
blocks.inputliquidfuel = Palivo-tekutina
|
blocks.inputliquidfuel = Palivo-tekutina
|
||||||
blocks.liquidfueluse = Spotřeba Paliva-tekutiny
|
blocks.liquidfueluse = Spotřeba Paliva-tekutiny
|
||||||
blocks.boostitem = Předmět pro zrychlení
|
blocks.boostitem = Předmět pro zrychlení
|
||||||
blocks.boostliquid = Tekutina pro zrychlení
|
blocks.boostliquid = Tekutina pro zrychlení
|
||||||
blocks.health = Životy
|
blocks.health = Životy
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Nepřesnost/výchylka
|
blocks.inaccuracy = Nepřesnost/výchylka
|
||||||
blocks.shots = Střely
|
blocks.shots = Střely
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Nein
|
|||||||
info.title = [accent]Info
|
info.title = [accent]Info
|
||||||
error.title = [crimson] Ein Fehler ist aufgetreten
|
error.title = [crimson] Ein Fehler ist aufgetreten
|
||||||
error.crashtitle = Ein Fehler ist aufgetreten!
|
error.crashtitle = Ein Fehler ist aufgetreten!
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Blockinfo:
|
blocks.blockinfo = Blockinfo:
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Kapazität
|
blocks.powercapacity = Kapazität
|
||||||
blocks.powershot = Stromverbrauch/Schuss
|
blocks.powershot = Stromverbrauch/Schuss
|
||||||
blocks.targetsair = Visiert Luft Einheiten an
|
blocks.targetsair = Visiert Luft Einheiten an
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Reichweite
|
blocks.shootrange = Reichweite
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Erzeugte Flüssigkeit
|
|||||||
blocks.liquidoutputspeed = Ausgabegeschwindigkeit
|
blocks.liquidoutputspeed = Ausgabegeschwindigkeit
|
||||||
blocks.liquiduse = Flüssigkeitsverbrauch
|
blocks.liquiduse = Flüssigkeitsverbrauch
|
||||||
blocks.coolant = Kühlmittel
|
blocks.coolant = Kühlmittel
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Kühlmittelverbrauch
|
blocks.coolantuse = Kühlmittelverbrauch
|
||||||
blocks.inputliquidfuel = Kraftstoff
|
blocks.inputliquidfuel = Kraftstoff
|
||||||
blocks.liquidfueluse = Kraftstoffverbrauch
|
blocks.liquidfueluse = Kraftstoffverbrauch
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Lebenspunkte
|
blocks.health = Lebenspunkte
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Ungenauigkeit
|
blocks.inaccuracy = Ungenauigkeit
|
||||||
blocks.shots = Schüsse
|
blocks.shots = Schüsse
|
||||||
|
|||||||
@@ -1,919 +0,0 @@
|
|||||||
credits.text = Δημιουργία: [ROYAL]Anuken[] - [SKY]anukendev@gmail.com[]
|
|
||||||
credits = Επαίνοι
|
|
||||||
contributors = Μεταφραστές και Συνεισφέροντες
|
|
||||||
discord = Συμμετοχή στο discord του Mindustry!
|
|
||||||
link.discord.description = Το επίσημο discord chatroom του Mindustry
|
|
||||||
link.github.description = Πηγαίος κώδικας του Παιχνιδιού
|
|
||||||
link.dev-builds.description = Ασταθείς εκδόσεις παιχνιδιού
|
|
||||||
link.trello.description = Ο επίσημος πίνακας trello του παιχνιδιού για τις προσχεδιασμένες του αλλαγές
|
|
||||||
link.itch.io.description = Η σελίδα itch.io με τις εκδόσεις του παιχνιδιού για τους υπολογιστές και περιηγητές
|
|
||||||
link.google-play.description = Google Play store καταχώριση
|
|
||||||
link.wiki.description = Η επίσημη σελίδα Wiki του Mindustry
|
|
||||||
linkfail = Αποτυχία ανοίγματος συνδέσμου!\nΤο URL αντιγράφτηκε στο πρόχειρο.
|
|
||||||
screenshot = Το στιγμιότυπο αποθηκεύτηκε στο {0}
|
|
||||||
gameover = Τέλος Παιχνιδιού
|
|
||||||
gameover.pvp = Η[accent] {0}[] ομάδα είναι νικήτρια!
|
|
||||||
highscore = [accent]Καινούργιο υψηλότερο σκόρ!
|
|
||||||
stat.wave = Waves Defeated:[accent] {0}
|
|
||||||
stat.enemiesDestroyed = Enemies Destroyed:[accent] {0}
|
|
||||||
stat.built = Buildings Built:[accent] {0}
|
|
||||||
stat.destroyed = Buildings Destroyed:[accent] {0}
|
|
||||||
stat.deconstructed = Buildings Deconstructed:[accent] {0}
|
|
||||||
stat.delivered = Resources Launched:
|
|
||||||
stat.rank = Final Rank: [accent]{0}
|
|
||||||
placeline = You have selected a block.\nYou can[accent] place in a line[] by[accent] holding down your finger for a few seconds[] and dragging in a direction.\n\n[scarlet]DO IT.
|
|
||||||
removearea = You have selected removal mode.\nYou can[accent] remove blocks in a rectangle[] by[accent] holding down your finger for a few seconds[] and dragging.\n\n[scarlet]DO IT.
|
|
||||||
launcheditems = [accent]Launched Items
|
|
||||||
map.delete = Είσαι σίγουρος οτι θέλεις να διαγράψεις τον χάρτη "[accent]{0}[]"?
|
|
||||||
level.highscore = Υψηλότερο σκόρ: [accent]{0}
|
|
||||||
level.select = Level Select
|
|
||||||
level.mode = Είδος Παιχνιδιού:
|
|
||||||
showagain = Μην το ξαναεμφανήσεις στην επόμενη συνεδρία
|
|
||||||
coreattack = < Ο πυρήνας είναι υπό επίθεση! >
|
|
||||||
nearpoint = [[ [scarlet]LEAVE DROP POINT IMMEDIATELY[] ]\nannihilation imminent
|
|
||||||
outofbounds = [[ OUT OF BOUNDS ]\n[]self-destruct in {0}
|
|
||||||
database = Core Database
|
|
||||||
savegame = Αποθήκευση Παιχνιδιού
|
|
||||||
loadgame = Φόρτωση Παιχνιδιού
|
|
||||||
joingame = Συμμετοχή σε Παιχνίδι
|
|
||||||
addplayers = Προσθήκη/Αφαίρεση Παικτών
|
|
||||||
customgame = Προσαρμοσμένο Παιχνίδι
|
|
||||||
newgame = New Game
|
|
||||||
none = <none>
|
|
||||||
close = Κλείσιμο
|
|
||||||
quit = Έξοδος
|
|
||||||
maps = Χάρτες
|
|
||||||
continue = Συνέχεια
|
|
||||||
maps.none = [LIGHT_GRAY]Δεν βρέθηκαν Χάρτες!
|
|
||||||
about.button = Σχετικά
|
|
||||||
name = Όνομα:
|
|
||||||
noname = Διάλεξε[accent] όνομα παίκτη[] πρώτα.
|
|
||||||
filename = Όνομα Αρχείου:
|
|
||||||
unlocked = Ανακάλυψη Καινούργας Δομής!
|
|
||||||
completed = [accent]Completed
|
|
||||||
techtree = Tech Tree
|
|
||||||
research.list = [LIGHT_GRAY]Research:
|
|
||||||
research = Research
|
|
||||||
researched = [LIGHT_GRAY]{0} researched.
|
|
||||||
players = {0} παίκτες ενεργοί
|
|
||||||
players.single = {0} παίκτης ενεργός
|
|
||||||
server.closing = [accent]Απενεργοποίηση Εξυπηρετητή...
|
|
||||||
server.kicked.kick = Διώχτηκες απο τον server!
|
|
||||||
server.kicked.serverClose = Ο server έκλεισε.
|
|
||||||
server.kicked.clientOutdated = Παλαιομένος client! Αναβάθμησε την έκδοση του παιχνιδιού!
|
|
||||||
server.kicked.serverOutdated = Παλαιομένος server! Ζήτα απο τον οικοδεσπότη να αναβαθμήσει την έκδοσή του!
|
|
||||||
server.kicked.banned = Είσαι μπλοκαρισμένος απο αυτόν τον server.
|
|
||||||
server.kicked.recentKick = Διώχτηκες πρόσφατα.\nΠερίμενε λίγο πριν ξανασυνδεθείς...
|
|
||||||
server.kicked.nameInUse = Υπάρχει ήδη κάποιος με αυτό το όνομα\nστον server.
|
|
||||||
server.kicked.nameEmpty = Το επιλεγμένο σου όνομα είναι άκυρο.
|
|
||||||
server.kicked.idInUse = Βρίσκεσε ήδη σε αυτόν τον server! Η σύνδεση με δύο λογαριασμούς απαγορεύεται.
|
|
||||||
server.kicked.customClient = Αυτός ο server δεν υποστηρίζει προσαρμοσμένες εκδοχές. Κατέβασε μια αυθεντική έκδοση.
|
|
||||||
server.kicked.gameover = Game over!
|
|
||||||
host.info = Το κουμπί [accent]host[] "σερβίρει" εναν server (εξυπηρετητή) στην θύρα [scarlet]6567[]. \nΌλα το άτομα στο ίδιο [LIGHT_GRAY]wifi ή τοπικό δίκτυο[] θα μπορούν να δούν τον server σου στην λίστα server τους.\n\nΑν θέλεις να μπορούν να συνδεθούν σε αυτόν απο οποιαδοίποτε διεύθυνση IP, Το [accent]port forwarding[] είναι απαραίτητο.\n\n[LIGHT_GRAY]Σημείωση: Αν κάποιος αντιμετωπίζει πρόβλημα στην σύνδεση στο παιχνίδι τοπικού δικτύου σου (LAN), σιγουρέψου οτι έχεις επιτρέψει στο Mindustry να ελέγχει το τοπικό σου δίκτυο στις ρυθμίσεις του τείχους προστασίας.
|
|
||||||
join.info = Εδώ, μπορείς να εισάγεις μια [accent]διεύθυνση (IP) server[] για να συνδεθείς σε αυτήν, ή να ανακαλύψεις servers [accent]τοπικού δικτύου[] και να συνδεθείς.\nΥποστηρίζεται και το LAN και το WAN.\n\n[LIGHT_GRAY]Σημείωση: Δεν υπάρχει αυτόματη παγκόσμια λίστα server; Αν θέλεις να συνδεθείς σε κάποιον μέσω IP, πρέπει να ρωτήσεις την διεύθυνσή τους.
|
|
||||||
hostserver = Δημιούργησε Παιχνίδι
|
|
||||||
hostserver.mobile = Δημιούργησε\nΠαιχνίδι
|
|
||||||
host = Δημιουργία
|
|
||||||
hosting = [accent]Άνοιγμα εξυπηρετητή...
|
|
||||||
hosts.refresh = Ανανέωση
|
|
||||||
hosts.discovering = Ανακάλυψη παιχνιδιών LAN
|
|
||||||
server.refreshing = Ανανέωση server
|
|
||||||
hosts.none = [lightgray]Δεν βρέθηκαν τοπικά παιχνίδια!
|
|
||||||
host.invalid = [scarlet]Δεν μπορείς να συνδεθείς στον host.
|
|
||||||
trace = Ανίχνευση Παίκτη
|
|
||||||
trace.playername = Όνομα Παίκτη: [accent]{0}
|
|
||||||
trace.ip = Διεύθυνση: [accent]{0}
|
|
||||||
trace.id = Μοναδική ID: [accent]{0}
|
|
||||||
trace.android = Android Client: [accent]{0}
|
|
||||||
trace.modclient = Προσαρμοσμένος Client: [accent]{0}
|
|
||||||
trace.totalblocksbroken = Συνολικά κατεστραμένα τετράγωνα: [accent]{0}
|
|
||||||
trace.structureblocksbroken = Συνολικές κατεστραμένες δομές: [accent]{0}
|
|
||||||
trace.lastblockbroken = Τελευταίο κατεστραμένο τετράγωνο: [accent]{0}
|
|
||||||
trace.totalblocksplaced = Σύνολο τοποθετημένων τετραγώνων: [accent]{0}
|
|
||||||
trace.lastblockplaced = Τελευταίο τοποθετημένο τετράγωνο: [accent]{0}
|
|
||||||
invalidid = Άκυρο client ID! Υπέβαλε αναφορά σφάλματος.
|
|
||||||
server.bans = Bans
|
|
||||||
server.bans.none = Δεν βρέθηκε κανένας banned παίκτης!
|
|
||||||
server.admins = Διαχειριστές
|
|
||||||
server.admins.none = Δεν βρέθηκαν διαχειριστές!
|
|
||||||
server.add = Προσθήκη Server
|
|
||||||
server.delete = Είσε σίγουρος οτι θέλεις να διαγράψεις αυτόν τον server;
|
|
||||||
server.hostname = Host: {0}
|
|
||||||
server.edit = Προσαρμογή Server
|
|
||||||
server.outdated = [crimson]Παλαιομένος Server![]
|
|
||||||
server.outdated.client = [crimson]Παλαιομένος Client![]
|
|
||||||
server.version = [lightgray]Έκδοση: {0} {1}
|
|
||||||
server.custombuild = [yellow]Προσαρμοσμένο Build
|
|
||||||
confirmban = Είσαι σίγουρος οτι θέλεις να διώξεις μόνιμα αυτόν τον παίκτη;
|
|
||||||
confirmkick = Είσαι σίγουρος οτι θέλεις να διώξεις αυτόν τον παίκτη;
|
|
||||||
confirmunban = Είσαι σίγουρος οτι θέλεις να επιτρέψεις την είσοδο αυτού του παίκτη ξανα;
|
|
||||||
confirmadmin = Είσαι σίγουρος οτι θέλεις να χρήσεις αυτόν τον παίκτη ως διαχειριστή;
|
|
||||||
confirmunadmin = Είσαι σίγουρος οτι θέλεις να αφαιρέσεις αυτόν τον παίκτη απο την λίστα διαχειριστών;
|
|
||||||
joingame.title = Συμμετοχή σε Παιχνίδι
|
|
||||||
joingame.ip = Διεύθυνση IP:
|
|
||||||
disconnect = Αποσυνδεθήκατε.
|
|
||||||
disconnect.data = Αποτυχία φώρτωσης δεδομένων κόσμου!
|
|
||||||
connecting = [accent]Σύνδεση...
|
|
||||||
connecting.data = [accent]Φώρτωση δεδομένων κόσμου...
|
|
||||||
server.port = Θύρα:
|
|
||||||
server.addressinuse = Η διεύθυνση βρήσκεται ήδη σε χρήση!
|
|
||||||
server.invalidport = Άκυρος αριθμός θύρας!
|
|
||||||
server.error = [crimson]Αποτυχία εκκίνησης εξυπηρετητή: [accent]{0}
|
|
||||||
save.old = Αυτά τα δεδομένα ανήκουν σε μια παλιότερη έκδοση του παιχνιδιού, και δεν μπορούν πλέον να χρησιμοποιηθούν.\n\n[LIGHT_GRAY]Η υποστήριξη ανάδρομης αποθήκευσης θα ενσωματωθεί στην πλήρη έκδοση 4.0.
|
|
||||||
save.new = Νέα αποθήκευση
|
|
||||||
save.overwrite = Είσαι σίγουρος οτι θέλεις να πανωγράψεις αυτήν την\nθέση αποθήκευσης;
|
|
||||||
overwrite = Πανώγραψε
|
|
||||||
save.none = Δεν βρέθηκαν δεδομένα!
|
|
||||||
saveload = [accent]Αποθήκευση...
|
|
||||||
savefail = Αποτυχία Αποθήκευσης!
|
|
||||||
save.delete.confirm = Είσαι σίγουρος οτι θέλεις να διαγράψεις αυτήν την αποθήκη;
|
|
||||||
save.delete = Διαγραφή
|
|
||||||
save.export = Εξαγωγή Δεδομένων
|
|
||||||
save.import.invalid = [accent]Αυτά τα δεδομένα είναι άκυρα!
|
|
||||||
save.import.fail = [crimson]Αποτυχία εισαγωγής δεδομένων: [accent]{0}
|
|
||||||
save.export.fail = [crimson]Αποτυχία εξαγωγής δεδομένων: [accent]{0}
|
|
||||||
save.import = Εισαγωγή Δεδομένων
|
|
||||||
save.newslot = Όνομα Αποθήκευσης:
|
|
||||||
save.rename = Μετονομασία
|
|
||||||
save.rename.text = Νέο Όνομα:
|
|
||||||
selectslot = Επιλογή Αποθήκης.
|
|
||||||
slot = [accent]Κελί {0}
|
|
||||||
save.corrupted = [accent]Το αρχείο αποθήκευσης είναι κατεστραμένο ή άκυρο!\nΑν είχες πρόσφατα αναβαθμίσει το παιχνίδι, τότε είναι πιθανώς εξ' αιτίας αλλαγής στον τρόπο αποθήκευσης και [scarlet]όχι[] προβλήματος.
|
|
||||||
empty = <καινό>
|
|
||||||
on = Ανοικτό
|
|
||||||
off = Κλειστό
|
|
||||||
save.autosave = Αυτόματη Αποθήκευση: {0}
|
|
||||||
save.map = Χάρτης: {0}
|
|
||||||
save.wave = Κύμα {0}
|
|
||||||
save.difficulty = Δυσκολία: {0}
|
|
||||||
save.date = Τελευταία Αποθήκευση: {0}
|
|
||||||
save.playtime = Χρόνος Παιχνιδιού: {0}
|
|
||||||
warning = Warning.
|
|
||||||
confirm = Επιβεβαίωση
|
|
||||||
delete = Διαγραφή
|
|
||||||
ok = OK
|
|
||||||
open = Άνοιγμα
|
|
||||||
cancel = Ακύρωση
|
|
||||||
openlink = Άνοιγμα Συνδέσμου
|
|
||||||
copylink = Αντιγραφή Συνδέσμου
|
|
||||||
back = Πίσω
|
|
||||||
quit.confirm = Είσαι σίγουρος οτι θέλεις να εγκαταλήψεις;
|
|
||||||
changelog.title = Αρχείο Αλλαγών
|
|
||||||
changelog.loading = Getting changelog...
|
|
||||||
changelog.error.android = [accent]Note that the changelog sometimes does not work on Android 4.4 and below!\nThis is due to an internal Android bug.
|
|
||||||
changelog.error.ios = [accent]The changelog is currently not supported in iOS.
|
|
||||||
changelog.error = [scarlet]Error getting changelog!\nCheck your internet connection.
|
|
||||||
changelog.current = [yellow][[Current version]
|
|
||||||
changelog.latest = [accent][[Latest version]
|
|
||||||
loading = [accent]Loading...
|
|
||||||
saving = [accent]Saving...
|
|
||||||
wave = [accent]Wave {0}
|
|
||||||
wave.waiting = [LIGHT_GRAY]Wave in {0}
|
|
||||||
waiting = [LIGHT_GRAY]Waiting...
|
|
||||||
waiting.players = Waiting for players...
|
|
||||||
wave.enemies = [LIGHT_GRAY]{0} Enemies Remaining
|
|
||||||
wave.enemy = [LIGHT_GRAY]{0} Enemy Remaining
|
|
||||||
loadimage = Load Image
|
|
||||||
saveimage = Save Image
|
|
||||||
unknown = Unknown
|
|
||||||
custom = Custom
|
|
||||||
builtin = Built-In
|
|
||||||
map.delete.confirm = Are you sure you want to delete this map? This action cannot be undone!
|
|
||||||
map.random = [accent]Random Map
|
|
||||||
map.nospawn = This map does not have any cores for the player to spawn in! Add a[ROYAL] blue[] core to this map in the editor.
|
|
||||||
map.nospawn.pvp = This map does not have any enemy cores for player to spawn into! Add[SCARLET] red[] cores to this map in the editor.
|
|
||||||
map.nospawn.attack = This map does not have any enemy cores for player to attack! Add[SCARLET] red[] cores to this map in the editor.
|
|
||||||
map.invalid = Error loading map: corrupted or invalid map file.
|
|
||||||
editor.brush = Brush
|
|
||||||
editor.openin = Open In Editor
|
|
||||||
editor.oregen = Ore Generation
|
|
||||||
editor.oregen.info = Ore Generation:
|
|
||||||
editor.mapinfo = Map Info
|
|
||||||
editor.author = Author:
|
|
||||||
editor.description = Description:
|
|
||||||
editor.waves = Waves:
|
|
||||||
waves.title = Waves
|
|
||||||
waves.remove = Remove
|
|
||||||
waves.never = <never>
|
|
||||||
waves.every = every
|
|
||||||
waves.waves = wave(s)
|
|
||||||
waves.perspawn = per spawn
|
|
||||||
waves.to = to
|
|
||||||
waves.boss = Boss
|
|
||||||
waves.preview = Preview
|
|
||||||
waves.edit = Edit...
|
|
||||||
waves.copy = Copy to Clipboard
|
|
||||||
waves.load = Load from Clipboard
|
|
||||||
waves.invalid = Invalid waves in clipboard.
|
|
||||||
waves.copied = Waves copied.
|
|
||||||
editor.default = [LIGHT_GRAY]<Default>
|
|
||||||
edit = Edit...
|
|
||||||
editor.name = Name:
|
|
||||||
editor.teams = Teams
|
|
||||||
editor.elevation = Elevation
|
|
||||||
editor.errorload = Error loading file:\n[accent]{0}
|
|
||||||
editor.errorsave = Error saving file:\n[accent]{0}
|
|
||||||
editor.errorname = Map has no name defined.
|
|
||||||
editor.update = Update
|
|
||||||
editor.randomize = Randomize
|
|
||||||
editor.apply = Apply
|
|
||||||
editor.generate = Generate
|
|
||||||
editor.resize = Resize
|
|
||||||
editor.loadmap = Load Map
|
|
||||||
editor.savemap = Save Map
|
|
||||||
editor.saved = Saved!
|
|
||||||
editor.save.noname = Your map does not have a name! Set one in the 'map info' menu.
|
|
||||||
editor.save.overwrite = Your map overwrites a built-in map! Pick a different name in the 'map info' menu.
|
|
||||||
editor.import.exists = [scarlet]Unable to import:[] a built-in map named '{0}' already exists!
|
|
||||||
editor.import = Import...
|
|
||||||
editor.importmap = Import Map
|
|
||||||
editor.importmap.description = Import an already existing map
|
|
||||||
editor.importfile = Import File
|
|
||||||
editor.importfile.description = Import an external map file
|
|
||||||
editor.importimage = Import Legacy Image
|
|
||||||
editor.importimage.description = Import an external map image file
|
|
||||||
editor.export = Export...
|
|
||||||
editor.exportfile = Export File
|
|
||||||
editor.exportfile.description = Export a map file
|
|
||||||
editor.exportimage = Export Terrain Image
|
|
||||||
editor.exportimage.description = Export a map image file
|
|
||||||
editor.loadimage = Import Terrain
|
|
||||||
editor.saveimage = Export Terrain
|
|
||||||
editor.unsaved = [scarlet]You have unsaved changes![]\nAre you sure you want to exit?
|
|
||||||
editor.resizemap = Resize Map
|
|
||||||
editor.mapname = Map Name:
|
|
||||||
editor.overwrite = [accent]Warning!\nThis overwrites an existing map.
|
|
||||||
editor.overwrite.confirm = [scarlet]Warning![] A map with this name already exists. Are you sure you want to overwrite it?
|
|
||||||
editor.selectmap = Select a map to load:
|
|
||||||
filters.empty = [LIGHT_GRAY]No filters! Add one with the button below.
|
|
||||||
filter.distort = Distort
|
|
||||||
filter.noise = Noise
|
|
||||||
filter.ore = Ore
|
|
||||||
filter.rivernoise = River Noise
|
|
||||||
filter.scatter = Scatter
|
|
||||||
filter.terrain = Terrain
|
|
||||||
filter.option.scale = Scale
|
|
||||||
filter.option.chance = Chance
|
|
||||||
filter.option.mag = Magnitude
|
|
||||||
filter.option.threshold = Threshold
|
|
||||||
filter.option.circle-scale = Circle Scale
|
|
||||||
filter.option.octaves = Octaves
|
|
||||||
filter.option.falloff = Falloff
|
|
||||||
filter.option.block = Block
|
|
||||||
filter.option.floor = Floor
|
|
||||||
filter.option.wall = Wall
|
|
||||||
filter.option.ore = Ore
|
|
||||||
filter.option.floor2 = Secondary Floor
|
|
||||||
filter.option.threshold2 = Secondary Threshold
|
|
||||||
width = Width:
|
|
||||||
height = Height:
|
|
||||||
menu = Menu
|
|
||||||
play = Play
|
|
||||||
load = Load
|
|
||||||
save = Save
|
|
||||||
fps = FPS: {0}
|
|
||||||
tps = TPS: {0}
|
|
||||||
ping = Ping: {0}ms
|
|
||||||
language.restart = Please restart your game for the language settings to take effect.
|
|
||||||
settings = Settings
|
|
||||||
tutorial = Tutorial
|
|
||||||
editor = Editor
|
|
||||||
mapeditor = Map Editor
|
|
||||||
donate = Donate
|
|
||||||
abandon = Abandon
|
|
||||||
abandon.text = This zone and all its resources will be lost to the enemy.
|
|
||||||
locked = Locked
|
|
||||||
complete = [LIGHT_GRAY]Reach:
|
|
||||||
zone.requirement = Wave {0} in zone {1}
|
|
||||||
resume = Resume Zone:\n[LIGHT_GRAY]{0}
|
|
||||||
bestwave = [LIGHT_GRAY]Best Wave: {0}
|
|
||||||
launch = < LAUNCH >
|
|
||||||
launch.title = Launch Successful
|
|
||||||
launch.next = [LIGHT_GRAY]next opportunity at wave {0}
|
|
||||||
launch.unable = [scarlet]Unable to LAUNCH.[] {0} Enemies.
|
|
||||||
launch.confirm = This will launch all resources in your core.\nYou will not be able to return to this base.
|
|
||||||
uncover = Uncover
|
|
||||||
configure = Configure Loadout
|
|
||||||
configure.locked = [LIGHT_GRAY]Unlock configuring loadout:\nWave {0}.
|
|
||||||
zone.unlocked = [LIGHT_GRAY]{0} unlocked.
|
|
||||||
zone.requirement.complete = Wave {0} reached:\n{1} zone requirements met.
|
|
||||||
zone.config.complete = Wave {0} reached:\nLoadout config unlocked.
|
|
||||||
zone.resources = Resources Detected:
|
|
||||||
add = Add...
|
|
||||||
boss.health = Boss Health
|
|
||||||
connectfail = [crimson]Failed to connect to server:\n\n[accent]{0}
|
|
||||||
error.unreachable = Server unreachable.\nIs the address spelled correctly?
|
|
||||||
error.invalidaddress = Invalid address.
|
|
||||||
error.timedout = Timed out!\nMake sure the host has port forwarding set up, and that the address is correct!
|
|
||||||
error.mismatch = Packet error:\npossible client/server version mismatch.\nMake sure you and the host have the latest version of Mindustry!
|
|
||||||
error.alreadyconnected = Already connected.
|
|
||||||
error.mapnotfound = Map file not found!
|
|
||||||
error.io = Network I/O error.
|
|
||||||
error.any = Unknown network error.
|
|
||||||
zone.groundZero.name = Ground Zero
|
|
||||||
zone.craters.name = The Craters
|
|
||||||
zone.frozenForest.name = Frozen Forest
|
|
||||||
zone.ruinousShores.name = Ruinous Shores
|
|
||||||
zone.stainedMountains.name = Stained Mountains
|
|
||||||
zone.desolateRift.name = Desolate Rift
|
|
||||||
zone.nuclearComplex.name = Nuclear Production Complex
|
|
||||||
settings.language = Language
|
|
||||||
settings.reset = Reset to Defaults
|
|
||||||
settings.rebind = Rebind
|
|
||||||
settings.controls = Controls
|
|
||||||
settings.game = Game
|
|
||||||
settings.sound = Sound
|
|
||||||
settings.graphics = Graphics
|
|
||||||
settings.cleardata = Clear Game Data...
|
|
||||||
settings.clear.confirm = Are you sure you want to clear this data?\nWhat is done cannot be undone!
|
|
||||||
settings.clearall.confirm = [scarlet]WARNING![]\nThis will clear all data, including saves, maps, unlocks and keybinds.\nOnce you press 'ok' the game will wipe all data and automatically exit.
|
|
||||||
settings.clearunlocks = Clear Unlocks
|
|
||||||
settings.clearall = Clear All
|
|
||||||
paused = [accent]< Paused >
|
|
||||||
yes = Yes
|
|
||||||
no = No
|
|
||||||
info.title = Info
|
|
||||||
error.title = [crimson]An error has occured
|
|
||||||
error.crashtitle = An error has occured
|
|
||||||
blocks.outputspeed = Drill Speed: {0}/
|
|
||||||
blocks.efficiency = Efficiency: {0}%
|
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
|
||||||
blocks.blockinfo = Block Info
|
|
||||||
blocks.powerbalance = Power: {0}
|
|
||||||
blocks.poweroutput = Power Output: {0}
|
|
||||||
blocks.powercapacity = Power Capacity
|
|
||||||
blocks.powershot = Power/Shot
|
|
||||||
blocks.targetsair = Targets Air
|
|
||||||
blocks.targetsground = Targets Ground
|
|
||||||
blocks.items = Items: {0}
|
|
||||||
blocks.itemsmoved = Move Speed
|
|
||||||
blocks.launchtime = Time Between Launches
|
|
||||||
blocks.shootrange = Range
|
|
||||||
blocks.size = Size
|
|
||||||
blocks.liquidcapacity = Liquid Capacity
|
|
||||||
blocks.maxitemssecond = Max Items
|
|
||||||
blocks.powerrange = Power Range
|
|
||||||
blocks.poweruse = Power Use
|
|
||||||
blocks.powerdamage = Power/Damage
|
|
||||||
blocks.inputitemcapacity = Input Item Capacity
|
|
||||||
blocks.outputitemcapacity = Output Item Capacity
|
|
||||||
blocks.itemcapacity = Item Capacity
|
|
||||||
blocks.basepowergeneration = Base Power Generation
|
|
||||||
blocks.powertransferspeed = Power Transfer
|
|
||||||
blocks.craftspeed = Production Speed
|
|
||||||
blocks.repairtime = Block Full Repair Time
|
|
||||||
blocks.range = Range
|
|
||||||
blocks.inputliquid = Input Liquid
|
|
||||||
blocks.inputliquidaux = Aux Liquid
|
|
||||||
blocks.inputitem = Input Item
|
|
||||||
blocks.inputitems = Input Items
|
|
||||||
blocks.outputitem = Output Item
|
|
||||||
blocks.drilltier = Drillables
|
|
||||||
blocks.drillspeed = Base Drill Speed
|
|
||||||
blocks.maxunits = Max Active Units
|
|
||||||
blocks.liquidoutput = Liquid Output
|
|
||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
|
||||||
blocks.liquiduse = Liquid Use
|
|
||||||
blocks.coolant = Coolant
|
|
||||||
blocks.liquid = Liquid
|
|
||||||
blocks.coolantuse = Coolant Use
|
|
||||||
blocks.inputliquidfuel = Fuel Liquid
|
|
||||||
blocks.liquidfueluse = Liquid Fuel Use
|
|
||||||
blocks.boostitem = Boost Item
|
|
||||||
blocks.boostliquid = Boost Liquid
|
|
||||||
blocks.health = Health
|
|
||||||
blocks.heat = Heat
|
|
||||||
blocks.power = Power
|
|
||||||
blocks.progress = Build Progress
|
|
||||||
blocks.spawned = Units: {0}/{1}
|
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
|
||||||
blocks.inaccuracy = Inaccuracy
|
|
||||||
blocks.shots = Shots
|
|
||||||
blocks.reload = Shots/Second
|
|
||||||
blocks.inputfuel = Fuel
|
|
||||||
blocks.fuelburntime = Fuel Burn Time
|
|
||||||
blocks.inputcapacity = Input capacity
|
|
||||||
blocks.outputcapacity = Output capacity
|
|
||||||
blocks.ammo = Ammo
|
|
||||||
bullet.damage = [stat]{0}[lightgray] damage
|
|
||||||
bullet.splashdamage = [stat]{0}[lightgray] area dmg ~[stat] {1}[lightgray] tiles
|
|
||||||
bullet.incendiary = [stat]incendiary
|
|
||||||
bullet.homing = [stat]homing
|
|
||||||
bullet.shock = [stat]shock
|
|
||||||
bullet.frag = [stat]frag
|
|
||||||
bullet.knockback = [stat]{0}[lightgray] knockback
|
|
||||||
bullet.freezing = [stat]freezing
|
|
||||||
bullet.tarred = [stat]tarred
|
|
||||||
bullet.multiplier = [stat]{0}[lightgray]x ammo multiplier
|
|
||||||
bullet.reload = [stat]{0}[lightgray]x fire rate
|
|
||||||
unit.blocks = blocks
|
|
||||||
unit.powersecond = power units/second
|
|
||||||
unit.liquidsecond = liquid units/second
|
|
||||||
unit.itemssecond = items/second
|
|
||||||
unit.liquidunits = liquid units
|
|
||||||
unit.powerunits = power units
|
|
||||||
unit.degrees = degrees
|
|
||||||
unit.seconds = seconds
|
|
||||||
unit.items = items
|
|
||||||
category.general = General
|
|
||||||
category.power = Power
|
|
||||||
category.liquids = Liquids
|
|
||||||
category.items = Items
|
|
||||||
category.crafting = Crafting
|
|
||||||
category.shooting = Shooting
|
|
||||||
category.optional = Optional Enhancements
|
|
||||||
setting.landscape.name = Lock Landscape
|
|
||||||
setting.shadows.name = Shadows
|
|
||||||
setting.animatedwater.name = Animated Water
|
|
||||||
setting.antialias.name = Antialias[LIGHT_GRAY] (requires restart)[]
|
|
||||||
setting.indicators.name = Ally Indicators
|
|
||||||
setting.autotarget.name = Auto-Target
|
|
||||||
setting.fpscap.name = Max FPS
|
|
||||||
setting.fpscap.none = None
|
|
||||||
setting.fpscap.text = {0} FPS
|
|
||||||
setting.swapdiagonal.name = Always Diagonal Placement
|
|
||||||
setting.difficulty.training = training
|
|
||||||
setting.difficulty.easy = easy
|
|
||||||
setting.difficulty.normal = normal
|
|
||||||
setting.difficulty.hard = hard
|
|
||||||
setting.difficulty.insane = insane
|
|
||||||
setting.difficulty.name = Difficulty:
|
|
||||||
setting.screenshake.name = Screen Shake
|
|
||||||
setting.effects.name = Display Effects
|
|
||||||
setting.sensitivity.name = Controller Sensitivity
|
|
||||||
setting.saveinterval.name = Autosave Interval
|
|
||||||
setting.seconds = {0} Seconds
|
|
||||||
setting.fullscreen.name = Fullscreen
|
|
||||||
setting.borderless.name = Borderless Window
|
|
||||||
setting.fps.name = Show FPS
|
|
||||||
setting.vsync.name = VSync
|
|
||||||
setting.lasers.name = Show Power Lasers
|
|
||||||
setting.minimap.name = Show Minimap
|
|
||||||
setting.musicvol.name = Music Volume
|
|
||||||
setting.mutemusic.name = Mute Music
|
|
||||||
setting.sfxvol.name = SFX Volume
|
|
||||||
setting.mutesound.name = Mute Sound
|
|
||||||
setting.crashreport.name = Send Anonymous Crash Reports
|
|
||||||
keybind.title = Rebind Keys
|
|
||||||
category.general.name = General
|
|
||||||
category.view.name = View
|
|
||||||
category.multiplayer.name = Multiplayer
|
|
||||||
command.attack = Attack
|
|
||||||
command.retreat = Retreat
|
|
||||||
command.patrol = Patrol
|
|
||||||
keybind.gridMode.name = Block Select
|
|
||||||
keybind.gridModeShift.name = Category Select
|
|
||||||
keybind.press = Press a key...
|
|
||||||
keybind.press.axis = Press an axis or key...
|
|
||||||
keybind.screenshot.name = Map Screenshot
|
|
||||||
keybind.move_x.name = Move x
|
|
||||||
keybind.move_y.name = Move y
|
|
||||||
keybind.select.name = Select/Shoot
|
|
||||||
keybind.diagonal_placement.name = Diagonal Placement
|
|
||||||
keybind.pick.name = Pick Block
|
|
||||||
keybind.break_block.name = Break Block
|
|
||||||
keybind.deselect.name = Deselect
|
|
||||||
keybind.shoot.name = Shoot
|
|
||||||
keybind.zoom_hold.name = Zoom Hold
|
|
||||||
keybind.zoom.name = Zoom
|
|
||||||
keybind.menu.name = Menu
|
|
||||||
keybind.pause.name = Pause
|
|
||||||
keybind.dash.name = Dash
|
|
||||||
keybind.chat.name = Chat
|
|
||||||
keybind.player_list.name = Player list
|
|
||||||
keybind.console.name = Console
|
|
||||||
keybind.rotate.name = Rotate
|
|
||||||
keybind.toggle_menus.name = Toggle menus
|
|
||||||
keybind.chat_history_prev.name = Chat history prev
|
|
||||||
keybind.chat_history_next.name = Chat history next
|
|
||||||
keybind.chat_scroll.name = Chat scroll
|
|
||||||
keybind.drop_unit.name = drop unit
|
|
||||||
keybind.zoom_minimap.name = Zoom minimap
|
|
||||||
mode.help.title = Description of modes
|
|
||||||
mode.survival.name = Survival
|
|
||||||
mode.survival.description = The normal mode. Limited resources and automatic incoming waves.
|
|
||||||
mode.sandbox.name = sandbox
|
|
||||||
mode.sandbox.description = infinite resources and no timer for waves.
|
|
||||||
mode.freebuild.name = freebuild
|
|
||||||
mode.freebuild.description = limited resources and no timer for waves.
|
|
||||||
mode.pvp.name = PvP
|
|
||||||
mode.pvp.description = fight against other players locally.
|
|
||||||
mode.attack.name = Attack
|
|
||||||
mode.attack.description = No waves, with the goal to destroy the enemy base.
|
|
||||||
mode.custom = Custom Rules
|
|
||||||
rules.infiniteresources = Infinite Resources
|
|
||||||
rules.wavetimer = Wave Timer
|
|
||||||
rules.waves = Waves
|
|
||||||
rules.enemyCheat = Infinite AI (Red Team) Resources
|
|
||||||
rules.pvp = PvP
|
|
||||||
rules.unitdrops = Unit Drops
|
|
||||||
rules.enemycorebuildradius = Enemy Core No-Build Radius:[LIGHT_GRAY] (tiles)
|
|
||||||
rules.respawntime = Respawn Time:[LIGHT_GRAY] (sec)
|
|
||||||
rules.wavespacing = Wave Spacing:[LIGHT_GRAY] (sec)
|
|
||||||
rules.buildcostmultiplier = Build Cost Multiplier
|
|
||||||
rules.buildspeedmultiplier = Build Speed Multiplier
|
|
||||||
content.item.name = Items
|
|
||||||
content.liquid.name = Liquids
|
|
||||||
content.unit.name = Units
|
|
||||||
content.block.name = Blocks
|
|
||||||
content.mech.name = Mechs
|
|
||||||
item.copper.name = Copper
|
|
||||||
item.copper.description = A useful structure material. Used extensively in all types of blocks.
|
|
||||||
item.lead.name = Lead
|
|
||||||
item.lead.description = A basic starter material. Used extensively in electronics and liquid transportation blocks.
|
|
||||||
item.coal.name = Coal
|
|
||||||
item.coal.description = A common and readily available fuel.
|
|
||||||
item.graphite.name = Graphite
|
|
||||||
item.titanium.name = Titanium
|
|
||||||
item.titanium.description = A rare super-light metal used extensively in liquid transportation, drills and aircraft.
|
|
||||||
item.thorium.name = Thorium
|
|
||||||
item.thorium.description = A dense, radioactive metal used as structural support and nuclear fuel.
|
|
||||||
item.silicon.name = Silicon
|
|
||||||
item.silicon.description = An extremely useful semiconductor, with applications in solar panels and many complex electronics.
|
|
||||||
item.plastanium.name = Plastanium
|
|
||||||
item.plastanium.description = A light, ductile material used in advanced aircraft and fragmentation ammunition.
|
|
||||||
item.phase-fabric.name = Phase Fabric
|
|
||||||
item.phase-fabric.description = A near-weightless substance used in advanced electronics and self-repairing technology.
|
|
||||||
item.surge-alloy.name = Surge Alloy
|
|
||||||
item.surge-alloy.description = An advanced alloy with unique electrical properties.
|
|
||||||
item.spore-pod.name = Spore Pod
|
|
||||||
item.spore-pod.description = Used for conversion into oil, explosives and fuel.
|
|
||||||
item.sand.name = Sand
|
|
||||||
item.sand.description = A common material that is used extensively in smelting, both in alloying and as a flux.
|
|
||||||
item.blast-compound.name = Blast Compound
|
|
||||||
item.blast-compound.description = A volatile compound used in bombs and explosives. While it can burned as fuel, this is not advised.
|
|
||||||
item.pyratite.name = Pyratite
|
|
||||||
item.pyratite.description = An extremely flammable substance used in incendiary weapons.
|
|
||||||
item.metaglass.name = Metaglass
|
|
||||||
item.metaglass.description = A super-tough glass compound. Extensively used for liquid distribution and storage.
|
|
||||||
item.scrap.name = Scrap
|
|
||||||
item.scrap.description = Leftover remnants of old structures and units. Contains trace amounts of many different metals.
|
|
||||||
liquid.water.name = Water
|
|
||||||
liquid.slag.name = Slag
|
|
||||||
liquid.oil.name = Oil
|
|
||||||
liquid.cryofluid.name = Cryofluid
|
|
||||||
mech.alpha-mech.name = Alpha
|
|
||||||
mech.alpha-mech.weapon = Heavy Repeater
|
|
||||||
mech.alpha-mech.ability = Drone Swarm
|
|
||||||
mech.alpha-mech.description = The standard mech. Has decent speed and damage output; can create up to 3 drones for increased offensive capability.
|
|
||||||
mech.delta-mech.name = Delta
|
|
||||||
mech.delta-mech.weapon = Arc Generator
|
|
||||||
mech.delta-mech.ability = Discharge
|
|
||||||
mech.delta-mech.description = A fast, lightly-armored mech made for hit-and-run attacks. Does little damage against structures, but can kill large groups of enemy units very quickly with its arc lightning weapons.
|
|
||||||
mech.tau-mech.name = Tau
|
|
||||||
mech.tau-mech.weapon = Restruct Laser
|
|
||||||
mech.tau-mech.ability = Repair Burst
|
|
||||||
mech.tau-mech.description = The support mech. Heals allied blocks by shooting at them. Can heal allies in a radius with its repair ability.
|
|
||||||
mech.omega-mech.name = Omega
|
|
||||||
mech.omega-mech.weapon = Swarm Missiles
|
|
||||||
mech.omega-mech.ability = Armored Configuration
|
|
||||||
mech.omega-mech.description = A bulky and well-armored mech, made for front-line assaults. Its armor ability can block up to 90% of incoming damage.
|
|
||||||
mech.dart-ship.name = Dart
|
|
||||||
mech.dart-ship.weapon = Repeater
|
|
||||||
mech.dart-ship.description = The standard ship. Reasonably fast and light, but has little offensive capability and low mining speed.
|
|
||||||
mech.javelin-ship.name = Javelin
|
|
||||||
mech.javelin-ship.description = A hit-and-run strike ship. While initially slow, it can accelerate to great speeds and fly by enemy outposts, dealing large amounts of damage with its lightning ability and missiles.
|
|
||||||
mech.javelin-ship.weapon = Burst Missiles
|
|
||||||
mech.javelin-ship.ability = Discharge Booster
|
|
||||||
mech.trident-ship.name = Trident
|
|
||||||
mech.trident-ship.description = A heavy bomber. Reasonably well armored.
|
|
||||||
mech.trident-ship.weapon = Bomb Bay
|
|
||||||
mech.glaive-ship.name = Glaive
|
|
||||||
mech.glaive-ship.description = A large, well-armored gunship. Equipped with an incendiary repeater. Good acceleration and maximum speed.
|
|
||||||
mech.glaive-ship.weapon = Flame Repeater
|
|
||||||
item.explosiveness = [LIGHT_GRAY]Explosiveness: {0}%
|
|
||||||
item.flammability = [LIGHT_GRAY]Flammability: {0}%
|
|
||||||
item.radioactivity = [LIGHT_GRAY]Radioactivity: {0}%
|
|
||||||
unit.health = [LIGHT_GRAY]Health: {0}
|
|
||||||
unit.speed = [LIGHT_GRAY]Speed: {0}
|
|
||||||
mech.weapon = [LIGHT_GRAY]Weapon: {0}
|
|
||||||
mech.health = [LIGHT_GRAY]Health: {0}
|
|
||||||
mech.itemcapacity = [LIGHT_GRAY]Item Capacity: {0}
|
|
||||||
mech.minespeed = [LIGHT_GRAY]Mining Speed: {0}
|
|
||||||
mech.minepower = [LIGHT_GRAY]Mining Power: {0}
|
|
||||||
mech.ability = [LIGHT_GRAY]Ability: {0}
|
|
||||||
liquid.heatcapacity = [LIGHT_GRAY]Heat Capacity: {0}
|
|
||||||
liquid.viscosity = [LIGHT_GRAY]Viscosity: {0}
|
|
||||||
liquid.temperature = [LIGHT_GRAY]Temperature: {0}
|
|
||||||
block.grass.name = Grass
|
|
||||||
block.salt.name = Salt
|
|
||||||
block.sandrocks.name = Sand Rocks
|
|
||||||
block.spore-pine.name = Spore Pine
|
|
||||||
block.sporerocks.name = Spore Rocks
|
|
||||||
block.rock.name = Rock
|
|
||||||
block.snowrock.name = Snow Rock
|
|
||||||
block.shale.name = Shale
|
|
||||||
block.shale-boulder.name = Shale Boulder
|
|
||||||
block.moss.name = Moss
|
|
||||||
block.spore-moss.name = Spore Moss
|
|
||||||
block.shalerocks.name = Shale Rocks
|
|
||||||
block.scrap-wall.name = Scrap Wall
|
|
||||||
block.scrap-wall-large.name = Large Scrap Wall
|
|
||||||
block.scrap-wall-huge.name = Huge Scrap Wall
|
|
||||||
block.scrap-wall-gigantic.name = Gigantic Scrap Wall
|
|
||||||
block.thruster.name = Thruster
|
|
||||||
block.kiln.name = Kiln
|
|
||||||
block.kiln.description = Smelts sand and lead into metaglass. Requires small amounts of power.
|
|
||||||
block.graphite-press.name = Graphite Press
|
|
||||||
block.multi-press.name = Multi-Press
|
|
||||||
block.constructing = {0} [LIGHT_GRAY](Constructing)
|
|
||||||
block.spawn.name = Enemy Spawn
|
|
||||||
block.core-shard.name = Core: Shard
|
|
||||||
block.core-foundation.name = Core: Foundation
|
|
||||||
block.core-nucleus.name = Core: Nucleus
|
|
||||||
block.deepwater.name = deepwater
|
|
||||||
block.water.name = water
|
|
||||||
block.tainted-water.name = Tainted Water
|
|
||||||
block.darksand-tainted-water.name = Dark Sand Tainted Water
|
|
||||||
block.tar.name = Tar
|
|
||||||
block.stone.name = Stone
|
|
||||||
block.sand.name = Sand
|
|
||||||
block.darksand.name = Dark Sand
|
|
||||||
block.ice.name = Ice
|
|
||||||
block.snow.name = Snow
|
|
||||||
block.craters.name = Craters
|
|
||||||
block.sand-water.name = Sand water
|
|
||||||
block.darksand-water.name = Dark Sand Water
|
|
||||||
block.char.name = Char
|
|
||||||
block.holostone.name = Holo stone
|
|
||||||
block.ice-snow.name = Ice Snow
|
|
||||||
block.rocks.name = Rocks
|
|
||||||
block.icerocks.name = Ice rocks
|
|
||||||
block.snowrocks.name = Snow Rocks
|
|
||||||
block.dunerocks.name = Dune Rocks
|
|
||||||
block.pine.name = Pine
|
|
||||||
block.white-tree-dead.name = White Tree Dead
|
|
||||||
block.white-tree.name = White Tree
|
|
||||||
block.spore-cluster.name = Spore Cluster
|
|
||||||
block.metal-floor.name = Metal Floor 1
|
|
||||||
block.metal-floor-2.name = Metal Floor 2
|
|
||||||
block.metal-floor-3.name = Metal Floor 3
|
|
||||||
block.metal-floor-5.name = Metal Floor 4
|
|
||||||
block.metal-floor-damaged.name = Metal Floor Damaged
|
|
||||||
block.ignarock.name = Igna Rock
|
|
||||||
block.hotrock.name = Hot Rock
|
|
||||||
block.magmarock.name = Magma Rock
|
|
||||||
block.cliffs.name = Cliffs
|
|
||||||
block.copper-wall.name = Copper Wall
|
|
||||||
block.copper-wall-large.name = Large Copper Wall
|
|
||||||
block.titanium-wall.name = Titanium Wall
|
|
||||||
block.titanium-wall-large.name = Large Titanium Wall
|
|
||||||
block.phase-wall.name = Phase Wall
|
|
||||||
block.phase-wall-large.name = Large Phase Wall
|
|
||||||
block.thorium-wall.name = Thorium Wall
|
|
||||||
block.thorium-wall-large.name = Large Thorium Wall
|
|
||||||
block.door.name = Door
|
|
||||||
block.door-large.name = Large Door
|
|
||||||
block.duo.name = Duo
|
|
||||||
block.scorch.name = Scorch
|
|
||||||
block.scatter.name = Scatter
|
|
||||||
block.hail.name = Hail
|
|
||||||
block.lancer.name = Lancer
|
|
||||||
block.conveyor.name = Conveyor
|
|
||||||
block.titanium-conveyor.name = Titanium Conveyor
|
|
||||||
block.junction.name = Junction
|
|
||||||
block.router.name = Router
|
|
||||||
block.distributor.name = Distributor
|
|
||||||
block.sorter.name = Sorter
|
|
||||||
block.sorter.description = Sorts items. If an item matches the selection, it is allowed to pass. Otherwise, the item is outputted to the left and right.
|
|
||||||
block.overflow-gate.name = Overflow Gate
|
|
||||||
block.overflow-gate.description = A combination splitter and router that only outputs to the left and right if the front path is blocked.
|
|
||||||
block.silicon-smelter.name = Silicon Smelter
|
|
||||||
block.phase-weaver.name = Phase Weaver
|
|
||||||
block.pulverizer.name = Pulverizer
|
|
||||||
block.cryofluidmixer.name = Cryofluid Mixer
|
|
||||||
block.melter.name = Melter
|
|
||||||
block.incinerator.name = Incinerator
|
|
||||||
block.spore-press.name = Spore Press
|
|
||||||
block.separator.name = Separator
|
|
||||||
block.power-node.name = Power Node
|
|
||||||
block.power-node-large.name = Large Power Node
|
|
||||||
block.surge-tower.name = Surge Tower
|
|
||||||
block.battery.name = Battery
|
|
||||||
block.battery-large.name = Large Battery
|
|
||||||
block.combustion-generator.name = Combustion Generator
|
|
||||||
block.turbine-generator.name = Turbine Generator
|
|
||||||
block.differential-generator.name = Differential Generator
|
|
||||||
block.impact-reactor.name = Impact Reactor
|
|
||||||
block.mechanical-drill.name = Mechanical Drill
|
|
||||||
block.pneumatic-drill.name = Pneumatic Drill
|
|
||||||
block.laser-drill.name = Laser Drill
|
|
||||||
block.water-extractor.name = Water Extractor
|
|
||||||
block.cultivator.name = Cultivator
|
|
||||||
block.alpha-dart-mech-pad.name = Alpha-Dart Mech Pad
|
|
||||||
block.delta-mech-pad.name = Delta Mech Pad
|
|
||||||
block.javelin-ship-pad.name = Javelin Ship Pad
|
|
||||||
block.trident-ship-pad.name = Trident Ship Pad
|
|
||||||
block.glaive-ship-pad.name = Glaive Ship Pad
|
|
||||||
block.omega-mech-pad.name = Omega Mech Pad
|
|
||||||
block.tau-mech-pad.name = Tau Mech Pad
|
|
||||||
block.conduit.name = Conduit
|
|
||||||
block.mechanical-pump.name = Mechanical Pump
|
|
||||||
block.item-source.name = Item Source
|
|
||||||
block.item-void.name = Item Void
|
|
||||||
block.liquid-source.name = Liquid Source
|
|
||||||
block.power-void.name = Power Void
|
|
||||||
block.power-source.name = Power Infinite
|
|
||||||
block.unloader.name = Unloader
|
|
||||||
block.vault.name = Vault
|
|
||||||
block.wave.name = Wave
|
|
||||||
block.swarmer.name = Swarmer
|
|
||||||
block.salvo.name = Salvo
|
|
||||||
block.ripple.name = Ripple
|
|
||||||
block.phase-conveyor.name = Phase Conveyor
|
|
||||||
block.bridge-conveyor.name = Bridge Conveyor
|
|
||||||
block.plastanium-compressor.name = Plastanium Compressor
|
|
||||||
block.pyratite-mixer.name = Pyratite Mixer
|
|
||||||
block.blast-mixer.name = Blast Mixer
|
|
||||||
block.solar-panel.name = Solar Panel
|
|
||||||
block.solar-panel-large.name = Large Solar Panel
|
|
||||||
block.oil-extractor.name = Oil Extractor
|
|
||||||
block.spirit-factory.name = Spirit Drone Factory
|
|
||||||
block.phantom-factory.name = Phantom Drone Factory
|
|
||||||
block.wraith-factory.name = Wraith Fighter Factory
|
|
||||||
block.ghoul-factory.name = Ghoul Bomber Factory
|
|
||||||
block.dagger-factory.name = Dagger Mech Factory
|
|
||||||
block.crawler-factory.name = Crawler Mech Factory
|
|
||||||
block.titan-factory.name = Titan Mech Factory
|
|
||||||
block.fortress-factory.name = Fortress Mech Factory
|
|
||||||
block.revenant-factory.name = Revenant Fighter Factory
|
|
||||||
block.repair-point.name = Repair Point
|
|
||||||
block.pulse-conduit.name = Pulse Conduit
|
|
||||||
block.phase-conduit.name = Phase Conduit
|
|
||||||
block.liquid-router.name = Liquid Router
|
|
||||||
block.liquid-tank.name = Liquid Tank
|
|
||||||
block.liquid-junction.name = Liquid Junction
|
|
||||||
block.bridge-conduit.name = Bridge Conduit
|
|
||||||
block.rotary-pump.name = Rotary Pump
|
|
||||||
block.thorium-reactor.name = Thorium Reactor
|
|
||||||
block.mass-driver.name = Mass Driver
|
|
||||||
block.blast-drill.name = Airblast Drill
|
|
||||||
block.thermal-pump.name = Thermal Pump
|
|
||||||
block.thermal-generator.name = Thermal Generator
|
|
||||||
block.alloy-smelter.name = Alloy Smelter
|
|
||||||
block.mender.name = Mender
|
|
||||||
block.mend-projector.name = Mend Projector
|
|
||||||
block.surge-wall.name = Surge Wall
|
|
||||||
block.surge-wall-large.name = Large Surge Wall
|
|
||||||
block.cyclone.name = Cyclone
|
|
||||||
block.fuse.name = Fuse
|
|
||||||
block.shock-mine.name = Shock Mine
|
|
||||||
block.overdrive-projector.name = Overdrive Projector
|
|
||||||
block.force-projector.name = Force Projector
|
|
||||||
block.arc.name = Arc
|
|
||||||
block.rtg-generator.name = RTG Generator
|
|
||||||
block.spectre.name = Spectre
|
|
||||||
block.meltdown.name = Meltdown
|
|
||||||
block.container.name = Container
|
|
||||||
block.launch-pad.name = Launch Pad
|
|
||||||
block.launch-pad.description = Launches batches of items without any need for a core launch. Unfinished.
|
|
||||||
block.launch-pad-large.name = Large Launch Pad
|
|
||||||
team.blue.name = blue
|
|
||||||
team.red.name = red
|
|
||||||
team.orange.name = orange
|
|
||||||
team.none.name = gray
|
|
||||||
team.green.name = green
|
|
||||||
team.purple.name = purple
|
|
||||||
unit.spirit.name = Spirit Drone
|
|
||||||
unit.spirit.description = The starter drone unit. Spawns in the core by default. Automatically mines ores and repairs blocks.
|
|
||||||
unit.phantom.name = Phantom Drone
|
|
||||||
unit.phantom.description = An advanced drone unit. Automatically mines ores and repairs blocks. Significantly more effective than a spirit drone.
|
|
||||||
unit.dagger.name = Dagger
|
|
||||||
unit.dagger.description = A basic ground unit. Useful in swarms.
|
|
||||||
unit.crawler.name = Crawler
|
|
||||||
unit.titan.name = Titan
|
|
||||||
unit.titan.description = An advanced, armored ground unit. Attacks both ground and air targets.
|
|
||||||
unit.ghoul.name = Ghoul Bomber
|
|
||||||
unit.ghoul.description = A heavy carpet bomber.
|
|
||||||
unit.wraith.name = Wraith Fighter
|
|
||||||
unit.wraith.description = A fast, hit-and-run interceptor unit.
|
|
||||||
unit.fortress.name = Fortress
|
|
||||||
unit.fortress.description = A heavy artillery ground unit.
|
|
||||||
unit.revenant.name = Revenant
|
|
||||||
unit.eruptor.name = Eruptor
|
|
||||||
unit.chaos-array.name = Chaos Array
|
|
||||||
unit.eradicator.name = Eradicator
|
|
||||||
unit.lich.name = Lich
|
|
||||||
unit.reaper.name = Reaper
|
|
||||||
tutorial.begin = Your mission here is to eradicate the[LIGHT_GRAY] enemy[].\n\nBegin by[accent] mining copper[]. Tap a copper ore vein near your core to do this.
|
|
||||||
tutorial.drill = Mining manually is inefficient.\n[accent]Drills []can mine automatically.\nPlace one on a copper vein.
|
|
||||||
tutorial.conveyor = [accent]Conveyors[] are used to transport items to the core.\nMake a line of conveyors from the drill to the core.
|
|
||||||
tutorial.morecopper = More copper is required.\n\nEither mine it manually, or place more drills.
|
|
||||||
tutorial.turret = Defensive structures must be built to repel the[LIGHT_GRAY] enemy[].\nBuild a duo turret near your base.
|
|
||||||
tutorial.drillturret = Duo turrets require[accent] copper ammo []to shoot.\nPlace a drill next to the turret to supply it with mined copper.
|
|
||||||
tutorial.waves = The[LIGHT_GRAY] enemy[] approaches.\n\nDefend your core for 2 waves. Build more turrets.
|
|
||||||
tutorial.lead = More ores are available. Explore and mine[accent] lead[].\n\nDrag from your unit to the core to transfer resources.
|
|
||||||
tutorial.smelter = Copper and lead are weak metals.\nSuperior[accent] Dense Alloy[] can be created in a smelter.\n\nBuild one.
|
|
||||||
tutorial.densealloy = The smelter will now produce alloy.\nGet some.\nImprove the production if necessary.
|
|
||||||
tutorial.siliconsmelter = The core will now create a[accent] spirit drone[] for mining and repairing blocks.\n\nFactories for other units can be created with [accent] silicon.\nMake a silicon smelter.
|
|
||||||
tutorial.silicondrill = Silicon requires[accent] coal[] and[accent] sand[].\nStart by making drills.
|
|
||||||
tutorial.generator = This technology requires power.\nCreate a[accent] combustion generator[] for it.
|
|
||||||
tutorial.generatordrill = Combustion generators need fuel.\nFuel it with coal from a drill.
|
|
||||||
tutorial.node = Power requires transport.\nCreate a[accent] power node[] next to your combustion generator to transfer its power.
|
|
||||||
tutorial.nodelink = Power can be transferred through contacting power blocks and generators, or by linked power nodes.\n\nLink power by tapping the node and selecting the generator and silicon smelter.
|
|
||||||
tutorial.silicon = Silicon is being produced. Get some.\n\nImproving the production system is advised.
|
|
||||||
tutorial.daggerfactory = Construct a[accent] dagger mech factory.[]\n\nThis will be used to create attack mechs.
|
|
||||||
tutorial.router = Factories need resources to function.\nCreate a router to split conveyor resources.
|
|
||||||
tutorial.dagger = Link power nodes to the factory.\nOnce requirements are met, a mech will be created.\n\nCreate more drills, generators and conveyors as necessary.
|
|
||||||
tutorial.battle = The[LIGHT_GRAY] enemy[] has revealed their core.\nDestroy it with your unit and dagger mechs.
|
|
||||||
block.copper-wall.description = A cheap defensive block.\nUseful for protecting the core and turrets in the first few waves.
|
|
||||||
block.copper-wall-large.description = A cheap defensive block.\nUseful for protecting the core and turrets in the first few waves.\nSpans multiple tiles.
|
|
||||||
block.thorium-wall.description = A strong defensive block.\nGood protection from enemies.
|
|
||||||
block.thorium-wall-large.description = A strong defensive block.\nGood protection from enemies.\nSpans multiple tiles.
|
|
||||||
block.phase-wall.description = Not as strong as a thorium wall but will deflect bullets unless they are too powerful.
|
|
||||||
block.phase-wall-large.description = Not as strong as a thorium wall but will deflect bullets unless they are too powerful.\nSpans multiple tiles.
|
|
||||||
block.surge-wall.description = The strongest defensive block.\nHas a small chance of triggering lightning towards the attacker.
|
|
||||||
block.surge-wall-large.description = The strongest defensive block.\nHas a small chance of triggering lightning towards the attacker.\nSpans multiple tiles.
|
|
||||||
block.door.description = A small door that can be opened and closed by tapping on it.\nIf opened, enemies can shoot and move through.
|
|
||||||
block.door-large.description = A large door that can be opened and closed by tapping on it.\nIf opened, enemies can shoot and move through.\nSpans multiple tiles.
|
|
||||||
block.mend-projector.description = Periodically heals blocks in its vicinity.
|
|
||||||
block.overdrive-projector.description = Increases the speed of nearby buildings like drills and conveyors.
|
|
||||||
block.force-projector.description = Creates a hexagonal force field around itself, protecting buildings and units inside from damage through bullets.
|
|
||||||
block.shock-mine.description = Damages enemies stepping on the mine. Nearly invisible to the enemy.
|
|
||||||
block.duo.description = A small, cheap turret.
|
|
||||||
block.scatter.description = A medium-sized anti-air turret. Sprays clumps of lead or scrap flak at enemy units.
|
|
||||||
block.arc.description = A small turret which shoots electricity in a random arc towards the enemy.
|
|
||||||
block.hail.description = A small artillery turret.
|
|
||||||
block.lancer.description = A medium-sized turret which shoots charged electricity beams.
|
|
||||||
block.wave.description = A medium-sized rapid-fire turret which shoots liquid bubbles.
|
|
||||||
block.salvo.description = A medium-sized turret which fires shots in salvos.
|
|
||||||
block.swarmer.description = A medium-sized turret which shoots burst missiles.
|
|
||||||
block.ripple.description = A large artillery turret which fires several shots simultaneously.
|
|
||||||
block.cyclone.description = A large rapid fire turret.
|
|
||||||
block.fuse.description = A large turret which shoots powerful short-range beams.
|
|
||||||
block.spectre.description = A large turret which shoots two powerful bullets at once.
|
|
||||||
block.meltdown.description = A large turret which shoots powerful long-range beams.
|
|
||||||
block.conveyor.description = Basic item transport block. Moved items forward and automatically deposits them into turrets or crafters. Rotatable.
|
|
||||||
block.titanium-conveyor.description = Advanced item transport block. Moves items faster than standard conveyors.
|
|
||||||
block.phase-conveyor.description = Advanced item transport block. Uses power to teleport items to a connected phase conveyor over several tiles.
|
|
||||||
block.junction.description = Acts as a bridge for two crossing conveyor belts. Useful in situations with two different conveyors carrying different materials to different locations.
|
|
||||||
block.mass-driver.description = Ultimate item transport block. Collects several items and then shoots them to another mass driver over a long range.
|
|
||||||
block.silicon-smelter.description = Reduces sand with highly pure coke in order to produce silicon.
|
|
||||||
block.plastanium-compressor.description = Produces plastanium from oil and titanium.
|
|
||||||
block.phase-weaver.description = Produces phase fabric from radioactive thorium and high amounts of sand.
|
|
||||||
block.alloy-smelter.description = Produces surge alloy from titanium, lead, silicon and copper.
|
|
||||||
block.pulverizer.description = Crushes stone into sand. Useful when there is a lack of natural sand.
|
|
||||||
block.pyratite-mixer.description = Mixes coal, lead and sand into highly flammable pyratite.
|
|
||||||
block.blast-mixer.description = Uses oil for transforming pyratite into the less flammable but more explosive blast compound.
|
|
||||||
block.cryofluidmixer.description = Combines water and titanium into cryofluid which is much more efficient for cooling.
|
|
||||||
block.melter.description = Heats up stone to very high temperatures to obtain lava.
|
|
||||||
block.incinerator.description = Gets rid of any excess item or liquid.
|
|
||||||
block.spore-press.description = Compresses spore pods into oil.
|
|
||||||
block.separator.description = Exposes stone to water pressure in order to obtain various minerals contained in the stone.
|
|
||||||
block.power-node.description = Transmits power to connected nodes. Up to four power sources, sinks or nodes can be connected. The node will receive power from or supply power to any adjacent blocks.
|
|
||||||
block.power-node-large.description = Has a larger radius than the power node and connects to up to six power sources, sinks or nodes.
|
|
||||||
block.battery.description = Stores power whenever there is an abundance and provides power whenever there is a shortage, as long as there is capacity left.
|
|
||||||
block.battery-large.description = Stores much more power than a regular battery.
|
|
||||||
block.combustion-generator.description = Generates power by burning oil or flammable materials.
|
|
||||||
block.turbine-generator.description = More efficient than a combustion generator, but requires additional water.
|
|
||||||
block.thermal-generator.description = Generates a large amount of power from lava.
|
|
||||||
block.solar-panel.description = Provides a small amount of power from the sun.
|
|
||||||
block.solar-panel-large.description = Provides much better power supply than a standard solar panel, but is also much more expensive to build.
|
|
||||||
block.thorium-reactor.description = Generates huge amounts of power from highly radioactive thorium. Requires constant cooling. Will explode violently if insufficient amounts of coolant are supplied. Power output depends on fullness, with base power generated at half capacity.
|
|
||||||
block.rtg-generator.description = A radioisotope thermoelectric generator which does not require cooling but provides less power than a thorium reactor.
|
|
||||||
block.unloader.description = Unloads items from a container, vault or core onto a conveyor or directly into an adjacent block. The type of item to be unloaded can be changed by tapping on the unloader.
|
|
||||||
block.container.description = Stores a small amount of items of each type. Adjacent containers, vaults and cores will be treated as a single storage unit. An[LIGHT_GRAY] unloader[] can be used to retrieve items from the container.
|
|
||||||
block.vault.description = Stores a large amount of items of each type. Adjacent containers, vaults and cores will be treated as a single storage unit. An[LIGHT_GRAY] unloader[] can be used to retrieve items from the vault.
|
|
||||||
block.mechanical-drill.description = A cheap drill. When placed on appropriate tiles, outputs items at a slow pace indefinitely.
|
|
||||||
block.pneumatic-drill.description = An improved drill which is faster and able to process harder materials by making use of air pressure.
|
|
||||||
block.laser-drill.description = Allows drilling even faster through laser technology, but requires power. Additionally, radioactive thorium can be retrieved with this drill.
|
|
||||||
block.blast-drill.description = The ultimate drill. Requires large amounts of power.
|
|
||||||
block.water-extractor.description = Extracts water from the ground. Use it when there is no lake nearby.
|
|
||||||
block.cultivator.description = Cultivates the soil with water in order to obtain biomatter.
|
|
||||||
block.oil-extractor.description = Uses large amounts of power in order to extract oil from sand. Use it when there is no direct source of oil nearby.
|
|
||||||
block.trident-ship-pad.description = Leave your current vessel and change into a reasonably well armored heavy bomber.\nUse the pad by double tapping while standing on it.
|
|
||||||
block.javelin-ship-pad.description = Leave your current vessel and change into a strong and fast interceptor with lightning weapons.\nUse the pad by double tapping while standing on it.
|
|
||||||
block.glaive-ship-pad.description = Leave your current vessel and change into a large, well-armored gunship.\nUse the pad by double tapping while standing on it.
|
|
||||||
block.tau-mech-pad.description = Leave your current vessel and change into a support mech which can heal friendly buildings and units.\nUse the pad by double tapping while standing on it.
|
|
||||||
block.delta-mech-pad.description = Leave your current vessel and change into a fast, lightly-armored mech made for hit-and-run attacks.\nUse the pad by double tapping while standing on it.
|
|
||||||
block.omega-mech-pad.description = Leave your current vessel and change into a bulky and well-armored mech, made for front-line assaults.\nUse the pad by double tapping while standing on it.
|
|
||||||
block.spirit-factory.description = Produces light drones which mine ore and repair blocks.
|
|
||||||
block.phantom-factory.description = Produces advanced drone units which are significantly more effective than a spirit drone.
|
|
||||||
block.wraith-factory.description = Produces fast, hit-and-run interceptor units.
|
|
||||||
block.ghoul-factory.description = Produces heavy carpet bombers.
|
|
||||||
block.dagger-factory.description = Produces basic ground units.
|
|
||||||
block.titan-factory.description = Produces advanced, armored ground units.
|
|
||||||
block.fortress-factory.description = Produces heavy artillery ground units.
|
|
||||||
block.revenant-factory.description = Produces heavy laser air units.
|
|
||||||
block.repair-point.description = Continuously heals the closest damaged unit in its vicinity.
|
|
||||||
block.conduit.description = Basic liquid transport block. Works like a conveyor, but with liquids. Best used with extractors, pumps or other conduits.
|
|
||||||
block.pulse-conduit.description = Advanced liquid transport block. Transports liquids faster and stores more than standard conduits.
|
|
||||||
block.phase-conduit.description = Advanced liquid transport block. Uses power to teleport liquids to a connected phase conduit over several tiles.
|
|
||||||
block.liquid-router.description = Accepts liquids from one direction and outputs them to up to 3 other directions equally. Can also store a certain amount of liquid. Useful for splitting the liquids from one source to multiple targets.
|
|
||||||
block.liquid-tank.description = Stores a large amount of liquids. Use it for creating buffers when there is a non-constant demand of materials or as a safeguard for cooling vital blocks.
|
|
||||||
block.liquid-junction.description = Acts as a bridge for two crossing conduits. Useful in situations with two different conduits carrying different liquids to different locations.
|
|
||||||
block.bridge-conduit.description = Advanced liquid transport block. Allows transporting liquids over up to 3 tiles of any terrain or building.
|
|
||||||
block.mechanical-pump.description = A cheap pump with slow output, but no power consumption.
|
|
||||||
block.rotary-pump.description = An advanced pump which doubles up speed by using power.
|
|
||||||
block.thermal-pump.description = The ultimate pump. Three times as fast as a mechanical pump and the only pump which is able to retrieve lava.
|
|
||||||
block.router.description = Accepts items from one direction and outputs them to up to 3 other directions equally. Useful for splitting the materials from one source to multiple targets.
|
|
||||||
block.distributor.description = An advanced router which splits items to up to 7 other directions equally.
|
|
||||||
block.bridge-conveyor.description = Advanced item transport block. Allows transporting items over up to 3 tiles of any terrain or building.
|
|
||||||
block.item-source.description = Infinitely outputs items. Sandbox only.
|
|
||||||
block.liquid-source.description = Infinitely outputs liquids. Sandbox only.
|
|
||||||
block.item-void.description = Destroys any items which go into it without using power. Sandbox only.
|
|
||||||
block.power-source.description = Infinitely outputs power. Sandbox only.
|
|
||||||
block.power-void.description = Voids all power inputted into it. Sandbox only.
|
|
||||||
liquid.water.description = Commonly used for cooling machines and waste processing.
|
|
||||||
liquid.oil.description = Can be burnt, exploded or used as a coolant.
|
|
||||||
liquid.cryofluid.description = The most efficient liquid for cooling things down.
|
|
||||||
@@ -335,17 +335,17 @@ no = No
|
|||||||
info.title = [accent]Información
|
info.title = [accent]Información
|
||||||
error.title = [crimson]Un error ha ocurrido.
|
error.title = [crimson]Un error ha ocurrido.
|
||||||
error.crashtitle = Un error ha ocurrido.
|
error.crashtitle = Un error ha ocurrido.
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Información del Bloque
|
blocks.blockinfo = Información del Bloque
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Capacidad de Energía
|
blocks.powercapacity = Capacidad de Energía
|
||||||
blocks.powershot = Energía/Disparo
|
blocks.powershot = Energía/Disparo
|
||||||
blocks.targetsair = Apunta al Aire
|
blocks.targetsair = Apunta al Aire
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Rango
|
blocks.shootrange = Rango
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Líquido de Salida
|
|||||||
blocks.liquidoutputspeed = Velocidad de Salida del Líquido
|
blocks.liquidoutputspeed = Velocidad de Salida del Líquido
|
||||||
blocks.liquiduse = Uso de Líquido
|
blocks.liquiduse = Uso de Líquido
|
||||||
blocks.coolant = Refrigerante
|
blocks.coolant = Refrigerante
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Uso del Refrigerante
|
blocks.coolantuse = Uso del Refrigerante
|
||||||
blocks.inputliquidfuel = Combustible Líquido
|
blocks.inputliquidfuel = Combustible Líquido
|
||||||
blocks.liquidfueluse = Uso del Combustible Líquido
|
blocks.liquidfueluse = Uso del Combustible Líquido
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Vida
|
blocks.health = Vida
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Imprecisión
|
blocks.inaccuracy = Imprecisión
|
||||||
blocks.shots = Disparos
|
blocks.shots = Disparos
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Non
|
|||||||
info.title = Info
|
info.title = Info
|
||||||
error.title = [crimson]Une erreur s'est produite
|
error.title = [crimson]Une erreur s'est produite
|
||||||
error.crashtitle = Une erreur s'est produite
|
error.crashtitle = Une erreur s'est produite
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Info sur le bloc
|
blocks.blockinfo = Info sur le bloc
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = capacité d'énergie
|
blocks.powercapacity = capacité d'énergie
|
||||||
blocks.powershot = Énergie/Tir
|
blocks.powershot = Énergie/Tir
|
||||||
blocks.targetsair = Cible les unités aériennes
|
blocks.targetsair = Cible les unités aériennes
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Portée
|
blocks.shootrange = Portée
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Liquide en sortie
|
|||||||
blocks.liquidoutputspeed = Vitesse de production de liquide
|
blocks.liquidoutputspeed = Vitesse de production de liquide
|
||||||
blocks.liquiduse = Quantité de liquide utilisée
|
blocks.liquiduse = Quantité de liquide utilisée
|
||||||
blocks.coolant = Liquide de refroidissement
|
blocks.coolant = Liquide de refroidissement
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Quantité de liquide de refroidissement utilisée
|
blocks.coolantuse = Quantité de liquide de refroidissement utilisée
|
||||||
blocks.inputliquidfuel = Carburant liquide
|
blocks.inputliquidfuel = Carburant liquide
|
||||||
blocks.liquidfueluse = Quantité de carburant liquide utilisé
|
blocks.liquidfueluse = Quantité de carburant liquide utilisé
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Santé
|
blocks.health = Santé
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Précision
|
blocks.inaccuracy = Précision
|
||||||
blocks.shots = Tir
|
blocks.shots = Tir
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Non
|
|||||||
info.title = Info
|
info.title = Info
|
||||||
error.title = [crimson]Une erreur s'est produite
|
error.title = [crimson]Une erreur s'est produite
|
||||||
error.crashtitle = Une erreur s'est produite
|
error.crashtitle = Une erreur s'est produite
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Info sur le bloc
|
blocks.blockinfo = Info sur le bloc
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Capacité d'énergie
|
blocks.powercapacity = Capacité d'énergie
|
||||||
blocks.powershot = Énergie/Tir
|
blocks.powershot = Énergie/Tir
|
||||||
blocks.targetsair = Cible les unités aériennes
|
blocks.targetsair = Cible les unités aériennes
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Portée
|
blocks.shootrange = Portée
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Liquide en sortie
|
|||||||
blocks.liquidoutputspeed = Vitesse de sortie du liquide
|
blocks.liquidoutputspeed = Vitesse de sortie du liquide
|
||||||
blocks.liquiduse = Quantité de liquide utilisé
|
blocks.liquiduse = Quantité de liquide utilisé
|
||||||
blocks.coolant = Liquide de refroidissement
|
blocks.coolant = Liquide de refroidissement
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Quantité de liquide de refroidissement utilisé
|
blocks.coolantuse = Quantité de liquide de refroidissement utilisé
|
||||||
blocks.inputliquidfuel = Carburant liquide
|
blocks.inputliquidfuel = Carburant liquide
|
||||||
blocks.liquidfueluse = Quantité de carburant liquide utilisé
|
blocks.liquidfueluse = Quantité de carburant liquide utilisé
|
||||||
blocks.boostitem = Objet boostant la production
|
blocks.boostitem = Objet boostant la production
|
||||||
blocks.boostliquid = Liquide boostant la production
|
blocks.boostliquid = Liquide boostant la production
|
||||||
blocks.health = Santé
|
blocks.health = Santé
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Précision
|
blocks.inaccuracy = Précision
|
||||||
blocks.shots = Tirs
|
blocks.shots = Tirs
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = No
|
|||||||
info.title = [accent]Info
|
info.title = [accent]Info
|
||||||
error.title = [crimson]Telah terjadi kesalahan
|
error.title = [crimson]Telah terjadi kesalahan
|
||||||
error.crashtitle = Telah terjadi kesalahan
|
error.crashtitle = Telah terjadi kesalahan
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Info Blok
|
blocks.blockinfo = Info Blok
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Kapasitas Tenaga
|
blocks.powercapacity = Kapasitas Tenaga
|
||||||
blocks.powershot = Tenaga/tembakan
|
blocks.powershot = Tenaga/tembakan
|
||||||
blocks.targetsair = Targets Air
|
blocks.targetsair = Targets Air
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Range
|
blocks.shootrange = Range
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Liquid Output
|
|||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
blocks.liquidoutputspeed = Liquid Output Speed
|
||||||
blocks.liquiduse = Liquid Use
|
blocks.liquiduse = Liquid Use
|
||||||
blocks.coolant = Coolant
|
blocks.coolant = Coolant
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Coolant Use
|
blocks.coolantuse = Coolant Use
|
||||||
blocks.inputliquidfuel = Fuel Liquid
|
blocks.inputliquidfuel = Fuel Liquid
|
||||||
blocks.liquidfueluse = Liquid Fuel Use
|
blocks.liquidfueluse = Liquid Fuel Use
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Darah
|
blocks.health = Darah
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Ketidaktelitian
|
blocks.inaccuracy = Ketidaktelitian
|
||||||
blocks.shots = Tembakan
|
blocks.shots = Tembakan
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = No
|
|||||||
info.title = [accent] Info
|
info.title = [accent] Info
|
||||||
error.title = [crimson]Si è verificato un errore
|
error.title = [crimson]Si è verificato un errore
|
||||||
error.crashtitle = Si è verificato un errore
|
error.crashtitle = Si è verificato un errore
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = info sul blocco
|
blocks.blockinfo = info sul blocco
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Capacità Energetica
|
blocks.powercapacity = Capacità Energetica
|
||||||
blocks.powershot = Danno/Colpo
|
blocks.powershot = Danno/Colpo
|
||||||
blocks.targetsair = Attacca nemici aerei
|
blocks.targetsair = Attacca nemici aerei
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Raggio
|
blocks.shootrange = Raggio
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Uscita liquidi
|
|||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
blocks.liquidoutputspeed = Liquid Output Speed
|
||||||
blocks.liquiduse = Uso liquidi
|
blocks.liquiduse = Uso liquidi
|
||||||
blocks.coolant = Refrigerante
|
blocks.coolant = Refrigerante
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = uso refrigerante
|
blocks.coolantuse = uso refrigerante
|
||||||
blocks.inputliquidfuel = carburante liquido
|
blocks.inputliquidfuel = carburante liquido
|
||||||
blocks.liquidfueluse = Utilizzo carburante liquido
|
blocks.liquidfueluse = Utilizzo carburante liquido
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Salute
|
blocks.health = Salute
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Inaccuratezza
|
blocks.inaccuracy = Inaccuratezza
|
||||||
blocks.shots = Colpi
|
blocks.shots = Colpi
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = いいえ
|
|||||||
info.title = 情報
|
info.title = 情報
|
||||||
error.title = [crimson]エラーが発生しました
|
error.title = [crimson]エラーが発生しました
|
||||||
error.crashtitle = エラーが発生しました
|
error.crashtitle = エラーが発生しました
|
||||||
blocks.outputspeed = 採掘速度: {0}/秒
|
bar.drillspeed = 採掘速度: {0}/秒
|
||||||
blocks.efficiency = 効率: {0}%
|
bar.efficiency = 効率: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = ブロック情報
|
blocks.blockinfo = ブロック情報
|
||||||
blocks.powerbalance = 電力: {0}
|
bar.powerbalance = 電力: {0}
|
||||||
blocks.poweroutput = 電力発電量: {0}
|
bar.poweroutput = 電力発電量: {0}
|
||||||
blocks.powercapacity = 電力容量
|
blocks.powercapacity = 電力容量
|
||||||
blocks.powershot = 電力/ショット
|
blocks.powershot = 電力/ショット
|
||||||
blocks.targetsair = 対空攻撃
|
blocks.targetsair = 対空攻撃
|
||||||
blocks.targetsground = 対地攻撃
|
blocks.targetsground = 対地攻撃
|
||||||
blocks.items = アイテム: {0}
|
bar.items = アイテム: {0}
|
||||||
blocks.itemsmoved = 輸送速度
|
blocks.itemsmoved = 輸送速度
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = 範囲
|
blocks.shootrange = 範囲
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = 搬出液体
|
|||||||
blocks.liquidoutputspeed = 液体搬出速度
|
blocks.liquidoutputspeed = 液体搬出速度
|
||||||
blocks.liquiduse = 液体使用量
|
blocks.liquiduse = 液体使用量
|
||||||
blocks.coolant = 冷却
|
blocks.coolant = 冷却
|
||||||
blocks.liquid = 液体
|
bar.liquid = 液体
|
||||||
blocks.coolantuse = 冷却使用量
|
blocks.coolantuse = 冷却使用量
|
||||||
blocks.inputliquidfuel = 液体燃料
|
blocks.inputliquidfuel = 液体燃料
|
||||||
blocks.liquidfueluse = 液体燃料使用量
|
blocks.liquidfueluse = 液体燃料使用量
|
||||||
blocks.boostitem = 加速アイテム
|
blocks.boostitem = 加速アイテム
|
||||||
blocks.boostliquid = 加速液体
|
blocks.boostliquid = 加速液体
|
||||||
blocks.health = 耐久値
|
blocks.health = 耐久値
|
||||||
blocks.heat = 熱
|
bar.heat = 熱
|
||||||
blocks.power = 電力
|
bar.power = 電力
|
||||||
blocks.progress = 建設状況
|
bar.progress = 建設状況
|
||||||
blocks.spawned = ユニット数: {0}/{1}
|
bar.spawned = ユニット数: {0}/{1}
|
||||||
blocks.power.satisfaction = 電力需要
|
blocks.power.satisfaction = 電力需要
|
||||||
blocks.inaccuracy = 精度のずれ
|
blocks.inaccuracy = 精度のずれ
|
||||||
blocks.shots = ショット
|
blocks.shots = ショット
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = 아니오
|
|||||||
info.title = [accent]정보
|
info.title = [accent]정보
|
||||||
error.title = [crimson]오류가 발생했습니다.
|
error.title = [crimson]오류가 발생했습니다.
|
||||||
error.crashtitle = 오류가 발생했습니다.
|
error.crashtitle = 오류가 발생했습니다.
|
||||||
blocks.outputspeed = 채광 속도: {0}/s
|
bar.outputspeed = 채광 속도: {0}/s
|
||||||
blocks.efficiency = 효율성: {0}%
|
bar.efficiency = 효율성: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = 블록 정보
|
blocks.blockinfo = 블록 정보
|
||||||
blocks.powerbalance = 전력: {0}
|
bar.powerbalance = 전력: {0}
|
||||||
blocks.poweroutput = 전력 출력: {0}
|
bar.poweroutput = 전력 출력: {0}
|
||||||
blocks.powercapacity = 전력 용량
|
blocks.powercapacity = 전력 용량
|
||||||
blocks.powershot = 1발당 전력 소모량
|
blocks.powershot = 1발당 전력 소모량
|
||||||
blocks.targetsair = 공중공격 가능
|
blocks.targetsair = 공중공격 가능
|
||||||
blocks.targetsground = 지상공격 가능
|
blocks.targetsground = 지상공격 가능
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = 이동 속도
|
blocks.itemsmoved = 이동 속도
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = 사거리
|
blocks.shootrange = 사거리
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = 액체 출력
|
|||||||
blocks.liquidoutputspeed = 액체 출력속도
|
blocks.liquidoutputspeed = 액체 출력속도
|
||||||
blocks.liquiduse = 액체 사용량
|
blocks.liquiduse = 액체 사용량
|
||||||
blocks.coolant = 냉각제
|
blocks.coolant = 냉각제
|
||||||
blocks.liquid = 액체
|
bar.liquid = 액체
|
||||||
blocks.coolantuse = 냉각제 사용
|
blocks.coolantuse = 냉각제 사용
|
||||||
blocks.inputliquidfuel = 연료 액
|
blocks.inputliquidfuel = 연료 액
|
||||||
blocks.liquidfueluse = 액체 연료 사용
|
blocks.liquidfueluse = 액체 연료 사용
|
||||||
blocks.boostitem = 가속 아이템
|
blocks.boostitem = 가속 아이템
|
||||||
blocks.boostliquid = 가속 액체
|
blocks.boostliquid = 가속 액체
|
||||||
blocks.health = 체력
|
blocks.health = 체력
|
||||||
blocks.heat = 발열
|
bar.heat = 발열
|
||||||
blocks.power = 전력
|
bar.power = 전력
|
||||||
blocks.progress = 건설 진행
|
bar.progress = 건설 진행
|
||||||
blocks.spawned = 유닛: {0}/{1}
|
bar.spawned = 유닛: {0}/{1}
|
||||||
blocks.power.satisfaction = 전력 만족도
|
blocks.power.satisfaction = 전력 만족도
|
||||||
blocks.inaccuracy = 오차각
|
blocks.inaccuracy = 오차각
|
||||||
blocks.shots = 발포 횟수
|
blocks.shots = 발포 횟수
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = No
|
|||||||
info.title = Info
|
info.title = Info
|
||||||
error.title = [crimson]An error has occured
|
error.title = [crimson]An error has occured
|
||||||
error.crashtitle = An error has occured
|
error.crashtitle = An error has occured
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Block Info
|
blocks.blockinfo = Block Info
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Power Capacity
|
blocks.powercapacity = Power Capacity
|
||||||
blocks.powershot = Power/Shot
|
blocks.powershot = Power/Shot
|
||||||
blocks.targetsair = Targets Air
|
blocks.targetsair = Targets Air
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Range
|
blocks.shootrange = Range
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Liquid Output
|
|||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
blocks.liquidoutputspeed = Liquid Output Speed
|
||||||
blocks.liquiduse = Liquid Use
|
blocks.liquiduse = Liquid Use
|
||||||
blocks.coolant = Coolant
|
blocks.coolant = Coolant
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Coolant Use
|
blocks.coolantuse = Coolant Use
|
||||||
blocks.inputliquidfuel = Fuel Liquid
|
blocks.inputliquidfuel = Fuel Liquid
|
||||||
blocks.liquidfueluse = Liquid Fuel Use
|
blocks.liquidfueluse = Liquid Fuel Use
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Health
|
blocks.health = Health
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Inaccuracy
|
blocks.inaccuracy = Inaccuracy
|
||||||
blocks.shots = Shots
|
blocks.shots = Shots
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Nie ma mowy!
|
|||||||
info.title = [accent]Informacje
|
info.title = [accent]Informacje
|
||||||
error.title = [crimson]Wystąpił błąd
|
error.title = [crimson]Wystąpił błąd
|
||||||
error.crashtitle = Wystąpił błąd
|
error.crashtitle = Wystąpił błąd
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Informacje o bloku
|
blocks.blockinfo = Informacje o bloku
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Pojemność mocy
|
blocks.powercapacity = Pojemność mocy
|
||||||
blocks.powershot = moc/strzał
|
blocks.powershot = moc/strzał
|
||||||
blocks.targetsair = Może namierzać wrogów powietrznych
|
blocks.targetsair = Może namierzać wrogów powietrznych
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Zasięg
|
blocks.shootrange = Zasięg
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Wyprodukowany płyn
|
|||||||
blocks.liquidoutputspeed = Prędkość odpływu cieczy
|
blocks.liquidoutputspeed = Prędkość odpływu cieczy
|
||||||
blocks.liquiduse = Zużycie płynów
|
blocks.liquiduse = Zużycie płynów
|
||||||
blocks.coolant = Płyn chłodzący
|
blocks.coolant = Płyn chłodzący
|
||||||
blocks.liquid = Płyn
|
bar.liquid = Płyn
|
||||||
blocks.coolantuse = Zużycie płynu chłodzącego
|
blocks.coolantuse = Zużycie płynu chłodzącego
|
||||||
blocks.inputliquidfuel = Paliwo
|
blocks.inputliquidfuel = Paliwo
|
||||||
blocks.liquidfueluse = Zużycie paliwa
|
blocks.liquidfueluse = Zużycie paliwa
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Zdrowie
|
blocks.health = Zdrowie
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Prąd
|
bar.power = Prąd
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Zapotrzebowanie Prądu
|
blocks.power.satisfaction = Zapotrzebowanie Prądu
|
||||||
blocks.inaccuracy = Niedokładność
|
blocks.inaccuracy = Niedokładność
|
||||||
blocks.shots = Strzały
|
blocks.shots = Strzały
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Não
|
|||||||
info.title = [accent]Informação
|
info.title = [accent]Informação
|
||||||
error.title = [crimson]Ocorreu um Erro.
|
error.title = [crimson]Ocorreu um Erro.
|
||||||
error.crashtitle = Ocorreu um Erro
|
error.crashtitle = Ocorreu um Erro
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Informação do Bloco
|
blocks.blockinfo = Informação do Bloco
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Capacidade de Energia
|
blocks.powercapacity = Capacidade de Energia
|
||||||
blocks.powershot = Energia/tiro
|
blocks.powershot = Energia/tiro
|
||||||
blocks.targetsair = Mirar no ar
|
blocks.targetsair = Mirar no ar
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Alcance
|
blocks.shootrange = Alcance
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Saida de liquido
|
|||||||
blocks.liquidoutputspeed = Velocidade da saida de líquido
|
blocks.liquidoutputspeed = Velocidade da saida de líquido
|
||||||
blocks.liquiduse = Uso de liquido
|
blocks.liquiduse = Uso de liquido
|
||||||
blocks.coolant = Esfriador
|
blocks.coolant = Esfriador
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Uso do esfriador
|
blocks.coolantuse = Uso do esfriador
|
||||||
blocks.inputliquidfuel = Liquido de combustivel
|
blocks.inputliquidfuel = Liquido de combustivel
|
||||||
blocks.liquidfueluse = Uso do liquido de combustivel
|
blocks.liquidfueluse = Uso do liquido de combustivel
|
||||||
blocks.boostitem = Acelerar item
|
blocks.boostitem = Acelerar item
|
||||||
blocks.boostliquid = Acelerar líquido
|
blocks.boostliquid = Acelerar líquido
|
||||||
blocks.health = Saúde
|
blocks.health = Saúde
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Poder
|
bar.power = Poder
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = Imprecisão
|
blocks.inaccuracy = Imprecisão
|
||||||
blocks.shots = Tiros
|
blocks.shots = Tiros
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Нет
|
|||||||
info.title = Информация
|
info.title = Информация
|
||||||
error.title = [crimson]Произошла ошибка
|
error.title = [crimson]Произошла ошибка
|
||||||
error.crashtitle = Произошла ошибка
|
error.crashtitle = Произошла ошибка
|
||||||
blocks.outputspeed = Скорость сверления: {0}/с
|
bar.drillspeed = Скорость сверления: {0}/с
|
||||||
blocks.efficiency = Эффективность: {0}%
|
bar.efficiency = Эффективность: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Информация о блоке
|
blocks.blockinfo = Информация о блоке
|
||||||
blocks.powerbalance = Энергия: {0}
|
bar.powerbalance = Энергия: {0}
|
||||||
blocks.poweroutput = Выходная энергия: {0}
|
bar.poweroutput = Выходная энергия: {0}
|
||||||
blocks.powercapacity = Вместимость энергии
|
blocks.powercapacity = Вместимость энергии
|
||||||
blocks.powershot = Энергия/выстрел
|
blocks.powershot = Энергия/выстрел
|
||||||
blocks.targetsair = Воздушные цели
|
blocks.targetsair = Воздушные цели
|
||||||
blocks.targetsground = Наземные цели
|
blocks.targetsground = Наземные цели
|
||||||
blocks.items = Предметы: {0}
|
bar.items = Предметы: {0}
|
||||||
blocks.itemsmoved = Скорость перемещения
|
blocks.itemsmoved = Скорость перемещения
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Радиус действия
|
blocks.shootrange = Радиус действия
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Выходящая жидкость
|
|||||||
blocks.liquidoutputspeed = Выходная скорость жидкости
|
blocks.liquidoutputspeed = Выходная скорость жидкости
|
||||||
blocks.liquiduse = Используется жидкости
|
blocks.liquiduse = Используется жидкости
|
||||||
blocks.coolant = Охлаждающая жидкость
|
blocks.coolant = Охлаждающая жидкость
|
||||||
blocks.liquid = Жидкость
|
bar.liquid = Жидкость
|
||||||
blocks.coolantuse = Охлажд. жидкости используется
|
blocks.coolantuse = Охлажд. жидкости используется
|
||||||
blocks.inputliquidfuel = Жидкое топливо
|
blocks.inputliquidfuel = Жидкое топливо
|
||||||
blocks.liquidfueluse = Жидкого топлива используется
|
blocks.liquidfueluse = Жидкого топлива используется
|
||||||
blocks.boostitem = Ускоряющий предмет
|
blocks.boostitem = Ускоряющий предмет
|
||||||
blocks.boostliquid = Ускоряющая жидкость
|
blocks.boostliquid = Ускоряющая жидкость
|
||||||
blocks.health = Здоровье
|
blocks.health = Здоровье
|
||||||
blocks.heat = Температура
|
bar.heat = Температура
|
||||||
blocks.power = Энергия
|
bar.power = Энергия
|
||||||
blocks.progress = Строительство продолжается
|
bar.progress = Строительство продолжается
|
||||||
blocks.spawned = Бой. ед.: {0}/{1}
|
bar.spawned = Бой. ед.: {0}/{1}
|
||||||
blocks.power.satisfaction = Энергия
|
blocks.power.satisfaction = Энергия
|
||||||
blocks.inaccuracy = Разброс
|
blocks.inaccuracy = Разброс
|
||||||
blocks.shots = Выстрелы
|
blocks.shots = Выстрелы
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Hayir
|
|||||||
info.title = [accent]Bilgi
|
info.title = [accent]Bilgi
|
||||||
error.title = [crimson]Bir hata olustu
|
error.title = [crimson]Bir hata olustu
|
||||||
error.crashtitle = Bir hata olustu
|
error.crashtitle = Bir hata olustu
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Yapi bilgisi
|
blocks.blockinfo = Yapi bilgisi
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Guc kapasitesi
|
blocks.powercapacity = Guc kapasitesi
|
||||||
blocks.powershot = Guc/Saldiri hizi
|
blocks.powershot = Guc/Saldiri hizi
|
||||||
blocks.targetsair = Havayi hedef alir mi?
|
blocks.targetsair = Havayi hedef alir mi?
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Menzil
|
blocks.shootrange = Menzil
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Sivi cikisi
|
|||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
blocks.liquidoutputspeed = Liquid Output Speed
|
||||||
blocks.liquiduse = Sivi kullanimi
|
blocks.liquiduse = Sivi kullanimi
|
||||||
blocks.coolant = Sogutma sivisi
|
blocks.coolant = Sogutma sivisi
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Sogutma sivi kullanimi
|
blocks.coolantuse = Sogutma sivi kullanimi
|
||||||
blocks.inputliquidfuel = Yakit sivisi
|
blocks.inputliquidfuel = Yakit sivisi
|
||||||
blocks.liquidfueluse = Sivi yakit kullanimi
|
blocks.liquidfueluse = Sivi yakit kullanimi
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Can
|
blocks.health = Can
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = sekme
|
blocks.inaccuracy = sekme
|
||||||
blocks.shots = vuruslar
|
blocks.shots = vuruslar
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = No
|
|||||||
info.title = [Vurgu] Bilgi
|
info.title = [Vurgu] Bilgi
|
||||||
error.title = [crimson] Bir hata oluştu
|
error.title = [crimson] Bir hata oluştu
|
||||||
error.crashtitle = Bir hata oluştu
|
error.crashtitle = Bir hata oluştu
|
||||||
blocks.outputspeed = Drill Speed: {0}/s
|
bar.drillspeed = Drill Speed: {0}/s
|
||||||
blocks.efficiency = Efficiency: {0}%
|
bar.efficiency = Efficiency: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Blok Bilgisi
|
blocks.blockinfo = Blok Bilgisi
|
||||||
blocks.powerbalance = Power: {0}
|
bar.powerbalance = Power: {0}
|
||||||
blocks.poweroutput = Power Output: {0}
|
bar.poweroutput = Power Output: {0}
|
||||||
blocks.powercapacity = Güç kapasitesi
|
blocks.powercapacity = Güç kapasitesi
|
||||||
blocks.powershot = Güç / atış
|
blocks.powershot = Güç / atış
|
||||||
blocks.targetsair = Targets Air
|
blocks.targetsair = Targets Air
|
||||||
blocks.targetsground = Targets Ground
|
blocks.targetsground = Targets Ground
|
||||||
blocks.items = Items: {0}
|
bar.items = Items: {0}
|
||||||
blocks.itemsmoved = Move Speed
|
blocks.itemsmoved = Move Speed
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Range
|
blocks.shootrange = Range
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Liquid Output
|
|||||||
blocks.liquidoutputspeed = Liquid Output Speed
|
blocks.liquidoutputspeed = Liquid Output Speed
|
||||||
blocks.liquiduse = Liquid Use
|
blocks.liquiduse = Liquid Use
|
||||||
blocks.coolant = Coolant
|
blocks.coolant = Coolant
|
||||||
blocks.liquid = Liquid
|
bar.liquid = Liquid
|
||||||
blocks.coolantuse = Coolant Use
|
blocks.coolantuse = Coolant Use
|
||||||
blocks.inputliquidfuel = Fuel Liquid
|
blocks.inputliquidfuel = Fuel Liquid
|
||||||
blocks.liquidfueluse = Liquid Fuel Use
|
blocks.liquidfueluse = Liquid Fuel Use
|
||||||
blocks.boostitem = Boost Item
|
blocks.boostitem = Boost Item
|
||||||
blocks.boostliquid = Boost Liquid
|
blocks.boostliquid = Boost Liquid
|
||||||
blocks.health = Can
|
blocks.health = Can
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = Power
|
bar.power = Power
|
||||||
blocks.progress = Build Progress
|
bar.progress = Build Progress
|
||||||
blocks.spawned = Units: {0}/{1}
|
bar.spawned = Units: {0}/{1}
|
||||||
blocks.power.satisfaction = Power Satisfaction
|
blocks.power.satisfaction = Power Satisfaction
|
||||||
blocks.inaccuracy = yanlışlık
|
blocks.inaccuracy = yanlışlık
|
||||||
blocks.shots = atışlar
|
blocks.shots = atışlar
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = Ні
|
|||||||
info.title = Інформація
|
info.title = Інформація
|
||||||
error.title = [crimson]Виникла помилка
|
error.title = [crimson]Виникла помилка
|
||||||
error.crashtitle = Виникла помилка
|
error.crashtitle = Виникла помилка
|
||||||
blocks.outputspeed = Швидкість свердління: {0}/с
|
bar.drillspeed = Швидкість свердління: {0}/с
|
||||||
blocks.efficiency = Ефективність: {0}%
|
bar.efficiency = Ефективність: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = Інформація про блок
|
blocks.blockinfo = Інформація про блок
|
||||||
blocks.powerbalance = Енергія: {0}
|
bar.powerbalance = Енергія: {0}
|
||||||
blocks.poweroutput = Вихідна енергія: {0}
|
bar.poweroutput = Вихідна енергія: {0}
|
||||||
blocks.powercapacity = Місткість енергії
|
blocks.powercapacity = Місткість енергії
|
||||||
blocks.powershot = Енергія/постріл
|
blocks.powershot = Енергія/постріл
|
||||||
blocks.targetsair = Повітряні мішені
|
blocks.targetsair = Повітряні мішені
|
||||||
blocks.targetsground = Наземні мішені
|
blocks.targetsground = Наземні мішені
|
||||||
blocks.items = Предмети: {0}
|
bar.items = Предмети: {0}
|
||||||
blocks.itemsmoved = Швидкість переміщення
|
blocks.itemsmoved = Швидкість переміщення
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = Діапазон дії
|
blocks.shootrange = Діапазон дії
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = Вихідна рідина
|
|||||||
blocks.liquidoutputspeed = Швидкість вихідної рідини
|
blocks.liquidoutputspeed = Швидкість вихідної рідини
|
||||||
blocks.liquiduse = Використовуеться рідин
|
blocks.liquiduse = Використовуеться рідин
|
||||||
blocks.coolant = Охолоджуюча рідина
|
blocks.coolant = Охолоджуюча рідина
|
||||||
blocks.liquid = Рідина
|
bar.liquid = Рідина
|
||||||
blocks.coolantuse = Охолодж. рідини використовуеться
|
blocks.coolantuse = Охолодж. рідини використовуеться
|
||||||
blocks.inputliquidfuel = Рідке паливо
|
blocks.inputliquidfuel = Рідке паливо
|
||||||
blocks.liquidfueluse = Рідкого палива використовуеться
|
blocks.liquidfueluse = Рідкого палива використовуеться
|
||||||
blocks.boostitem = Прискорюючий предмет
|
blocks.boostitem = Прискорюючий предмет
|
||||||
blocks.boostliquid = Прискорююча рідина
|
blocks.boostliquid = Прискорююча рідина
|
||||||
blocks.health = Здоров'я
|
blocks.health = Здоров'я
|
||||||
blocks.heat = Температура
|
bar.heat = Температура
|
||||||
blocks.power = Енергія
|
bar.power = Енергія
|
||||||
blocks.progress = Будівництво триває
|
bar.progress = Будівництво триває
|
||||||
blocks.spawned = Бой. од.: {0}/{1}
|
bar.spawned = Бой. од.: {0}/{1}
|
||||||
blocks.power.satisfaction = Енергія
|
blocks.power.satisfaction = Енергія
|
||||||
blocks.inaccuracy = Розкид
|
blocks.inaccuracy = Розкид
|
||||||
blocks.shots = Постріли
|
blocks.shots = Постріли
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = 不
|
|||||||
info.title = [accent]详情
|
info.title = [accent]详情
|
||||||
error.title = [crimson]发生了一个错误
|
error.title = [crimson]发生了一个错误
|
||||||
error.crashtitle = 发生了一个错误
|
error.crashtitle = 发生了一个错误
|
||||||
blocks.outputspeed = 挖掘速度: {0}/s
|
bar.drillspeed = 挖掘速度: {0}/s
|
||||||
blocks.efficiency = 效率: {0}%
|
bar.efficiency = 效率: {0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = 方块详情
|
blocks.blockinfo = 方块详情
|
||||||
blocks.powerbalance = 能量: {0}
|
bar.powerbalance = 能量: {0}
|
||||||
blocks.poweroutput = 能量输出: {0}
|
bar.poweroutput = 能量输出: {0}
|
||||||
blocks.powercapacity = 能量容量
|
blocks.powercapacity = 能量容量
|
||||||
blocks.powershot = 能量/发射
|
blocks.powershot = 能量/发射
|
||||||
blocks.targetsair = 攻击空中单位
|
blocks.targetsair = 攻击空中单位
|
||||||
blocks.targetsground = 攻击地面单位
|
blocks.targetsground = 攻击地面单位
|
||||||
blocks.items = 物体: {0}
|
bar.items = 物体: {0}
|
||||||
blocks.itemsmoved = 移动速度
|
blocks.itemsmoved = 移动速度
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = 范围
|
blocks.shootrange = 范围
|
||||||
@@ -375,18 +375,17 @@ blocks.liquidoutput = 液体输出
|
|||||||
blocks.liquidoutputspeed = 液体输出速度
|
blocks.liquidoutputspeed = 液体输出速度
|
||||||
blocks.liquiduse = 液体使用速度
|
blocks.liquiduse = 液体使用速度
|
||||||
blocks.coolant = 冷却剂
|
blocks.coolant = 冷却剂
|
||||||
blocks.liquid = 液体
|
bar.liquid = 液体
|
||||||
blocks.coolantuse = 冷却剂使用速度
|
blocks.coolantuse = 冷却剂使用速度
|
||||||
blocks.inputliquidfuel = 液体燃料输入
|
blocks.inputliquidfuel = 液体燃料输入
|
||||||
blocks.liquidfueluse = 液体燃料使用速度
|
blocks.liquidfueluse = 液体燃料使用速度
|
||||||
blocks.boostitem = 强化物件
|
blocks.boostitem = 强化物件
|
||||||
blocks.boostliquid = 强化液体
|
blocks.boostliquid = 强化液体
|
||||||
blocks.health = 生命值
|
blocks.health = 生命值
|
||||||
blocks.heat = Heat
|
bar.heat = Heat
|
||||||
blocks.power = 电力
|
bar.power = 电力
|
||||||
blocks.progress = 制造进度
|
bar.progress = 制造进度
|
||||||
blocks.spawned = 单位数量: {0}/{1}
|
bar.spawned = 单位数量: {0}/{1}
|
||||||
blocks.power.satisfaction = 电力输入
|
|
||||||
blocks.inaccuracy = 误差
|
blocks.inaccuracy = 误差
|
||||||
blocks.shots = 发射数
|
blocks.shots = 发射数
|
||||||
blocks.reload = 重新装弹
|
blocks.reload = 重新装弹
|
||||||
|
|||||||
@@ -335,17 +335,17 @@ no = 否
|
|||||||
info.title = [accent]資訊
|
info.title = [accent]資訊
|
||||||
error.title = [crimson]發生錯誤
|
error.title = [crimson]發生錯誤
|
||||||
error.crashtitle = 發生錯誤
|
error.crashtitle = 發生錯誤
|
||||||
blocks.outputspeed = 鑽頭速度:{0}/秒
|
bar.drillspeed = 鑽頭速度:{0}/秒
|
||||||
blocks.efficiency = 效率:{0}%
|
bar.efficiency = 效率:{0}%
|
||||||
blocks.unknown = [LIGHT_GRAY]???
|
block.unknown = [LIGHT_GRAY]???
|
||||||
blocks.blockinfo = 方塊資訊
|
blocks.blockinfo = 方塊資訊
|
||||||
blocks.powerbalance = 能量變化:{0}
|
bar.powerbalance = 能量變化:{0}
|
||||||
blocks.poweroutput = 能量輸出:{0}
|
bar.poweroutput = 能量輸出:{0}
|
||||||
blocks.powercapacity = 蓄電量
|
blocks.powercapacity = 蓄電量
|
||||||
blocks.powershot = 能量/射擊
|
blocks.powershot = 能量/射擊
|
||||||
blocks.targetsair = 攻擊空中目標
|
blocks.targetsair = 攻擊空中目標
|
||||||
blocks.targetsground = 攻擊地面
|
blocks.targetsground = 攻擊地面
|
||||||
blocks.items = 物品:{0}
|
bar.items = 物品:{0}
|
||||||
blocks.itemsmoved = 移動速度
|
blocks.itemsmoved = 移動速度
|
||||||
blocks.launchtime = Time Between Launches
|
blocks.launchtime = Time Between Launches
|
||||||
blocks.shootrange = 範圍
|
blocks.shootrange = 範圍
|
||||||
@@ -375,17 +375,17 @@ blocks.liquidoutput = 輸出液體
|
|||||||
blocks.liquidoutputspeed = 輸出液體速度
|
blocks.liquidoutputspeed = 輸出液體速度
|
||||||
blocks.liquiduse = 使用液體速度
|
blocks.liquiduse = 使用液體速度
|
||||||
blocks.coolant = 冷卻劑
|
blocks.coolant = 冷卻劑
|
||||||
blocks.liquid = 液體
|
bar.liquid = 液體
|
||||||
blocks.coolantuse = 使用冷卻劑
|
blocks.coolantuse = 使用冷卻劑
|
||||||
blocks.inputliquidfuel = 輸入液體燃料
|
blocks.inputliquidfuel = 輸入液體燃料
|
||||||
blocks.liquidfueluse = 使用液體燃料速度
|
blocks.liquidfueluse = 使用液體燃料速度
|
||||||
blocks.boostitem = 強化物品
|
blocks.boostitem = 強化物品
|
||||||
blocks.boostliquid = 強化液體
|
blocks.boostliquid = 強化液體
|
||||||
blocks.health = 耐久度
|
blocks.health = 耐久度
|
||||||
blocks.heat = 熱
|
bar.heat = 熱
|
||||||
blocks.power = 能量
|
bar.power = 能量
|
||||||
blocks.progress = 建造進度
|
bar.progress = 建造進度
|
||||||
blocks.spawned = 單位:{0}/{1}
|
bar.spawned = 單位:{0}/{1}
|
||||||
blocks.power.satisfaction = 能量滿意度
|
blocks.power.satisfaction = 能量滿意度
|
||||||
blocks.inaccuracy = 誤差
|
blocks.inaccuracy = 誤差
|
||||||
blocks.shots = 射擊數
|
blocks.shots = 射擊數
|
||||||
|
|||||||
@@ -3,11 +3,17 @@ package io.anuke.mindustry.content;
|
|||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.Color;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
|
import io.anuke.arc.graphics.g2d.Lines;
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
|
import io.anuke.arc.math.Mathf;
|
||||||
|
import io.anuke.mindustry.Vars;
|
||||||
import io.anuke.mindustry.game.ContentList;
|
import io.anuke.mindustry.game.ContentList;
|
||||||
import io.anuke.mindustry.graphics.CacheLayer;
|
import io.anuke.mindustry.graphics.CacheLayer;
|
||||||
|
import io.anuke.mindustry.graphics.Pal;
|
||||||
|
import io.anuke.mindustry.graphics.Shaders;
|
||||||
import io.anuke.mindustry.type.Category;
|
import io.anuke.mindustry.type.Category;
|
||||||
import io.anuke.mindustry.type.ItemStack;
|
import io.anuke.mindustry.type.ItemStack;
|
||||||
|
import io.anuke.mindustry.type.LiquidStack;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.blocks.*;
|
import io.anuke.mindustry.world.blocks.*;
|
||||||
@@ -24,9 +30,9 @@ import io.anuke.mindustry.world.blocks.storage.Vault;
|
|||||||
import io.anuke.mindustry.world.blocks.units.MechPad;
|
import io.anuke.mindustry.world.blocks.units.MechPad;
|
||||||
import io.anuke.mindustry.world.blocks.units.RepairPoint;
|
import io.anuke.mindustry.world.blocks.units.RepairPoint;
|
||||||
import io.anuke.mindustry.world.blocks.units.UnitFactory;
|
import io.anuke.mindustry.world.blocks.units.UnitFactory;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItemFilter;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
||||||
import io.anuke.mindustry.world.meta.Attribute;
|
import io.anuke.mindustry.world.meta.Attribute;
|
||||||
|
import io.anuke.mindustry.world.modules.LiquidModule;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.state;
|
import static io.anuke.mindustry.Vars.state;
|
||||||
import static io.anuke.mindustry.Vars.world;
|
import static io.anuke.mindustry.Vars.world;
|
||||||
@@ -87,6 +93,7 @@ public class Blocks implements ContentList{
|
|||||||
|
|
||||||
air = new Floor("air"){{
|
air = new Floor("air"){{
|
||||||
alwaysReplace = true;
|
alwaysReplace = true;
|
||||||
|
hasShadow = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void draw(Tile tile){}
|
public void draw(Tile tile){}
|
||||||
@@ -370,7 +377,7 @@ public class Blocks implements ContentList{
|
|||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 150, Items.lead, 60));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 150, Items.lead, 60));
|
||||||
|
|
||||||
craftEffect = Fx.pulverizeMedium;
|
craftEffect = Fx.pulverizeMedium;
|
||||||
output = Items.graphite;
|
outputItem = new ItemStack(Items.graphite, 1);
|
||||||
craftTime = 90f;
|
craftTime = 90f;
|
||||||
size = 2;
|
size = 2;
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
@@ -382,7 +389,7 @@ public class Blocks implements ContentList{
|
|||||||
requirements(Category.crafting, ItemStack.with(Items.titanium, 200, Items.silicon, 50, Items.lead, 200, Items.graphite, 100));
|
requirements(Category.crafting, ItemStack.with(Items.titanium, 200, Items.silicon, 50, Items.lead, 200, Items.graphite, 100));
|
||||||
|
|
||||||
craftEffect = Fx.pulverizeMedium;
|
craftEffect = Fx.pulverizeMedium;
|
||||||
output = Items.graphite;
|
outputItem = new ItemStack(Items.graphite, 2);
|
||||||
craftTime = 30f;
|
craftTime = 30f;
|
||||||
size = 3;
|
size = 3;
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
@@ -390,14 +397,14 @@ public class Blocks implements ContentList{
|
|||||||
hasPower = true;
|
hasPower = true;
|
||||||
|
|
||||||
consumes.power(2f);
|
consumes.power(2f);
|
||||||
consumes.item(Items.coal, 2);
|
consumes.item(Items.coal, 4);
|
||||||
consumes.liquid(Liquids.water, 0.1f);
|
consumes.liquid(Liquids.water, 0.1f);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
siliconSmelter = new PowerSmelter("silicon-smelter"){{
|
siliconSmelter = new GenericSmelter("silicon-smelter"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 60, Items.lead, 50));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 60, Items.lead, 50));
|
||||||
craftEffect = Fx.smeltsmoke;
|
craftEffect = Fx.smeltsmoke;
|
||||||
output = Items.silicon;
|
outputItem = new ItemStack(Items.silicon, 1);
|
||||||
craftTime = 40f;
|
craftTime = 40f;
|
||||||
size = 2;
|
size = 2;
|
||||||
hasLiquids = false;
|
hasLiquids = false;
|
||||||
@@ -407,10 +414,10 @@ public class Blocks implements ContentList{
|
|||||||
consumes.power(0.50f);
|
consumes.power(0.50f);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
kiln = new PowerSmelter("kiln"){{
|
kiln = new GenericSmelter("kiln"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 120, Items.graphite, 60, Items.lead, 60));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 120, Items.graphite, 60, Items.lead, 60));
|
||||||
craftEffect = Fx.smeltsmoke;
|
craftEffect = Fx.smeltsmoke;
|
||||||
output = Items.metaglass;
|
outputItem = new ItemStack(Items.metaglass, 1);
|
||||||
craftTime = 30f;
|
craftTime = 30f;
|
||||||
size = 2;
|
size = 2;
|
||||||
hasPower = hasItems = true;
|
hasPower = hasItems = true;
|
||||||
@@ -420,12 +427,12 @@ public class Blocks implements ContentList{
|
|||||||
consumes.power(0.60f);
|
consumes.power(0.60f);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
plastaniumCompressor = new PlastaniumCompressor("plastanium-compressor"){{
|
plastaniumCompressor = new GenericCrafter("plastanium-compressor"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.silicon, 160, Items.lead, 230, Items.graphite, 120, Items.titanium, 160));
|
requirements(Category.crafting, ItemStack.with(Items.silicon, 160, Items.lead, 230, Items.graphite, 120, Items.titanium, 160));
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
liquidCapacity = 60f;
|
liquidCapacity = 60f;
|
||||||
craftTime = 60f;
|
craftTime = 60f;
|
||||||
output = Items.plastanium;
|
outputItem = new ItemStack(Items.plastanium, 1);
|
||||||
size = 2;
|
size = 2;
|
||||||
health = 320;
|
health = 320;
|
||||||
hasPower = hasLiquids = true;
|
hasPower = hasLiquids = true;
|
||||||
@@ -435,23 +442,69 @@ public class Blocks implements ContentList{
|
|||||||
consumes.liquid(Liquids.oil, 0.25f);
|
consumes.liquid(Liquids.oil, 0.25f);
|
||||||
consumes.power(3f);
|
consumes.power(3f);
|
||||||
consumes.item(Items.titanium, 2);
|
consumes.item(Items.titanium, 2);
|
||||||
|
|
||||||
|
int topRegion = reg("-top");
|
||||||
|
|
||||||
|
drawer = tile -> {
|
||||||
|
super.draw(tile);
|
||||||
|
|
||||||
|
GenericCrafterEntity entity = tile.entity();
|
||||||
|
|
||||||
|
Draw.alpha(Mathf.absin(entity.totalProgress, 3f, 0.9f) * entity.warmup);
|
||||||
|
Draw.rect(reg(topRegion), tile.drawx(), tile.drawy());
|
||||||
|
Draw.reset();
|
||||||
|
};
|
||||||
}};
|
}};
|
||||||
|
|
||||||
phaseWeaver = new PhaseWeaver("phase-weaver"){{
|
phaseWeaver = new GenericCrafter("phase-weaver"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.silicon, 260, Items.lead, 240, Items.thorium, 150));
|
requirements(Category.crafting, ItemStack.with(Items.silicon, 260, Items.lead, 240, Items.thorium, 150));
|
||||||
craftEffect = Fx.smeltsmoke;
|
craftEffect = Fx.smeltsmoke;
|
||||||
output = Items.phasefabric;
|
outputItem = new ItemStack(Items.phasefabric, 1);
|
||||||
craftTime = 120f;
|
craftTime = 120f;
|
||||||
size = 2;
|
size = 2;
|
||||||
|
|
||||||
consumes.items(new ItemStack(Items.thorium, 4), new ItemStack(Items.sand, 10));
|
consumes.items(new ItemStack(Items.thorium, 4), new ItemStack(Items.sand, 10));
|
||||||
consumes.power(5f);
|
consumes.power(5f);
|
||||||
|
|
||||||
|
int bottomRegion = reg("-bottom"), weaveRegion = reg("-weave");
|
||||||
|
|
||||||
|
drawer = tile -> {
|
||||||
|
GenericCrafterEntity entity = tile.entity();
|
||||||
|
|
||||||
|
Draw.rect(reg(bottomRegion), tile.drawx(), tile.drawy());
|
||||||
|
|
||||||
|
float progress = 0.5f;
|
||||||
|
|
||||||
|
Shaders.build.region = reg(weaveRegion);
|
||||||
|
Shaders.build.progress = progress;
|
||||||
|
Shaders.build.color.set(Pal.accent);
|
||||||
|
Shaders.build.color.a = entity.warmup;
|
||||||
|
Shaders.build.time = -entity.totalProgress / 10f;
|
||||||
|
|
||||||
|
Draw.shader(Shaders.build, false);
|
||||||
|
Shaders.build.apply();
|
||||||
|
Draw.rect(reg(weaveRegion), tile.drawx(), tile.drawy(), entity.totalProgress);
|
||||||
|
Draw.shader();
|
||||||
|
|
||||||
|
Draw.color(Pal.accent);
|
||||||
|
Draw.alpha(entity.warmup);
|
||||||
|
|
||||||
|
Lines.lineAngleCenter(
|
||||||
|
tile.drawx() + Mathf.sin(entity.totalProgress, 6f, Vars.tilesize / 3f * size),
|
||||||
|
tile.drawy(),
|
||||||
|
90,
|
||||||
|
size * Vars.tilesize / 2f);
|
||||||
|
|
||||||
|
Draw.reset();
|
||||||
|
|
||||||
|
Draw.rect(region, tile.drawx(), tile.drawy());
|
||||||
|
};
|
||||||
}};
|
}};
|
||||||
|
|
||||||
surgeSmelter = new PowerSmelter("alloy-smelter"){{
|
surgeSmelter = new GenericSmelter("alloy-smelter"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.silicon, 160, Items.lead, 160, Items.thorium, 140));
|
requirements(Category.crafting, ItemStack.with(Items.silicon, 160, Items.lead, 160, Items.thorium, 140));
|
||||||
craftEffect = Fx.smeltsmoke;
|
craftEffect = Fx.smeltsmoke;
|
||||||
output = Items.surgealloy;
|
outputItem = new ItemStack(Items.surgealloy, 1);
|
||||||
craftTime = 75f;
|
craftTime = 75f;
|
||||||
size = 3;
|
size = 3;
|
||||||
|
|
||||||
@@ -459,35 +512,60 @@ public class Blocks implements ContentList{
|
|||||||
consumes.items(new ItemStack(Items.titanium, 2), new ItemStack(Items.lead, 4), new ItemStack(Items.silicon, 3), new ItemStack(Items.copper, 3));
|
consumes.items(new ItemStack(Items.titanium, 2), new ItemStack(Items.lead, 4), new ItemStack(Items.silicon, 3), new ItemStack(Items.copper, 3));
|
||||||
}};
|
}};
|
||||||
|
|
||||||
cryofluidMixer = new LiquidMixer("cryofluidmixer"){{
|
cryofluidMixer = new GenericCrafter("cryofluidmixer"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.lead, 130, Items.silicon, 80, Items.thorium, 90));
|
requirements(Category.crafting, ItemStack.with(Items.lead, 130, Items.silicon, 80, Items.thorium, 90));
|
||||||
outputLiquid = Liquids.cryofluid;
|
outputLiquid = new LiquidStack(Liquids.cryofluid, 0.3f);
|
||||||
liquidPerItem = 50f;
|
craftTime = 5f;
|
||||||
size = 2;
|
size = 2;
|
||||||
hasPower = true;
|
hasPower = true;
|
||||||
|
hasItems = true;
|
||||||
|
rotate = false;
|
||||||
|
solid = true;
|
||||||
|
outputsLiquid = true;
|
||||||
|
|
||||||
consumes.power(1f);
|
consumes.power(1f);
|
||||||
consumes.item(Items.titanium);
|
consumes.item(Items.titanium);
|
||||||
consumes.liquid(Liquids.water, 0.3f);
|
consumes.liquid(Liquids.water, 0.3f);
|
||||||
|
|
||||||
|
int liquidRegion = reg("-liquid"), topRegion = reg("-top"), bottomRegion = reg("-bottom");
|
||||||
|
|
||||||
|
drawIcons = () -> new TextureRegion[]{Core.atlas.find(name + "-bottom"), Core.atlas.find(name + "-top")};
|
||||||
|
|
||||||
|
drawer = tile -> {
|
||||||
|
LiquidModule mod = tile.entity.liquids;
|
||||||
|
|
||||||
|
int rotation = rotate ? tile.getRotation() * 90 : 0;
|
||||||
|
|
||||||
|
Draw.rect(reg(bottomRegion), tile.drawx(), tile.drawy(), rotation);
|
||||||
|
|
||||||
|
if(mod.total() > 0.001f){
|
||||||
|
Draw.color(outputLiquid.liquid.color);
|
||||||
|
Draw.alpha(mod.get(outputLiquid.liquid) / liquidCapacity);
|
||||||
|
Draw.rect(reg(liquidRegion), tile.drawx(), tile.drawy(), rotation);
|
||||||
|
Draw.color();
|
||||||
|
}
|
||||||
|
|
||||||
|
Draw.rect(reg(topRegion), tile.drawx(), tile.drawy(), rotation);
|
||||||
|
};
|
||||||
}};
|
}};
|
||||||
|
|
||||||
blastMixer = new GenericCrafter("blast-mixer"){{
|
blastMixer = new GenericCrafter("blast-mixer"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.lead, 60, Items.titanium, 40));
|
requirements(Category.crafting, ItemStack.with(Items.lead, 60, Items.titanium, 40));
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
hasPower = true;
|
hasPower = true;
|
||||||
output = Items.blastCompound;
|
outputItem = new ItemStack(Items.blastCompound, 1);
|
||||||
size = 2;
|
size = 2;
|
||||||
|
|
||||||
consumes.items(new ItemStack(Items.pyratite, 1), new ItemStack(Items.sporePod, 1));
|
consumes.items(new ItemStack(Items.pyratite, 1), new ItemStack(Items.sporePod, 1));
|
||||||
consumes.power(0.40f);
|
consumes.power(0.40f);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
pyratiteMixer = new PowerSmelter("pyratite-mixer"){{
|
pyratiteMixer = new GenericSmelter("pyratite-mixer"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 100, Items.lead, 50));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 100, Items.lead, 50));
|
||||||
flameColor = Color.CLEAR;
|
flameColor = Color.CLEAR;
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
hasPower = true;
|
hasPower = true;
|
||||||
output = Items.pyratite;
|
outputItem = new ItemStack(Items.pyratite, 1);
|
||||||
|
|
||||||
size = 2;
|
size = 2;
|
||||||
|
|
||||||
@@ -495,11 +573,10 @@ public class Blocks implements ContentList{
|
|||||||
consumes.items(new ItemStack(Items.coal, 1), new ItemStack(Items.lead, 2), new ItemStack(Items.sand, 2));
|
consumes.items(new ItemStack(Items.coal, 1), new ItemStack(Items.lead, 2), new ItemStack(Items.sand, 2));
|
||||||
}};
|
}};
|
||||||
|
|
||||||
melter = new PowerCrafter("melter"){{
|
melter = new GenericCrafter("melter"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 60, Items.lead, 70, Items.graphite, 90));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 60, Items.lead, 70, Items.graphite, 90));
|
||||||
health = 200;
|
health = 200;
|
||||||
outputLiquid = Liquids.slag;
|
outputLiquid = new LiquidStack(Liquids.slag, 2f);
|
||||||
outputLiquidAmount = 2f;
|
|
||||||
craftTime = 10f;
|
craftTime = 10f;
|
||||||
hasLiquids = hasPower = true;
|
hasLiquids = hasPower = true;
|
||||||
|
|
||||||
@@ -516,7 +593,7 @@ public class Blocks implements ContentList{
|
|||||||
Items.titanium, 2
|
Items.titanium, 2
|
||||||
);
|
);
|
||||||
hasPower = true;
|
hasPower = true;
|
||||||
filterTime = 35f;
|
craftTime = 35f;
|
||||||
spinnerLength = 1.5f;
|
spinnerLength = 1.5f;
|
||||||
spinnerRadius = 3.5f;
|
spinnerRadius = 3.5f;
|
||||||
spinnerThickness = 1.5f;
|
spinnerThickness = 1.5f;
|
||||||
@@ -529,7 +606,7 @@ public class Blocks implements ContentList{
|
|||||||
|
|
||||||
cultivator = new Cultivator("cultivator"){{
|
cultivator = new Cultivator("cultivator"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 20, Items.lead, 50, Items.silicon, 20));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 20, Items.lead, 50, Items.silicon, 20));
|
||||||
output = Items.sporePod;
|
outputItem = new ItemStack(Items.sporePod, 1);
|
||||||
craftTime = 160;
|
craftTime = 160;
|
||||||
size = 2;
|
size = 2;
|
||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
@@ -540,23 +617,41 @@ public class Blocks implements ContentList{
|
|||||||
consumes.liquid(Liquids.water, 0.15f);
|
consumes.liquid(Liquids.water, 0.15f);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
sporePress = new Compressor("spore-press"){{
|
sporePress = new GenericCrafter("spore-press"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.lead, 70, Items.silicon, 60));
|
requirements(Category.crafting, ItemStack.with(Items.lead, 70, Items.silicon, 60));
|
||||||
liquidCapacity = 60f;
|
liquidCapacity = 60f;
|
||||||
craftTime = 20f;
|
craftTime = 20f;
|
||||||
outputLiquid = Liquids.oil;
|
outputLiquid = new LiquidStack(Liquids.oil, 4f);
|
||||||
outputLiquidAmount = 4f;
|
|
||||||
size = 2;
|
size = 2;
|
||||||
health = 320;
|
health = 320;
|
||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
|
|
||||||
consumes.item(Items.sporePod, 1);
|
consumes.item(Items.sporePod, 1);
|
||||||
consumes.power(0.60f);
|
consumes.power(0.60f);
|
||||||
|
|
||||||
|
int[] frameRegions = new int[3];
|
||||||
|
for(int i = 0; i < 3; i++){
|
||||||
|
frameRegions[i] = reg("-frame" + i);
|
||||||
|
}
|
||||||
|
|
||||||
|
int liquidRegion = reg("-liquid");
|
||||||
|
int topRegion =reg("-top");
|
||||||
|
|
||||||
|
drawer = tile -> {
|
||||||
|
GenericCrafterEntity entity = tile.entity();
|
||||||
|
|
||||||
|
Draw.rect(region, tile.drawx(), tile.drawy());
|
||||||
|
Draw.rect(reg(frameRegions[(int) Mathf.absin(entity.totalProgress, 5f, 2.999f)]), tile.drawx(), tile.drawy());
|
||||||
|
Draw.color(Color.CLEAR, tile.entity.liquids.current().color, tile.entity.liquids.total() / liquidCapacity);
|
||||||
|
Draw.rect(reg(liquidRegion), tile.drawx(), tile.drawy());
|
||||||
|
Draw.color();
|
||||||
|
Draw.rect(reg(topRegion), tile.drawx(), tile.drawy());
|
||||||
|
};
|
||||||
}};
|
}};
|
||||||
|
|
||||||
pulverizer = new Pulverizer("pulverizer"){{
|
pulverizer = new GenericCrafter("pulverizer"){{
|
||||||
requirements(Category.crafting, ItemStack.with(Items.copper, 60, Items.lead, 50));
|
requirements(Category.crafting, ItemStack.with(Items.copper, 60, Items.lead, 50));
|
||||||
output = Items.sand;
|
outputItem = new ItemStack(Items.sand, 1);
|
||||||
craftEffect = Fx.pulverize;
|
craftEffect = Fx.pulverize;
|
||||||
craftTime = 40f;
|
craftTime = 40f;
|
||||||
updateEffect = Fx.pulverizeSmall;
|
updateEffect = Fx.pulverizeSmall;
|
||||||
@@ -564,6 +659,15 @@ public class Blocks implements ContentList{
|
|||||||
|
|
||||||
consumes.item(Items.scrap, 1);
|
consumes.item(Items.scrap, 1);
|
||||||
consumes.power(0.50f);
|
consumes.power(0.50f);
|
||||||
|
|
||||||
|
int rotatorRegion = reg("-rotator");
|
||||||
|
|
||||||
|
drawer = tile -> {
|
||||||
|
GenericCrafterEntity entity = tile.entity();
|
||||||
|
|
||||||
|
Draw.rect(region, tile.drawx(), tile.drawy());
|
||||||
|
Draw.rect(reg(rotatorRegion), tile.drawx(), tile.drawy(), entity.totalProgress * 2f);
|
||||||
|
};
|
||||||
}};
|
}};
|
||||||
|
|
||||||
incinerator = new Incinerator("incinerator"){{
|
incinerator = new Incinerator("incinerator"){{
|
||||||
@@ -724,17 +828,18 @@ public class Blocks implements ContentList{
|
|||||||
requirements(Category.effect, ItemStack.with(Items.lead, 200, Items.titanium, 150, Items.silicon, 150, Items.plastanium, 60));
|
requirements(Category.effect, ItemStack.with(Items.lead, 200, Items.titanium, 150, Items.silicon, 150, Items.plastanium, 60));
|
||||||
consumes.power(3.50f);
|
consumes.power(3.50f);
|
||||||
size = 2;
|
size = 2;
|
||||||
consumes.item(Items.phasefabric).optional(true).boost(true);
|
consumes.item(Items.phasefabric).optional(true);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
forceProjector = new ForceProjector("force-projector"){{
|
forceProjector = new ForceProjector("force-projector"){{
|
||||||
requirements(Category.effect, ItemStack.with(Items.lead, 200, Items.titanium, 150, Items.silicon, 250));
|
requirements(Category.effect, ItemStack.with(Items.lead, 200, Items.titanium, 150, Items.silicon, 250));
|
||||||
size = 3;
|
size = 3;
|
||||||
consumes.item(Items.phasefabric).optional(true).boost(true);
|
consumes.item(Items.phasefabric).optional(true);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
shockMine = new ShockMine("shock-mine"){{
|
shockMine = new ShockMine("shock-mine"){{
|
||||||
requirements(Category.effect, ItemStack.with(Items.lead, 50, Items.silicon, 25));
|
requirements(Category.effect, ItemStack.with(Items.lead, 50, Items.silicon, 25));
|
||||||
|
hasShadow = false;
|
||||||
health = 40;
|
health = 40;
|
||||||
damage = 11;
|
damage = 11;
|
||||||
tileDamage = 7f;
|
tileDamage = 7f;
|
||||||
@@ -919,7 +1024,7 @@ public class Blocks implements ContentList{
|
|||||||
size = 2;
|
size = 2;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
turbineGenerator = new TurbineGenerator("turbine-generator"){{
|
turbineGenerator = new BurnerGenerator("turbine-generator"){{
|
||||||
requirements(Category.power, ItemStack.with(Items.copper, 70, Items.graphite, 50, Items.lead, 80, Items.silicon, 60));
|
requirements(Category.power, ItemStack.with(Items.copper, 70, Items.graphite, 50, Items.lead, 80, Items.silicon, 60));
|
||||||
powerProduction = 6f;
|
powerProduction = 6f;
|
||||||
itemDuration = 30f;
|
itemDuration = 30f;
|
||||||
@@ -928,15 +1033,15 @@ public class Blocks implements ContentList{
|
|||||||
size = 2;
|
size = 2;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
differentialGenerator = new DifferentialGenerator("differential-generator"){{
|
differentialGenerator = new ItemLiquidGenerator(true, true, "differential-generator"){{
|
||||||
requirements(Category.power, ItemStack.with(Items.copper, 140, Items.titanium, 100, Items.lead, 200, Items.silicon, 130, Items.metaglass, 100));
|
requirements(Category.power, ItemStack.with(Items.copper, 140, Items.titanium, 100, Items.lead, 200, Items.silicon, 130, Items.metaglass, 100));
|
||||||
powerProduction = 13f;
|
powerProduction = 13f;
|
||||||
itemDuration = 50f;
|
itemDuration = 50f;
|
||||||
consumes.remove(ConsumeItemFilter.class);
|
hasLiquids = true;
|
||||||
consumes.remove(ConsumeLiquidFilter.class);
|
size = 3;
|
||||||
|
|
||||||
consumes.item(Items.pyratite);
|
consumes.item(Items.pyratite);
|
||||||
consumes.liquid(Liquids.cryofluid, 0.2f);
|
consumes.liquid(Liquids.cryofluid, 0.2f);
|
||||||
size = 3;
|
|
||||||
}};
|
}};
|
||||||
|
|
||||||
rtgGenerator = new DecayGenerator("rtg-generator"){{
|
rtgGenerator = new DecayGenerator("rtg-generator"){{
|
||||||
@@ -971,7 +1076,7 @@ public class Blocks implements ContentList{
|
|||||||
size = 4;
|
size = 4;
|
||||||
health = 900;
|
health = 900;
|
||||||
powerProduction = 80f;
|
powerProduction = 80f;
|
||||||
useTime = 40f;
|
itemDuration = 40f;
|
||||||
consumes.power(23f);
|
consumes.power(23f);
|
||||||
consumes.item(Items.blastCompound);
|
consumes.item(Items.blastCompound);
|
||||||
consumes.liquid(Liquids.cryofluid, 0.8f);
|
consumes.liquid(Liquids.cryofluid, 0.8f);
|
||||||
@@ -986,6 +1091,7 @@ public class Blocks implements ContentList{
|
|||||||
drillTime = 600;
|
drillTime = 600;
|
||||||
size = 2;
|
size = 2;
|
||||||
drawMineItem = true;
|
drawMineItem = true;
|
||||||
|
consumes.liquid(Liquids.water, 0.05f).optional(true);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
pneumaticDrill = new Drill("pneumatic-drill"){{
|
pneumaticDrill = new Drill("pneumatic-drill"){{
|
||||||
@@ -1096,7 +1202,7 @@ public class Blocks implements ContentList{
|
|||||||
}};
|
}};
|
||||||
|
|
||||||
unloader = new Unloader("unloader"){{
|
unloader = new Unloader("unloader"){{
|
||||||
requirements(Category.distribution, ItemStack.with(Items.titanium, 50, Items.silicon, 60));
|
requirements(Category.effect, ItemStack.with(Items.titanium, 50, Items.silicon, 60));
|
||||||
speed = 7f;
|
speed = 7f;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
@@ -1365,7 +1471,6 @@ public class Blocks implements ContentList{
|
|||||||
);
|
);
|
||||||
reload = 6f;
|
reload = 6f;
|
||||||
coolantMultiplier = 0.5f;
|
coolantMultiplier = 0.5f;
|
||||||
maxCoolantUsed = 1.5f;
|
|
||||||
restitution = 0.1f;
|
restitution = 0.1f;
|
||||||
ammoUseEffect = Fx.shellEjectBig;
|
ammoUseEffect = Fx.shellEjectBig;
|
||||||
range = 200f;
|
range = 200f;
|
||||||
@@ -1379,6 +1484,7 @@ public class Blocks implements ContentList{
|
|||||||
shootCone = 24f;
|
shootCone = 24f;
|
||||||
|
|
||||||
health = 155 * size * size;
|
health = 155 * size * size;
|
||||||
|
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 2f)).update(false).optional(true);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
meltdown = new LaserTurret("meltdown"){{
|
meltdown = new LaserTurret("meltdown"){{
|
||||||
|
|||||||
@@ -34,6 +34,10 @@ public class Items implements ContentList{
|
|||||||
cost = 1f;
|
cost = 1f;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
|
sand = new Item("sand", Color.valueOf("f7cba4")){{
|
||||||
|
|
||||||
|
}};
|
||||||
|
|
||||||
coal = new Item("coal", Color.valueOf("272727")){{
|
coal = new Item("coal", Color.valueOf("272727")){{
|
||||||
explosiveness = 0.4f;
|
explosiveness = 0.4f;
|
||||||
flammability = 1f;
|
flammability = 1f;
|
||||||
@@ -65,7 +69,7 @@ public class Items implements ContentList{
|
|||||||
|
|
||||||
plastanium = new Item("plastanium", Color.valueOf("cbd97f")){{
|
plastanium = new Item("plastanium", Color.valueOf("cbd97f")){{
|
||||||
type = ItemType.material;
|
type = ItemType.material;
|
||||||
flammability = 0.2f;
|
flammability = 0.1f;
|
||||||
explosiveness = 0.2f;
|
explosiveness = 0.2f;
|
||||||
cost = 1.3f;
|
cost = 1.3f;
|
||||||
}};
|
}};
|
||||||
@@ -84,10 +88,6 @@ public class Items implements ContentList{
|
|||||||
flammability = 1.05f;
|
flammability = 1.05f;
|
||||||
}};
|
}};
|
||||||
|
|
||||||
sand = new Item("sand", Color.valueOf("f7cba4")){{
|
|
||||||
|
|
||||||
}};
|
|
||||||
|
|
||||||
blastCompound = new Item("blast-compound", Color.valueOf("ff795e")){{
|
blastCompound = new Item("blast-compound", Color.valueOf("ff795e")){{
|
||||||
flammability = 0.4f;
|
flammability = 0.4f;
|
||||||
explosiveness = 1.2f;
|
explosiveness = 1.2f;
|
||||||
|
|||||||
@@ -35,6 +35,7 @@ public class Mechs implements ContentList{
|
|||||||
mass = 1.2f;
|
mass = 1.2f;
|
||||||
speed = 0.5f;
|
speed = 0.5f;
|
||||||
boostSpeed = 0.85f;
|
boostSpeed = 0.85f;
|
||||||
|
buildPower = 1.2f;
|
||||||
engineColor = Color.valueOf("ffd37f");
|
engineColor = Color.valueOf("ffd37f");
|
||||||
health = 300f;
|
health = 300f;
|
||||||
|
|
||||||
@@ -47,6 +48,11 @@ public class Mechs implements ContentList{
|
|||||||
}};
|
}};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateAlt(Player player){
|
||||||
|
player.healBy(Time.delta() * 0.4f);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean alwaysUnlocked(){
|
public boolean alwaysUnlocked(){
|
||||||
return true;
|
return true;
|
||||||
@@ -63,6 +69,7 @@ public class Mechs implements ContentList{
|
|||||||
itemCapacity = 15;
|
itemCapacity = 15;
|
||||||
mass = 0.9f;
|
mass = 0.9f;
|
||||||
health = 250f;
|
health = 250f;
|
||||||
|
buildPower = 0.9f;
|
||||||
weaponOffsetX = -1;
|
weaponOffsetX = -1;
|
||||||
weaponOffsetY = -1;
|
weaponOffsetY = -1;
|
||||||
engineColor = Color.valueOf("d3ddff");
|
engineColor = Color.valueOf("d3ddff");
|
||||||
@@ -110,6 +117,7 @@ public class Mechs implements ContentList{
|
|||||||
boostSpeed = 0.8f;
|
boostSpeed = 0.8f;
|
||||||
canHeal = true;
|
canHeal = true;
|
||||||
health = 200f;
|
health = 200f;
|
||||||
|
buildPower = 1.6f;
|
||||||
engineColor = Pal.heal;
|
engineColor = Pal.heal;
|
||||||
|
|
||||||
weapon = new Weapon("heal-blaster"){{
|
weapon = new Weapon("heal-blaster"){{
|
||||||
@@ -161,6 +169,7 @@ public class Mechs implements ContentList{
|
|||||||
weaponOffsetY = 0;
|
weaponOffsetY = 0;
|
||||||
engineColor = Color.valueOf("feb380");
|
engineColor = Color.valueOf("feb380");
|
||||||
health = 300f;
|
health = 300f;
|
||||||
|
buildPower = 1.5f;
|
||||||
weapon = new Weapon("swarmer"){{
|
weapon = new Weapon("swarmer"){{
|
||||||
length = 1.5f;
|
length = 1.5f;
|
||||||
recoil = 4f;
|
recoil = 4f;
|
||||||
@@ -227,6 +236,7 @@ public class Mechs implements ContentList{
|
|||||||
weaponOffsetY = -1;
|
weaponOffsetY = -1;
|
||||||
engineColor = Pal.lightTrail;
|
engineColor = Pal.lightTrail;
|
||||||
cellTrnsY = 1f;
|
cellTrnsY = 1f;
|
||||||
|
buildPower = 1.1f;
|
||||||
weapon = new Weapon("blaster"){{
|
weapon = new Weapon("blaster"){{
|
||||||
length = 1.5f;
|
length = 1.5f;
|
||||||
reload = 20f;
|
reload = 20f;
|
||||||
@@ -315,6 +325,7 @@ public class Mechs implements ContentList{
|
|||||||
itemCapacity = 30;
|
itemCapacity = 30;
|
||||||
engineColor = Color.valueOf("84f491");
|
engineColor = Color.valueOf("84f491");
|
||||||
cellTrnsY = 1f;
|
cellTrnsY = 1f;
|
||||||
|
buildPower = 2f;
|
||||||
weapon = new Weapon("bomber"){{
|
weapon = new Weapon("bomber"){{
|
||||||
length = 0f;
|
length = 0f;
|
||||||
width = 2f;
|
width = 2f;
|
||||||
@@ -346,6 +357,7 @@ public class Mechs implements ContentList{
|
|||||||
itemCapacity = 60;
|
itemCapacity = 60;
|
||||||
engineColor = Color.valueOf("feb380");
|
engineColor = Color.valueOf("feb380");
|
||||||
cellTrnsY = 1f;
|
cellTrnsY = 1f;
|
||||||
|
buildPower = 1.2f;
|
||||||
|
|
||||||
weapon = new Weapon("bomber"){{
|
weapon = new Weapon("bomber"){{
|
||||||
length = 1.5f;
|
length = 1.5f;
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ import io.anuke.arc.graphics.GL20;
|
|||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
import io.anuke.arc.graphics.g2d.TextureAtlas;
|
import io.anuke.arc.graphics.g2d.TextureAtlas;
|
||||||
import io.anuke.arc.input.KeyCode;
|
import io.anuke.arc.input.KeyCode;
|
||||||
|
import io.anuke.arc.scene.ui.TextField;
|
||||||
import io.anuke.arc.util.BufferUtils;
|
import io.anuke.arc.util.BufferUtils;
|
||||||
import io.anuke.arc.util.Interval;
|
import io.anuke.arc.util.Interval;
|
||||||
import io.anuke.arc.util.Strings;
|
import io.anuke.arc.util.Strings;
|
||||||
@@ -301,10 +302,18 @@ public class Control implements ApplicationListener{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!mobile && Core.input.keyTap(Binding.screenshot) && !(scene.getKeyboardFocus() instanceof TextField) && !ui.chatfrag.chatOpen()){
|
||||||
|
renderer.takeMapScreenshot();
|
||||||
|
}
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
if(!state.isPaused()){
|
if(!state.isPaused()){
|
||||||
Time.update();
|
Time.update();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!scene.hasDialog() && Core.input.keyTap(KeyCode.BACK)){
|
||||||
|
Platform.instance.hide();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -69,6 +69,9 @@ public abstract class Platform {
|
|||||||
*/
|
*/
|
||||||
public void showFileChooser(String text, String content, Consumer<FileHandle> cons, boolean open, String filetype){}
|
public void showFileChooser(String text, String content, Consumer<FileHandle> cons, boolean open, String filetype){}
|
||||||
|
|
||||||
|
/**Hide the app. Android only.*/
|
||||||
|
public void hide(){}
|
||||||
|
|
||||||
/**Forces the app into landscape mode. Currently Android only.*/
|
/**Forces the app into landscape mode. Currently Android only.*/
|
||||||
public void beginForceLandscape(){}
|
public void beginForceLandscape(){}
|
||||||
|
|
||||||
|
|||||||
@@ -2,10 +2,13 @@ package io.anuke.mindustry.core;
|
|||||||
|
|
||||||
import io.anuke.arc.ApplicationListener;
|
import io.anuke.arc.ApplicationListener;
|
||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
|
import io.anuke.arc.files.FileHandle;
|
||||||
import io.anuke.arc.function.Consumer;
|
import io.anuke.arc.function.Consumer;
|
||||||
import io.anuke.arc.function.Predicate;
|
import io.anuke.arc.function.Predicate;
|
||||||
import io.anuke.arc.graphics.Camera;
|
import io.anuke.arc.graphics.Camera;
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.Color;
|
||||||
|
import io.anuke.arc.graphics.Pixmap;
|
||||||
|
import io.anuke.arc.graphics.PixmapIO;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
import io.anuke.arc.graphics.g2d.Lines;
|
import io.anuke.arc.graphics.g2d.Lines;
|
||||||
import io.anuke.arc.graphics.g2d.SpriteBatch;
|
import io.anuke.arc.graphics.g2d.SpriteBatch;
|
||||||
@@ -13,6 +16,8 @@ import io.anuke.arc.graphics.glutils.FrameBuffer;
|
|||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.math.geom.Rectangle;
|
import io.anuke.arc.math.geom.Rectangle;
|
||||||
import io.anuke.arc.math.geom.Vector2;
|
import io.anuke.arc.math.geom.Vector2;
|
||||||
|
import io.anuke.arc.util.BufferUtils;
|
||||||
|
import io.anuke.arc.util.ScreenUtils;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.arc.util.Tmp;
|
import io.anuke.arc.util.Tmp;
|
||||||
import io.anuke.arc.util.pooling.Pools;
|
import io.anuke.arc.util.pooling.Pools;
|
||||||
@@ -296,10 +301,6 @@ public class Renderer implements ApplicationListener{
|
|||||||
EntityDraw.drawWith(group, toDraw, drawer);
|
EntityDraw.drawWith(group, toDraw, drawer);
|
||||||
}
|
}
|
||||||
|
|
||||||
public float cameraScale(){
|
|
||||||
return camerascale;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void scaleCamera(float amount){
|
public void scaleCamera(float amount){
|
||||||
targetscale += amount;
|
targetscale += amount;
|
||||||
clampScale();
|
clampScale();
|
||||||
@@ -310,4 +311,47 @@ public class Renderer implements ApplicationListener{
|
|||||||
targetscale = Mathf.clamp(targetscale, s * 1.5f, Math.round(s * 6));
|
targetscale = Mathf.clamp(targetscale, s * 1.5f, Math.round(s * 6));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void takeMapScreenshot(){
|
||||||
|
drawGroundShadows();
|
||||||
|
|
||||||
|
int w = world.width()*tilesize, h = world.height()*tilesize;
|
||||||
|
|
||||||
|
boolean isWater = settings.getBool("animatedwater");
|
||||||
|
settings.put("animatedwater", false);
|
||||||
|
|
||||||
|
FrameBuffer buffer = new FrameBuffer(w, h);
|
||||||
|
|
||||||
|
float vpW = camera.width, vpH = camera.height, px = camera.position.x, py = camera.position.y;
|
||||||
|
disableUI = true;
|
||||||
|
camera.width = w;
|
||||||
|
camera.height = h;
|
||||||
|
camera.position.x = w/2f + tilesize/2f;
|
||||||
|
camera.position.y = h/2f + tilesize/2f;
|
||||||
|
Draw.flush();
|
||||||
|
buffer.begin();
|
||||||
|
draw();
|
||||||
|
Draw.flush();
|
||||||
|
buffer.end();
|
||||||
|
disableUI = false;
|
||||||
|
camera.width = vpW;
|
||||||
|
camera.height = vpH;
|
||||||
|
camera.position.set(px, py);
|
||||||
|
buffer.begin();
|
||||||
|
byte[] lines = ScreenUtils.getFrameBufferPixels(0, 0, w, h, true);
|
||||||
|
for(int i = 0; i < lines.length; i+= 4){
|
||||||
|
lines[i + 3] = (byte)255;
|
||||||
|
}
|
||||||
|
buffer.end();
|
||||||
|
Pixmap fullPixmap = new Pixmap(w, h, Pixmap.Format.RGBA8888);
|
||||||
|
BufferUtils.copy(lines, 0, fullPixmap.getPixels(), lines.length);
|
||||||
|
FileHandle file = screenshotDirectory.child("screenshot-" + Time.millis() + ".png");
|
||||||
|
PixmapIO.writePNG(file, fullPixmap);
|
||||||
|
fullPixmap.dispose();
|
||||||
|
ui.showInfoFade(Core.bundle.format("screenshot", file.toString()));
|
||||||
|
|
||||||
|
buffer.dispose();
|
||||||
|
|
||||||
|
settings.put("animatedwater", isWater);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -287,11 +287,11 @@ public class UI implements ApplicationListener{
|
|||||||
|
|
||||||
public String formatAmount(int number){
|
public String formatAmount(int number){
|
||||||
if(number >= 1000000){
|
if(number >= 1000000){
|
||||||
return Strings.toFixed(number / 1000000f, 1) + "[gray]mil[]";
|
return Strings.fixed(number / 1000000f, 1) + "[gray]mil[]";
|
||||||
}else if(number >= 10000){
|
}else if(number >= 10000){
|
||||||
return number / 1000 + "[gray]k[]";
|
return number / 1000 + "[gray]k[]";
|
||||||
}else if(number >= 1000){
|
}else if(number >= 1000){
|
||||||
return Strings.toFixed(number / 1000f, 1) + "[gray]k[]";
|
return Strings.fixed(number / 1000f, 1) + "[gray]k[]";
|
||||||
}else{
|
}else{
|
||||||
return number + "";
|
return number + "";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -184,7 +184,7 @@ public class WaveInfoDialog extends FloatingDialog{
|
|||||||
}).width(80f);
|
}).width(80f);
|
||||||
|
|
||||||
a.add(" + ");
|
a.add(" + ");
|
||||||
a.addField(Strings.toFixed(Math.max((Mathf.isZero(group.unitScaling) ? 0 : 1f/group.unitScaling), 0), 2), TextFieldFilter.floatsOnly, text -> {
|
a.addField(Strings.fixed(Math.max((Mathf.isZero(group.unitScaling) ? 0 : 1f/group.unitScaling), 0), 2), TextFieldFilter.floatsOnly, text -> {
|
||||||
if(Strings.canParsePositiveFloat(text)){
|
if(Strings.canParsePositiveFloat(text)){
|
||||||
group.unitScaling = 1f / Strings.parseFloat(text);
|
group.unitScaling = 1f / Strings.parseFloat(text);
|
||||||
updateWaves();
|
updateWaves();
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ import io.anuke.arc.function.Predicate;
|
|||||||
import io.anuke.arc.graphics.Camera;
|
import io.anuke.arc.graphics.Camera;
|
||||||
import io.anuke.arc.math.geom.Rectangle;
|
import io.anuke.arc.math.geom.Rectangle;
|
||||||
import io.anuke.mindustry.entities.traits.DrawTrait;
|
import io.anuke.mindustry.entities.traits.DrawTrait;
|
||||||
|
import io.anuke.mindustry.entities.traits.Entity;
|
||||||
|
|
||||||
public class EntityDraw{
|
public class EntityDraw{
|
||||||
private static final Rectangle viewport = new Rectangle();
|
private static final Rectangle viewport = new Rectangle();
|
||||||
@@ -42,15 +43,12 @@ public class EntityDraw{
|
|||||||
viewport.set(cam.position.x - cam.width / 2, cam.position.y - cam.height / 2, cam.width, cam.height);
|
viewport.set(cam.position.x - cam.width / 2, cam.position.y - cam.height / 2, cam.width, cam.height);
|
||||||
}
|
}
|
||||||
|
|
||||||
group.forEach(e -> {
|
for(Entity e : group.all()){
|
||||||
if(!(e instanceof DrawTrait)) return;
|
if(!(e instanceof DrawTrait) || !toDraw.test((T)e) || !e.isAdded()) continue;
|
||||||
T t = (T) e;
|
|
||||||
|
|
||||||
if(!toDraw.test(t) || !e.isAdded()) return;
|
|
||||||
|
|
||||||
if(!clip || rect.setSize(((DrawTrait) e).drawSize()).setCenter(e.getX(), e.getY()).overlaps(viewport)){
|
if(!clip || rect.setSize(((DrawTrait) e).drawSize()).setCenter(e.getX(), e.getY()).overlaps(viewport)){
|
||||||
cons.accept(t);
|
cons.accept((T)e);
|
||||||
}
|
}
|
||||||
});
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -215,7 +215,7 @@ public abstract class GroundUnit extends BaseUnit{
|
|||||||
|
|
||||||
velocity.add(vec.trns(angleTo(targetTile), type.speed*Time.delta()));
|
velocity.add(vec.trns(angleTo(targetTile), type.speed*Time.delta()));
|
||||||
if(Units.invalidateTarget(target, this)){
|
if(Units.invalidateTarget(target, this)){
|
||||||
rotation = Mathf.slerpDelta(rotation, angle, type.rotatespeed);
|
rotation = Mathf.slerpDelta(rotation, baseRotation, type.rotatespeed);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -240,6 +240,6 @@ public abstract class GroundUnit extends BaseUnit{
|
|||||||
float angle = angleTo(targetTile);
|
float angle = angleTo(targetTile);
|
||||||
|
|
||||||
velocity.add(vec.trns(angleTo(targetTile), type.speed*Time.delta()));
|
velocity.add(vec.trns(angleTo(targetTile), type.speed*Time.delta()));
|
||||||
rotation = Mathf.slerpDelta(rotation, angle, type.rotatespeed);
|
rotation = Mathf.slerpDelta(rotation, baseRotation, type.rotatespeed);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,17 +5,17 @@ import io.anuke.annotations.Annotations.Remote;
|
|||||||
import io.anuke.arc.Events;
|
import io.anuke.arc.Events;
|
||||||
import io.anuke.arc.collection.Array;
|
import io.anuke.arc.collection.Array;
|
||||||
import io.anuke.arc.collection.ObjectSet;
|
import io.anuke.arc.collection.ObjectSet;
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.mindustry.entities.EntityGroup;
|
|
||||||
import io.anuke.mindustry.entities.impl.BaseEntity;
|
|
||||||
import io.anuke.mindustry.entities.traits.HealthTrait;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.math.geom.Point2;
|
import io.anuke.arc.math.geom.Point2;
|
||||||
import io.anuke.arc.math.geom.Vector2;
|
import io.anuke.arc.math.geom.Vector2;
|
||||||
import io.anuke.arc.util.Interval;
|
import io.anuke.arc.util.Interval;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.content.Fx;
|
import io.anuke.mindustry.content.Fx;
|
||||||
|
import io.anuke.mindustry.entities.Effects;
|
||||||
|
import io.anuke.mindustry.entities.EntityGroup;
|
||||||
import io.anuke.mindustry.entities.bullet.Bullet;
|
import io.anuke.mindustry.entities.bullet.Bullet;
|
||||||
|
import io.anuke.mindustry.entities.impl.BaseEntity;
|
||||||
|
import io.anuke.mindustry.entities.traits.HealthTrait;
|
||||||
import io.anuke.mindustry.entities.traits.TargetTrait;
|
import io.anuke.mindustry.entities.traits.TargetTrait;
|
||||||
import io.anuke.mindustry.game.EventType.BlockDestroyEvent;
|
import io.anuke.mindustry.game.EventType.BlockDestroyEvent;
|
||||||
import io.anuke.mindustry.game.Team;
|
import io.anuke.mindustry.game.Team;
|
||||||
@@ -24,7 +24,6 @@ import io.anuke.mindustry.world.Block;
|
|||||||
import io.anuke.mindustry.world.Edges;
|
import io.anuke.mindustry.world.Edges;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.blocks.defense.Wall;
|
import io.anuke.mindustry.world.blocks.defense.Wall;
|
||||||
import io.anuke.mindustry.world.consumers.Consume;
|
|
||||||
import io.anuke.mindustry.world.modules.ConsumeModule;
|
import io.anuke.mindustry.world.modules.ConsumeModule;
|
||||||
import io.anuke.mindustry.world.modules.ItemModule;
|
import io.anuke.mindustry.world.modules.ItemModule;
|
||||||
import io.anuke.mindustry.world.modules.LiquidModule;
|
import io.anuke.mindustry.world.modules.LiquidModule;
|
||||||
@@ -44,6 +43,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
public static int sleepingEntities = 0;
|
public static int sleepingEntities = 0;
|
||||||
|
|
||||||
public Tile tile;
|
public Tile tile;
|
||||||
|
public Block block;
|
||||||
public Interval timer;
|
public Interval timer;
|
||||||
public float health;
|
public float health;
|
||||||
public float timeScale = 1f, timeScaleDuration;
|
public float timeScale = 1f, timeScaleDuration;
|
||||||
@@ -81,10 +81,10 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
this.tile = tile;
|
this.tile = tile;
|
||||||
x = tile.drawx();
|
x = tile.drawx();
|
||||||
y = tile.drawy();
|
y = tile.drawy();
|
||||||
|
block = tile.block();
|
||||||
|
|
||||||
health = tile.block().health;
|
health = block.health;
|
||||||
|
timer = new Interval(block.timers);
|
||||||
timer = new Interval(tile.block().timers);
|
|
||||||
|
|
||||||
if(shouldAdd){
|
if(shouldAdd){
|
||||||
add();
|
add();
|
||||||
@@ -139,7 +139,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void collision(Bullet other){
|
public void collision(Bullet other){
|
||||||
tile.block().handleBulletHit(this, other);
|
block.handleBulletHit(this, other);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void kill(){
|
public void kill(){
|
||||||
@@ -151,7 +151,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
|
|
||||||
float preHealth = health;
|
float preHealth = health;
|
||||||
|
|
||||||
Call.onTileDamage(tile, health - tile.block().handleDamage(tile, damage));
|
Call.onTileDamage(tile, health - block.handleDamage(tile, damage));
|
||||||
|
|
||||||
if(health <= 0){
|
if(health <= 0){
|
||||||
Call.onTileDestroyed(tile);
|
Call.onTileDestroyed(tile);
|
||||||
@@ -170,14 +170,10 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
return tile;
|
return tile;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean consumed(Class<? extends Consume> type){
|
|
||||||
return tile.block().consumes.get(type).valid(tile.block(), this);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void removeFromProximity(){
|
public void removeFromProximity(){
|
||||||
tile.block().onProximityRemoved(tile);
|
block.onProximityRemoved(tile);
|
||||||
|
|
||||||
Point2[] nearby = Edges.getEdges(tile.block().size);
|
Point2[] nearby = Edges.getEdges(block.size);
|
||||||
for(Point2 point : nearby){
|
for(Point2 point : nearby){
|
||||||
Tile other = world.tile(tile.x + point.x, tile.y + point.y);
|
Tile other = world.tile(tile.x + point.x, tile.y + point.y);
|
||||||
//remove this tile from all nearby tile's proximities
|
//remove this tile from all nearby tile's proximities
|
||||||
@@ -195,7 +191,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
tmpTiles.clear();
|
tmpTiles.clear();
|
||||||
proximity.clear();
|
proximity.clear();
|
||||||
|
|
||||||
Point2[] nearby = Edges.getEdges(tile.block().size);
|
Point2[] nearby = Edges.getEdges(block.size);
|
||||||
for(Point2 point : nearby){
|
for(Point2 point : nearby){
|
||||||
Tile other = world.tile(tile.x + point.x, tile.y + point.y);
|
Tile other = world.tile(tile.x + point.x, tile.y + point.y);
|
||||||
|
|
||||||
@@ -218,8 +214,8 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
proximity.add(tile);
|
proximity.add(tile);
|
||||||
}
|
}
|
||||||
|
|
||||||
tile.block().onProximityAdded(tile);
|
block.onProximityAdded(tile);
|
||||||
tile.block().onProximityUpdate(tile);
|
block.onProximityUpdate(tile);
|
||||||
}
|
}
|
||||||
|
|
||||||
public Array<Tile> proximity(){
|
public Array<Tile> proximity(){
|
||||||
@@ -238,7 +234,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float maxHealth(){
|
public float maxHealth(){
|
||||||
return tile.block().health;
|
return block.health;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -250,7 +246,6 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
public void onDeath(){
|
public void onDeath(){
|
||||||
if(!dead){
|
if(!dead){
|
||||||
dead = true;
|
dead = true;
|
||||||
Block block = tile.block();
|
|
||||||
|
|
||||||
Events.fire(new BlockDestroyEvent(tile));
|
Events.fire(new BlockDestroyEvent(tile));
|
||||||
block.onDestroyed(tile);
|
block.onDestroyed(tile);
|
||||||
@@ -273,22 +268,22 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
|
|||||||
@Override
|
@Override
|
||||||
public void update(){
|
public void update(){
|
||||||
//TODO better smoke effect, this one is awful
|
//TODO better smoke effect, this one is awful
|
||||||
if(health != 0 && health < tile.block().health && !(tile.block() instanceof Wall) &&
|
if(health != 0 && health < block.health && !(block instanceof Wall) &&
|
||||||
Mathf.chance(0.009f * Time.delta() * (1f - health / tile.block().health))){
|
Mathf.chance(0.009f * Time.delta() * (1f - health / block.health))){
|
||||||
Effects.effect(Fx.smoke, x + Mathf.range(4), y + Mathf.range(4));
|
Effects.effect(Fx.smoke, x + Mathf.range(4), y + Mathf.range(4));
|
||||||
}
|
}
|
||||||
|
|
||||||
timeScaleDuration -= Time.delta();
|
timeScaleDuration -= Time.delta();
|
||||||
if(timeScaleDuration <= 0f || !tile.block().canOverdrive){
|
if(timeScaleDuration <= 0f || !block.canOverdrive){
|
||||||
timeScale = 1f;
|
timeScale = 1f;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(health <= 0){
|
if(health <= 0){
|
||||||
onDeath();
|
onDeath();
|
||||||
}
|
}
|
||||||
Block previous = tile.block();
|
Block previous = block;
|
||||||
tile.block().update(tile);
|
block.update(tile);
|
||||||
if(tile.block() == previous && cons != null){
|
if(block == previous && cons != null){
|
||||||
cons.update();
|
cons.update();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,7 +7,6 @@ import io.anuke.arc.graphics.g2d.Draw;
|
|||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.math.geom.Geometry;
|
import io.anuke.arc.math.geom.Geometry;
|
||||||
import io.anuke.arc.math.geom.Rectangle;
|
|
||||||
import io.anuke.arc.math.geom.Vector2;
|
import io.anuke.arc.math.geom.Vector2;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.arc.util.Tmp;
|
import io.anuke.arc.util.Tmp;
|
||||||
@@ -15,7 +14,6 @@ import io.anuke.mindustry.content.Blocks;
|
|||||||
import io.anuke.mindustry.content.Fx;
|
import io.anuke.mindustry.content.Fx;
|
||||||
import io.anuke.mindustry.entities.Damage;
|
import io.anuke.mindustry.entities.Damage;
|
||||||
import io.anuke.mindustry.entities.Effects;
|
import io.anuke.mindustry.entities.Effects;
|
||||||
import io.anuke.mindustry.entities.Units;
|
|
||||||
import io.anuke.mindustry.entities.effect.ScorchDecal;
|
import io.anuke.mindustry.entities.effect.ScorchDecal;
|
||||||
import io.anuke.mindustry.entities.impl.DestructibleEntity;
|
import io.anuke.mindustry.entities.impl.DestructibleEntity;
|
||||||
import io.anuke.mindustry.entities.traits.*;
|
import io.anuke.mindustry.entities.traits.*;
|
||||||
@@ -49,9 +47,11 @@ public abstract class Unit extends DestructibleEntity implements SaveTrait, Targ
|
|||||||
public static final float maxAbsVelocity = 127f / velocityPercision;
|
public static final float maxAbsVelocity = 127f / velocityPercision;
|
||||||
public static final int noSpawner = Pos.get(-1, 1);
|
public static final int noSpawner = Pos.get(-1, 1);
|
||||||
|
|
||||||
private static final Rectangle queryRect = new Rectangle();
|
|
||||||
private static final Vector2 moveVector = new Vector2();
|
private static final Vector2 moveVector = new Vector2();
|
||||||
|
|
||||||
|
private int lastWeightTile = Pos.invalid, lastWeightDelta;
|
||||||
|
private boolean wasFlying = false;
|
||||||
|
|
||||||
public float rotation;
|
public float rotation;
|
||||||
|
|
||||||
protected final Interpolator interpolator = new Interpolator();
|
protected final Interpolator interpolator = new Interpolator();
|
||||||
@@ -140,6 +140,15 @@ public abstract class Unit extends DestructibleEntity implements SaveTrait, Targ
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void removed(){
|
||||||
|
Tile tile = world.tile(lastWeightTile);
|
||||||
|
|
||||||
|
if(tile != null){
|
||||||
|
tile.weight -= Math.max(lastWeightDelta, tile.weight);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid(){
|
public boolean isValid(){
|
||||||
return !isDead() && isAdded();
|
return !isDead() && isAdded();
|
||||||
@@ -190,8 +199,8 @@ public abstract class Unit extends DestructibleEntity implements SaveTrait, Targ
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected void clampPosition(){
|
protected void clampPosition(){
|
||||||
x = Mathf.clamp(x, tilesize, world.width() * tilesize - tilesize);
|
x = Mathf.clamp(x, 0, world.width() * tilesize - tilesize);
|
||||||
y = Mathf.clamp(y, tilesize, world.height() * tilesize - tilesize);
|
y = Mathf.clamp(y, 0, world.height() * tilesize - tilesize);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void kill(){
|
public void kill(){
|
||||||
@@ -219,17 +228,56 @@ public abstract class Unit extends DestructibleEntity implements SaveTrait, Targ
|
|||||||
return status.hasEffect(effect);
|
return status.hasEffect(effect);
|
||||||
}
|
}
|
||||||
|
|
||||||
//TODO optimize
|
|
||||||
public void avoidOthers(float scaling){
|
public void avoidOthers(float scaling){
|
||||||
hitbox(queryRect);
|
boolean flying = isFlying();
|
||||||
queryRect.setSize(queryRect.getWidth() * scaling);
|
|
||||||
|
|
||||||
Units.getNearby(queryRect, t -> {
|
if(lastWeightTile != Pos.invalid){
|
||||||
if(t == this || t.isFlying() != isFlying()) return;
|
Tile tile = world.tile(lastWeightTile);
|
||||||
float dst = dst(t);
|
|
||||||
moveVector.set(x, y).sub(t.getX(), t.getY()).setLength(1f * (1f - (dst / queryRect.getWidth())));
|
if(tile != null){
|
||||||
applyImpulse(moveVector.x, moveVector.y);
|
int dec = Math.min(lastWeightDelta, wasFlying ? tile.airWeight : tile.weight);
|
||||||
});
|
if(!wasFlying){
|
||||||
|
tile.weight -= dec;
|
||||||
|
}else{
|
||||||
|
tile.airWeight -= dec;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
final int rad = 2;
|
||||||
|
|
||||||
|
moveVector.setZero();
|
||||||
|
for(int cx = -rad; cx <= rad; cx++){
|
||||||
|
for(int cy = -rad; cy <= rad; cy++){
|
||||||
|
Tile tile = world.tileWorld(x + cx*tilesize, y + cy*tilesize);
|
||||||
|
if(tile == null) continue;
|
||||||
|
int weight = flying ? tile.airWeight : tile.weight;
|
||||||
|
float scl = (rad - Mathf.dst(tile.worldx(), tile.worldy(), x, y)/(8f * 1.2f * Mathf.sqrt2)) * 0.1f;
|
||||||
|
|
||||||
|
moveVector.add(Mathf.sign(x - tile.worldx()) * scaling * weight * scl, Mathf.sign(y - tile.worldy()) * scaling * weight * scl);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
moveVector.limit(flying ? 0.1f : 0.2f);
|
||||||
|
|
||||||
|
velocity.add(moveVector.x / mass() * Time.delta(), moveVector.y / mass() * Time.delta());
|
||||||
|
|
||||||
|
Tile tile = world.tileWorld(x, y);
|
||||||
|
|
||||||
|
if(tile != null){
|
||||||
|
int tw = flying ? tile.airWeight : tile.weight;
|
||||||
|
lastWeightDelta = Math.min((int)(mass()), 127 - tw);
|
||||||
|
lastWeightTile = tile.pos();
|
||||||
|
if(!flying){
|
||||||
|
tile.weight += lastWeightDelta;
|
||||||
|
}else{
|
||||||
|
tile.airWeight += lastWeightDelta;
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
lastWeightTile = Pos.invalid;
|
||||||
|
}
|
||||||
|
wasFlying = flying;
|
||||||
}
|
}
|
||||||
|
|
||||||
public TileEntity getClosestCore(){
|
public TileEntity getClosestCore(){
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ public class Drone extends FlyingUnit implements BuilderTrait{
|
|||||||
|
|
||||||
if(core == null) return;
|
if(core == null) return;
|
||||||
|
|
||||||
if((entity.progress() < 1f || entity.progress() > 0f) && entity.tile.block() instanceof BuildBlock){ //building is valid
|
if((entity.progress() < 1f || entity.progress() > 0f) && entity.block instanceof BuildBlock){ //building is valid
|
||||||
if(!isBuilding() && dst(target) < placeDistance * 0.9f){ //within distance, begin placing
|
if(!isBuilding() && dst(target) < placeDistance * 0.9f){ //within distance, begin placing
|
||||||
if(isBreaking){
|
if(isBreaking){
|
||||||
getPlaceQueue().addLast(new BuildRequest(entity.tile.x, entity.tile.y));
|
getPlaceQueue().addLast(new BuildRequest(entity.tile.x, entity.tile.y));
|
||||||
@@ -127,7 +127,7 @@ public class Drone extends FlyingUnit implements BuilderTrait{
|
|||||||
}
|
}
|
||||||
|
|
||||||
//core full
|
//core full
|
||||||
if(targetItem != null && entity.tile.block().acceptStack(targetItem, 1, entity.tile, Drone.this) == 0){
|
if(targetItem != null && entity.block.acceptStack(targetItem, 1, entity.tile, Drone.this) == 0){
|
||||||
setState(repair);
|
setState(repair);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ public class SpawnGroup implements Serializable{
|
|||||||
}
|
}
|
||||||
float scaling = this.unitScaling;
|
float scaling = this.unitScaling;
|
||||||
|
|
||||||
return Math.min(unitAmount - 1 + Math.max((int) (((wave - begin) / spacing) / scaling), 1), max);
|
return Math.min(unitAmount - 1 + Math.max((int) (((wave - begin + 1) / spacing) / scaling), 1), max);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ public class BlockRenderer{
|
|||||||
for(int x = 0; x < world.width(); x++){
|
for(int x = 0; x < world.width(); x++){
|
||||||
for(int y = 0; y < world.height(); y++){
|
for(int y = 0; y < world.height(); y++){
|
||||||
Tile tile = world.rawTile(x, y);
|
Tile tile = world.rawTile(x, y);
|
||||||
if(tile.block() != Blocks.air){
|
if(tile.block().hasShadow){
|
||||||
Fill.rect(tile.x + 0.5f, tile.y + 0.5f, 1, 1);
|
Fill.rect(tile.x + 0.5f, tile.y + 0.5f, 1, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -125,7 +125,11 @@ public class BlockRenderer{
|
|||||||
Draw.proj().setOrtho(0, 0, shadows.getWidth(), shadows.getHeight());
|
Draw.proj().setOrtho(0, 0, shadows.getWidth(), shadows.getHeight());
|
||||||
|
|
||||||
for(Tile tile : shadowEvents){
|
for(Tile tile : shadowEvents){
|
||||||
Draw.color(tile.block() == Blocks.air ? Color.WHITE : shadowColor);
|
//clear it first
|
||||||
|
Draw.color(Color.WHITE);
|
||||||
|
Fill.rect(tile.x + 0.5f, tile.y + 0.5f, 1, 1);
|
||||||
|
//then draw the shadow
|
||||||
|
Draw.color(!tile.block().hasShadow ? Color.WHITE : shadowColor);
|
||||||
Fill.rect(tile.x + 0.5f, tile.y + 0.5f, 1, 1);
|
Fill.rect(tile.x + 0.5f, tile.y + 0.5f, 1, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -186,7 +190,6 @@ public class BlockRenderer{
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(block.expanded || !expanded){
|
if(block.expanded || !expanded){
|
||||||
addRequest(tile, Layer.shadow);
|
|
||||||
|
|
||||||
if(block.layer != null && block.isLayer(tile)){
|
if(block.layer != null && block.isLayer(tile)){
|
||||||
addRequest(tile, block.layer);
|
addRequest(tile, block.layer);
|
||||||
@@ -227,9 +230,7 @@ public class BlockRenderer{
|
|||||||
BlockRequest req = requests.get(iterateidx);
|
BlockRequest req = requests.get(iterateidx);
|
||||||
Block block = req.tile.block();
|
Block block = req.tile.block();
|
||||||
|
|
||||||
if(req.layer == Layer.shadow){
|
if(req.layer == Layer.block){
|
||||||
block.drawShadow(req.tile);
|
|
||||||
}else if(req.layer == Layer.block){
|
|
||||||
block.draw(req.tile);
|
block.draw(req.tile);
|
||||||
if(block.synthetic() && req.tile.getTeam() != player.getTeam()){
|
if(block.synthetic() && req.tile.getTeam() != player.getTeam()){
|
||||||
block.drawTeam(req.tile);
|
block.drawTeam(req.tile);
|
||||||
|
|||||||
@@ -1,8 +1,6 @@
|
|||||||
package io.anuke.mindustry.graphics;
|
package io.anuke.mindustry.graphics;
|
||||||
|
|
||||||
public enum Layer{
|
public enum Layer{
|
||||||
/**Drawn under everything.*/
|
|
||||||
shadow,
|
|
||||||
/**Base block layer.*/
|
/**Base block layer.*/
|
||||||
block,
|
block,
|
||||||
/**for placement*/
|
/**for placement*/
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import io.anuke.arc.math.geom.Rectangle;
|
|||||||
import io.anuke.arc.math.geom.Vector2;
|
import io.anuke.arc.math.geom.Vector2;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.arc.util.Tmp;
|
import io.anuke.arc.util.Tmp;
|
||||||
|
import io.anuke.mindustry.Vars;
|
||||||
import io.anuke.mindustry.content.Blocks;
|
import io.anuke.mindustry.content.Blocks;
|
||||||
import io.anuke.mindustry.entities.Units;
|
import io.anuke.mindustry.entities.Units;
|
||||||
import io.anuke.mindustry.entities.type.Player;
|
import io.anuke.mindustry.entities.type.Player;
|
||||||
@@ -36,7 +37,7 @@ public class OverlayRenderer{
|
|||||||
|
|
||||||
if(Core.settings.getBool("indicators")){
|
if(Core.settings.getBool("indicators")){
|
||||||
for(Player player : playerGroup.all()){
|
for(Player player : playerGroup.all()){
|
||||||
if(player != player && player.getTeam() == player.getTeam()){
|
if(Vars.player != player && Vars.player.getTeam() == player.getTeam()){
|
||||||
if(!rect.setSize(Core.camera.width * 0.9f, Core.camera.height * 0.9f)
|
if(!rect.setSize(Core.camera.width * 0.9f, Core.camera.height * 0.9f)
|
||||||
.setCenter(Core.camera.position.x, Core.camera.position.y).contains(player.x, player.y)){
|
.setCenter(Core.camera.position.x, Core.camera.position.y).contains(player.x, player.y)){
|
||||||
|
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ public enum Binding implements KeyBind{
|
|||||||
menu(Core.app.getType() == ApplicationType.Android ? KeyCode.BACK : KeyCode.ESCAPE),
|
menu(Core.app.getType() == ApplicationType.Android ? KeyCode.BACK : KeyCode.ESCAPE),
|
||||||
pause(KeyCode.SPACE),
|
pause(KeyCode.SPACE),
|
||||||
toggle_menus(KeyCode.C),
|
toggle_menus(KeyCode.C),
|
||||||
|
screenshot(KeyCode.P),
|
||||||
player_list(KeyCode.TAB, "multiplayer"),
|
player_list(KeyCode.TAB, "multiplayer"),
|
||||||
chat(KeyCode.ENTER),
|
chat(KeyCode.ENTER),
|
||||||
chat_history_prev(KeyCode.UP),
|
chat_history_prev(KeyCode.UP),
|
||||||
|
|||||||
@@ -8,7 +8,10 @@ import io.anuke.arc.graphics.Color;
|
|||||||
import io.anuke.arc.graphics.Pixmap;
|
import io.anuke.arc.graphics.Pixmap;
|
||||||
import io.anuke.arc.graphics.Pixmap.Format;
|
import io.anuke.arc.graphics.Pixmap.Format;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.util.*;
|
import io.anuke.arc.util.Pack;
|
||||||
|
import io.anuke.arc.util.Strings;
|
||||||
|
import io.anuke.arc.util.Structs;
|
||||||
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.content.Blocks;
|
import io.anuke.mindustry.content.Blocks;
|
||||||
import io.anuke.mindustry.game.MappableContent;
|
import io.anuke.mindustry.game.MappableContent;
|
||||||
import io.anuke.mindustry.game.Team;
|
import io.anuke.mindustry.game.Team;
|
||||||
@@ -72,6 +75,7 @@ public class MapIO{
|
|||||||
Pixmap floors = new Pixmap(map.width, map.height, Format.RGBA8888);
|
Pixmap floors = new Pixmap(map.width, map.height, Format.RGBA8888);
|
||||||
Pixmap walls = new Pixmap(map.width, map.height, Format.RGBA8888);
|
Pixmap walls = new Pixmap(map.width, map.height, Format.RGBA8888);
|
||||||
int black = Color.rgba8888(Color.BLACK);
|
int black = Color.rgba8888(Color.BLACK);
|
||||||
|
int shade = Color.rgba8888(0f, 0f, 0f, 0.5f);
|
||||||
CachedTile tile = new CachedTile(){
|
CachedTile tile = new CachedTile(){
|
||||||
@Override
|
@Override
|
||||||
public void setFloor(Floor type){
|
public void setFloor(Floor type){
|
||||||
@@ -87,7 +91,10 @@ public class MapIO{
|
|||||||
protected void changed(){
|
protected void changed(){
|
||||||
super.changed();
|
super.changed();
|
||||||
int c = colorFor(Blocks.air, block(), Blocks.air, getTeam());
|
int c = colorFor(Blocks.air, block(), Blocks.air, getTeam());
|
||||||
if(c != black) walls.drawPixel(x, floors.getHeight() - 1 - y, c);
|
if(c != black){
|
||||||
|
walls.drawPixel(x, floors.getHeight() - 1 - y, c);
|
||||||
|
floors.drawPixel(x, floors.getHeight() - 1 - y + 1, shade);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
readTiles(map, (x, y) -> {
|
readTiles(map, (x, y) -> {
|
||||||
|
|||||||
19
core/src/io/anuke/mindustry/type/LiquidStack.java
Normal file
19
core/src/io/anuke/mindustry/type/LiquidStack.java
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
package io.anuke.mindustry.type;
|
||||||
|
|
||||||
|
public class LiquidStack{
|
||||||
|
public Liquid liquid;
|
||||||
|
public float amount;
|
||||||
|
|
||||||
|
public LiquidStack(Liquid liquid, float amount){
|
||||||
|
this.liquid = liquid;
|
||||||
|
this.amount = amount;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString(){
|
||||||
|
return "LiquidStack{" +
|
||||||
|
"liquid=" + liquid +
|
||||||
|
", amount=" + amount +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
package io.anuke.mindustry.ui;
|
package io.anuke.mindustry.ui;
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
|
import io.anuke.arc.collection.Array;
|
||||||
import io.anuke.arc.collection.OrderedMap;
|
import io.anuke.arc.collection.OrderedMap;
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.Color;
|
||||||
import io.anuke.arc.scene.ui.layout.Table;
|
import io.anuke.arc.scene.ui.layout.Table;
|
||||||
@@ -45,7 +46,7 @@ public class ContentDisplay{
|
|||||||
BlockStats stats = block.stats;
|
BlockStats stats = block.stats;
|
||||||
|
|
||||||
for(StatCategory cat : stats.toMap().keys()){
|
for(StatCategory cat : stats.toMap().keys()){
|
||||||
OrderedMap<BlockStat, StatValue> map = stats.toMap().get(cat);
|
OrderedMap<BlockStat, Array<StatValue>> map = stats.toMap().get(cat);
|
||||||
|
|
||||||
if(map.size == 0) continue;
|
if(map.size == 0) continue;
|
||||||
|
|
||||||
@@ -56,7 +57,13 @@ public class ContentDisplay{
|
|||||||
table.table(inset -> {
|
table.table(inset -> {
|
||||||
inset.left();
|
inset.left();
|
||||||
inset.add("[LIGHT_GRAY]" + stat.localized() + ":[] ");
|
inset.add("[LIGHT_GRAY]" + stat.localized() + ":[] ");
|
||||||
map.get(stat).display(inset);
|
Array<StatValue> arr = map.get(stat);
|
||||||
|
for(StatValue value : arr){
|
||||||
|
value.display(inset);
|
||||||
|
inset.add().size(10f);
|
||||||
|
}
|
||||||
|
|
||||||
|
//map.get(stat).display(inset);
|
||||||
}).fillX().padLeft(10);
|
}).fillX().padLeft(10);
|
||||||
table.row();
|
table.row();
|
||||||
}
|
}
|
||||||
@@ -134,6 +141,7 @@ public class ContentDisplay{
|
|||||||
title.addImage(mech.getContentIcon()).size(8 * 6);
|
title.addImage(mech.getContentIcon()).size(8 * 6);
|
||||||
title.add("[accent]" + mech.localizedName()).padLeft(5);
|
title.add("[accent]" + mech.localizedName()).padLeft(5);
|
||||||
});
|
});
|
||||||
|
table.left().defaults().left();
|
||||||
|
|
||||||
table.row();
|
table.row();
|
||||||
|
|
||||||
@@ -159,13 +167,17 @@ public class ContentDisplay{
|
|||||||
table.add(Core.bundle.format("mech.ability", Core.bundle.get("mech." + mech.name + ".ability")));
|
table.add(Core.bundle.format("mech.ability", Core.bundle.get("mech." + mech.name + ".ability")));
|
||||||
table.row();
|
table.row();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
table.add(Core.bundle.format("mech.buildspeed", (int)(mech.buildPower * 100f)));
|
||||||
|
table.row();
|
||||||
|
|
||||||
table.add(Core.bundle.format("mech.health", (int)mech.health));
|
table.add(Core.bundle.format("mech.health", (int)mech.health));
|
||||||
table.row();
|
table.row();
|
||||||
table.add(Core.bundle.format("mech.itemcapacity", mech.itemCapacity));
|
table.add(Core.bundle.format("mech.itemcapacity", mech.itemCapacity));
|
||||||
table.row();
|
table.row();
|
||||||
|
|
||||||
if(mech.drillPower > 0){
|
if(mech.drillPower > 0){
|
||||||
table.add(Core.bundle.format("mech.minespeed", (int) (mech.mineSpeed * 10)));
|
table.add(Core.bundle.format("mech.minespeed", (int)(mech.mineSpeed * 100f)));
|
||||||
table.row();
|
table.row();
|
||||||
table.add(Core.bundle.format("mech.minepower", mech.drillPower));
|
table.add(Core.bundle.format("mech.minepower", mech.drillPower));
|
||||||
table.row();
|
table.row();
|
||||||
@@ -196,7 +208,7 @@ public class ContentDisplay{
|
|||||||
|
|
||||||
table.add(Core.bundle.format("unit.health", unit.health));
|
table.add(Core.bundle.format("unit.health", unit.health));
|
||||||
table.row();
|
table.row();
|
||||||
table.add(Core.bundle.format("unit.speed", Strings.toFixed(unit.speed, 1)));
|
table.add(Core.bundle.format("unit.speed", Strings.fixed(unit.speed, 1)));
|
||||||
table.row();
|
table.row();
|
||||||
table.row();
|
table.row();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ public class ItemDisplay extends Table{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public ItemDisplay(Item item, int amount){
|
public ItemDisplay(Item item, int amount){
|
||||||
add(new ItemImage(new ItemStack(item, amount))).size(8*3);
|
add(new ItemImage(new ItemStack(item, amount))).size(8*4);
|
||||||
add(item.localizedName()).padLeft(4);
|
add(item.localizedName()).padLeft(4);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ public class ItemImage extends Stack{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public ItemImage(ItemStack stack){
|
public ItemImage(ItemStack stack){
|
||||||
add(new Image(stack.item.icon(Icon.medium)));
|
add(new Image(stack.item.icon(Icon.large)));
|
||||||
|
|
||||||
if(stack.amount != 0){
|
if(stack.amount != 0){
|
||||||
Table t = new Table().left().bottom();
|
Table t = new Table().left().bottom();
|
||||||
|
|||||||
@@ -1,14 +1,31 @@
|
|||||||
package io.anuke.mindustry.ui;
|
package io.anuke.mindustry.ui;
|
||||||
|
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.arc.graphics.Color;
|
||||||
import io.anuke.arc.scene.ui.Image;
|
import io.anuke.arc.scene.ui.Image;
|
||||||
|
import io.anuke.arc.scene.ui.layout.Stack;
|
||||||
import io.anuke.arc.scene.ui.layout.Table;
|
import io.anuke.arc.scene.ui.layout.Table;
|
||||||
|
import io.anuke.arc.util.Strings;
|
||||||
|
import io.anuke.mindustry.type.Liquid;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
/**An ItemDisplay, but for liquids.*/
|
/**An ItemDisplay, but for liquids.*/
|
||||||
public class LiquidDisplay extends Table{
|
public class LiquidDisplay extends Table{
|
||||||
|
|
||||||
public LiquidDisplay(Liquid liquid){
|
public LiquidDisplay(Liquid liquid, float amount, boolean perSecond){
|
||||||
add(new Image(liquid.getContentIcon())).size(8*3);
|
add(new Stack(){{
|
||||||
add(liquid.localizedName()).padLeft(3);
|
add(new Image(liquid.getContentIcon()));
|
||||||
|
|
||||||
|
if(amount != 0){
|
||||||
|
Table t = new Table().left().bottom();
|
||||||
|
t.add(Strings.autoFixed(amount, 1));
|
||||||
|
add(t);
|
||||||
|
}
|
||||||
|
}}).size(8*4).padRight(3);
|
||||||
|
|
||||||
|
if(perSecond){
|
||||||
|
add(StatUnit.perSecond.localized()).padLeft(2).padRight(5).color(Color.LIGHT_GRAY);
|
||||||
|
}
|
||||||
|
|
||||||
|
add(liquid.localizedName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -187,9 +187,9 @@ public class BlockInventoryFragment extends Fragment{
|
|||||||
private String round(float f){
|
private String round(float f){
|
||||||
f = (int) f;
|
f = (int) f;
|
||||||
if(f >= 1000000){
|
if(f >= 1000000){
|
||||||
return Strings.toFixed(f / 1000000f, 1) + "[gray]mil[]";
|
return Strings.fixed(f / 1000000f, 1) + "[gray]mil[]";
|
||||||
}else if(f >= 1000){
|
}else if(f >= 1000){
|
||||||
return Strings.toFixed(f / 1000, 1) + "k";
|
return Strings.fixed(f / 1000, 1) + "k";
|
||||||
}else{
|
}else{
|
||||||
return (int) f + "";
|
return (int) f + "";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -192,7 +192,7 @@ public class PlacementFragment extends Fragment{
|
|||||||
topTable.table(header -> {
|
topTable.table(header -> {
|
||||||
header.left();
|
header.left();
|
||||||
header.add(new Image(lastDisplay.icon(Icon.medium))).size(8 * 4);
|
header.add(new Image(lastDisplay.icon(Icon.medium))).size(8 * 4);
|
||||||
header.labelWrap(() -> !unlocked(lastDisplay) ? Core.bundle.get("blocks.unknown") : lastDisplay.localizedName)
|
header.labelWrap(() -> !unlocked(lastDisplay) ? Core.bundle.get("block.unknown") : lastDisplay.localizedName)
|
||||||
.left().width(190f).padLeft(5);
|
.left().width(190f).padLeft(5);
|
||||||
header.add().growX();
|
header.add().growX();
|
||||||
if(unlocked(lastDisplay)){
|
if(unlocked(lastDisplay)){
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ import io.anuke.mindustry.ui.Bar;
|
|||||||
import io.anuke.mindustry.ui.ContentDisplay;
|
import io.anuke.mindustry.ui.ContentDisplay;
|
||||||
import io.anuke.mindustry.world.consumers.Consume;
|
import io.anuke.mindustry.world.consumers.Consume;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumePower;
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
import io.anuke.mindustry.world.meta.*;
|
import io.anuke.mindustry.world.meta.*;
|
||||||
|
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
@@ -95,6 +95,8 @@ public class Block extends BlockStorage{
|
|||||||
public boolean canOverdrive = true;
|
public boolean canOverdrive = true;
|
||||||
/**Whether the icon region has an outline added.*/
|
/**Whether the icon region has an outline added.*/
|
||||||
public boolean outlineIcon = false;
|
public boolean outlineIcon = false;
|
||||||
|
/**Whether this block has a shadow under it.*/
|
||||||
|
public boolean hasShadow = true;
|
||||||
|
|
||||||
/**Cost of constructing this block.*/
|
/**Cost of constructing this block.*/
|
||||||
public ItemStack[] buildRequirements = new ItemStack[]{};
|
public ItemStack[] buildRequirements = new ItemStack[]{};
|
||||||
@@ -106,6 +108,9 @@ public class Block extends BlockStorage{
|
|||||||
public BooleanProvider buildVisibility = () -> false;
|
public BooleanProvider buildVisibility = () -> false;
|
||||||
public boolean alwaysUnlocked = false;
|
public boolean alwaysUnlocked = false;
|
||||||
|
|
||||||
|
protected TextureRegion[] cacheRegions = {};
|
||||||
|
protected Array<String> cacheRegionStrings = new Array<>();
|
||||||
|
|
||||||
protected Array<Tile> tempTiles = new Array<>();
|
protected Array<Tile> tempTiles = new Array<>();
|
||||||
protected TextureRegion[] icons = new TextureRegion[Icon.values().length];
|
protected TextureRegion[] icons = new TextureRegion[Icon.values().length];
|
||||||
protected TextureRegion[] generatedIcons;
|
protected TextureRegion[] generatedIcons;
|
||||||
@@ -161,7 +166,7 @@ public class Block extends BlockStorage{
|
|||||||
if(tile == null || tile.entity == null || tile.entity.power == null) return out;
|
if(tile == null || tile.entity == null || tile.entity.power == null) return out;
|
||||||
|
|
||||||
for(Tile other : tile.entity.proximity()){
|
for(Tile other : tile.entity.proximity()){
|
||||||
if(other.entity.power != null && !(consumesPower && other.block().consumesPower && !outputsPower && !other.block().outputsPower)
|
if(other != null && other.entity != null && other.entity.power != null && !(consumesPower && other.block().consumesPower && !outputsPower && !other.block().outputsPower)
|
||||||
&& !tile.entity.power.links.contains(other.pos())){
|
&& !tile.entity.power.links.contains(other.pos())){
|
||||||
out.add(other);
|
out.add(other);
|
||||||
}
|
}
|
||||||
@@ -230,10 +235,6 @@ public class Block extends BlockStorage{
|
|||||||
Draw.rect(region, tile.drawx(), tile.drawy(), rotate ? tile.getRotation() * 90 : 0);
|
Draw.rect(region, tile.drawx(), tile.drawy(), rotate ? tile.getRotation() * 90 : 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void drawShadow(Tile tile){
|
|
||||||
draw(tile);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void drawTeam(Tile tile){
|
public void drawTeam(Tile tile){
|
||||||
Draw.color(tile.getTeam().color);
|
Draw.color(tile.getTeam().color);
|
||||||
Draw.rect("block-border", tile.drawx() - size * tilesize/2f + 4, tile.drawy() - size * tilesize/2f + 4);
|
Draw.rect("block-border", tile.drawx() - size * tilesize/2f + 4, tile.drawy() - size * tilesize/2f + 4);
|
||||||
@@ -318,12 +319,28 @@ public class Block extends BlockStorage{
|
|||||||
setStats();
|
setStats();
|
||||||
setBars();
|
setBars();
|
||||||
|
|
||||||
consumes.checkRequired(this);
|
consumes.init();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void load(){
|
public void load(){
|
||||||
region = Core.atlas.find(name);
|
region = Core.atlas.find(name);
|
||||||
|
|
||||||
|
cacheRegions = new TextureRegion[cacheRegionStrings.size];
|
||||||
|
for(int i = 0; i < cacheRegions.length; i++){
|
||||||
|
cacheRegions[i] = Core.atlas.find(cacheRegionStrings.get(i));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**Adds a region by name to be loaded, with the final name "{name}-suffix". Returns an ID to looks this region up by in {@link #reg(int)}.*/
|
||||||
|
protected int reg(String suffix){
|
||||||
|
cacheRegionStrings.add(name + suffix);
|
||||||
|
return cacheRegionStrings.size - 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**Returns an internally cached region by ID.*/
|
||||||
|
protected TextureRegion reg(int id){
|
||||||
|
return cacheRegions[id];
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Called when the block is tapped. */
|
/** Called when the block is tapped. */
|
||||||
@@ -376,7 +393,7 @@ public class Block extends BlockStorage{
|
|||||||
stats.add(BlockStat.size, "{0}x{0}", size);
|
stats.add(BlockStat.size, "{0}x{0}", size);
|
||||||
stats.add(BlockStat.health, health, StatUnit.none);
|
stats.add(BlockStat.health, health, StatUnit.none);
|
||||||
|
|
||||||
consumes.forEach(cons -> cons.display(stats));
|
consumes.display(stats);
|
||||||
|
|
||||||
// Note: Power stats are added by the consumers.
|
// Note: Power stats are added by the consumers.
|
||||||
if(hasLiquids) stats.add(BlockStat.liquidCapacity, liquidCapacity, StatUnit.liquidUnits);
|
if(hasLiquids) stats.add(BlockStat.liquidCapacity, liquidCapacity, StatUnit.liquidUnits);
|
||||||
@@ -388,25 +405,25 @@ public class Block extends BlockStorage{
|
|||||||
|
|
||||||
if(hasLiquids){
|
if(hasLiquids){
|
||||||
Function<TileEntity, Liquid> current;
|
Function<TileEntity, Liquid> current;
|
||||||
if(consumes.has(ConsumeLiquid.class)){
|
if(consumes.has(ConsumeType.liquid) && consumes.get(ConsumeType.liquid) instanceof ConsumeLiquid){
|
||||||
Liquid liquid = consumes.liquid();
|
Liquid liquid = consumes.<ConsumeLiquid>get(ConsumeType.liquid).liquid;
|
||||||
current = entity -> liquid;
|
current = entity -> liquid;
|
||||||
}else{
|
}else{
|
||||||
current = entity -> entity.liquids.current();
|
current = entity -> entity.liquids.current();
|
||||||
}
|
}
|
||||||
bars.add("liquid", entity -> new Bar(() -> entity.liquids.get(current.get(entity)) <= 0.001f ? Core.bundle.get("blocks.liquid") : current.get(entity).localizedName(), () -> current.get(entity).color, () -> entity.liquids.get(current.get(entity)) / liquidCapacity));
|
bars.add("liquid", entity -> new Bar(() -> entity.liquids.get(current.get(entity)) <= 0.001f ? Core.bundle.get("bar.liquid") : current.get(entity).localizedName(), () -> current.get(entity).color, () -> entity.liquids.get(current.get(entity)) / liquidCapacity));
|
||||||
}
|
}
|
||||||
|
|
||||||
if(hasPower && consumes.has(ConsumePower.class)){
|
if(hasPower && consumes.hasPower()){
|
||||||
boolean buffered = consumes.get(ConsumePower.class).isBuffered;
|
boolean buffered = consumes.getPower().isBuffered;
|
||||||
float capacity = consumes.get(ConsumePower.class).powerCapacity;
|
float capacity = consumes.getPower().powerCapacity;
|
||||||
|
|
||||||
bars.add("power", entity -> new Bar(() -> buffered ? Core.bundle.format("blocks.powerbalance", Float.isNaN(entity.power.satisfaction * capacity) ? "<ERROR>" : (int)(entity.power.satisfaction * capacity)) :
|
bars.add("power", entity -> new Bar(() -> buffered ? Core.bundle.format("bar.powerbalance", Float.isNaN(entity.power.satisfaction * capacity) ? "<ERROR>" : (int)(entity.power.satisfaction * capacity)) :
|
||||||
Core.bundle.get("blocks.power"), () -> Pal.powerBar, () -> entity.power.satisfaction));
|
Core.bundle.get("bar.power"), () -> Pal.powerBar, () -> entity.power.satisfaction));
|
||||||
}
|
}
|
||||||
|
|
||||||
if(hasItems && configurable){
|
if(hasItems && configurable){
|
||||||
bars.add("items", entity -> new Bar(() -> Core.bundle.format("blocks.items", entity.items.total()), () -> Pal.items, () -> (float)entity.items.total() / itemCapacity));
|
bars.add("items", entity -> new Bar(() -> Core.bundle.format("bar.items", entity.items.total()), () -> Pal.items, () -> (float)entity.items.total() / itemCapacity));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -458,8 +475,8 @@ public class Block extends BlockStorage{
|
|||||||
explosiveness += tile.entity.liquids.sum((liquid, amount) -> liquid.flammability * amount / 2f);
|
explosiveness += tile.entity.liquids.sum((liquid, amount) -> liquid.flammability * amount / 2f);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(consumes.has(ConsumePower.class) && consumes.get(ConsumePower.class).isBuffered){
|
if(consumes.hasPower() && consumes.getPower().isBuffered){
|
||||||
power += tile.entity.power.satisfaction * consumes.get(ConsumePower.class).powerCapacity;
|
power += tile.entity.power.satisfaction * consumes.getPower().powerCapacity;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(hasLiquids){
|
if(hasLiquids){
|
||||||
|
|||||||
@@ -12,15 +12,10 @@ import io.anuke.mindustry.entities.type.TileEntity;
|
|||||||
import io.anuke.mindustry.entities.type.Unit;
|
import io.anuke.mindustry.entities.type.Unit;
|
||||||
import io.anuke.mindustry.game.UnlockableContent;
|
import io.anuke.mindustry.game.UnlockableContent;
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
import io.anuke.mindustry.type.ItemStack;
|
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItem;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItems;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
|
||||||
import io.anuke.mindustry.world.consumers.Consumers;
|
import io.anuke.mindustry.world.consumers.Consumers;
|
||||||
import io.anuke.mindustry.world.meta.BlockBars;
|
import io.anuke.mindustry.world.meta.BlockBars;
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
import io.anuke.mindustry.world.meta.Producers;
|
|
||||||
|
|
||||||
public abstract class BlockStorage extends UnlockableContent{
|
public abstract class BlockStorage extends UnlockableContent{
|
||||||
public boolean hasItems;
|
public boolean hasItems;
|
||||||
@@ -28,7 +23,6 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
public boolean hasPower;
|
public boolean hasPower;
|
||||||
|
|
||||||
public boolean outputsLiquid = false;
|
public boolean outputsLiquid = false;
|
||||||
public boolean singleLiquid = true;
|
|
||||||
public boolean consumesPower = true;
|
public boolean consumesPower = true;
|
||||||
public boolean outputsPower = false;
|
public boolean outputsPower = false;
|
||||||
|
|
||||||
@@ -39,7 +33,6 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
public final BlockStats stats = new BlockStats();
|
public final BlockStats stats = new BlockStats();
|
||||||
public final BlockBars bars = new BlockBars();
|
public final BlockBars bars = new BlockBars();
|
||||||
public final Consumers consumes = new Consumers();
|
public final Consumers consumes = new Consumers();
|
||||||
public final Producers produces = new Producers();
|
|
||||||
|
|
||||||
public BlockStorage(String name){
|
public BlockStorage(String name){
|
||||||
super(name);
|
super(name);
|
||||||
@@ -98,21 +91,11 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean acceptItem(Item item, Tile tile, Tile source){
|
public boolean acceptItem(Item item, Tile tile, Tile source){
|
||||||
if(tile.entity != null && consumes.has(ConsumeItems.class)){
|
return consumes.itemFilters[item.id] && tile.entity.items.get(item) < getMaximumAccepted(tile, item);
|
||||||
for(ItemStack stack : consumes.items()){
|
|
||||||
if(stack.item == item){
|
|
||||||
return tile.entity.items.get(item) < getMaximumAccepted(tile, item);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return tile.entity != null && consumes.has(ConsumeItem.class) && consumes.item() == item &&
|
|
||||||
tile.entity.items.get(item) < getMaximumAccepted(tile, item);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
||||||
return hasLiquids && tile.entity.liquids.get(liquid) + amount < liquidCapacity &&
|
return hasLiquids && tile.entity.liquids.get(liquid) + amount < liquidCapacity && consumes.liquidfilters[liquid.id];
|
||||||
(!singleLiquid || (tile.entity.liquids.current() == liquid || tile.entity.liquids.get(tile.entity.liquids.current()) < 0.2f)) &&
|
|
||||||
(!consumes.has(ConsumeLiquid.class) || consumes.liquid() == liquid);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void handleLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
public void handleLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
||||||
@@ -128,7 +111,7 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
Tile other = proximity.get((i + dump) % proximity.size);
|
Tile other = proximity.get((i + dump) % proximity.size);
|
||||||
Tile in = Edges.getFacingEdge(tile, other);
|
Tile in = Edges.getFacingEdge(tile, other);
|
||||||
|
|
||||||
if(other.getTeamID() == tile.getTeamID() && other.block().hasLiquids && canDumpLiquid(tile, other, liquid)){
|
if(other.getTeam() == tile.getTeam() && other.block().hasLiquids && canDumpLiquid(tile, other, liquid)){
|
||||||
float ofract = other.entity.liquids.get(liquid) / other.block().liquidCapacity;
|
float ofract = other.entity.liquids.get(liquid) / other.block().liquidCapacity;
|
||||||
float fract = tile.entity.liquids.get(liquid) / liquidCapacity;
|
float fract = tile.entity.liquids.get(liquid) / liquidCapacity;
|
||||||
|
|
||||||
@@ -156,7 +139,7 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
|
|
||||||
next = next.target();
|
next = next.target();
|
||||||
|
|
||||||
if(next.getTeamID() == tile.getTeamID() && next.block().hasLiquids && tile.entity.liquids.get(liquid) > 0f){
|
if(next.getTeam() == tile.getTeam() && next.block().hasLiquids && tile.entity.liquids.get(liquid) > 0f){
|
||||||
|
|
||||||
if(next.block().acceptLiquid(next, tile, liquid, 0f)){
|
if(next.block().acceptLiquid(next, tile, liquid, 0f)){
|
||||||
float ofract = next.entity.liquids.get(liquid) / next.block().liquidCapacity;
|
float ofract = next.entity.liquids.get(liquid) / next.block().liquidCapacity;
|
||||||
@@ -206,7 +189,7 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
incrementDump(tile, proximity.size);
|
incrementDump(tile, proximity.size);
|
||||||
Tile other = proximity.get((i + dump) % proximity.size);
|
Tile other = proximity.get((i + dump) % proximity.size);
|
||||||
Tile in = Edges.getFacingEdge(tile, other);
|
Tile in = Edges.getFacingEdge(tile, other);
|
||||||
if(other.getTeamID() == tile.getTeamID() && other.block().acceptItem(item, other, in) && canDump(tile, other, item)){
|
if(other.getTeam() == tile.getTeam() && other.block().acceptItem(item, other, in) && canDump(tile, other, item)){
|
||||||
other.block().handleItem(item, other, in);
|
other.block().handleItem(item, other, in);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -215,9 +198,7 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
handleItem(item, tile, tile);
|
handleItem(item, tile, tile);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**Try dumping any item near the tile.*/
|
||||||
* Try dumping any item near the tile.
|
|
||||||
*/
|
|
||||||
public boolean tryDump(Tile tile){
|
public boolean tryDump(Tile tile){
|
||||||
return tryDump(tile, null);
|
return tryDump(tile, null);
|
||||||
}
|
}
|
||||||
@@ -246,7 +227,7 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
for(int ii = 0; ii < Vars.content.items().size; ii++){
|
for(int ii = 0; ii < Vars.content.items().size; ii++){
|
||||||
Item item = Vars.content.item(ii);
|
Item item = Vars.content.item(ii);
|
||||||
|
|
||||||
if(other.getTeamID() == tile.getTeamID() && entity.items.has(item) && other.block().acceptItem(item, other, in) && canDump(tile, other, item)){
|
if(other.getTeam() == tile.getTeam() && entity.items.has(item) && other.block().acceptItem(item, other, in) && canDump(tile, other, item)){
|
||||||
other.block().handleItem(item, other, in);
|
other.block().handleItem(item, other, in);
|
||||||
tile.entity.items.remove(item, 1);
|
tile.entity.items.remove(item, 1);
|
||||||
incrementDump(tile, proximity.size);
|
incrementDump(tile, proximity.size);
|
||||||
@@ -255,7 +236,7 @@ public abstract class BlockStorage extends UnlockableContent{
|
|||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
|
|
||||||
if(other.getTeamID() == tile.getTeamID() && other.block().acceptItem(todump, other, in) && canDump(tile, other, todump)){
|
if(other.getTeam() == tile.getTeam() && other.block().acceptItem(todump, other, in) && canDump(tile, other, todump)){
|
||||||
other.block().handleItem(todump, other, in);
|
other.block().handleItem(todump, other, in);
|
||||||
tile.entity.items.remove(todump, 1);
|
tile.entity.items.remove(todump, 1);
|
||||||
incrementDump(tile, proximity.size);
|
incrementDump(tile, proximity.size);
|
||||||
|
|||||||
@@ -31,6 +31,8 @@ public class Tile implements Position, TargetTrait{
|
|||||||
public byte link = 0;
|
public byte link = 0;
|
||||||
/** Tile traversal cost. */
|
/** Tile traversal cost. */
|
||||||
public byte cost = 1;
|
public byte cost = 1;
|
||||||
|
/** Weight of [ground] units on this tile.*/
|
||||||
|
public byte weight, airWeight = 0;
|
||||||
/** Tile entity, usually null. */
|
/** Tile entity, usually null. */
|
||||||
public TileEntity entity;
|
public TileEntity entity;
|
||||||
public short x, y;
|
public short x, y;
|
||||||
|
|||||||
@@ -38,11 +38,6 @@ public class BlockPart extends Block{
|
|||||||
//do nothing
|
//do nothing
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void drawShadow(Tile tile){
|
|
||||||
//also do nothing
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isSolidFor(Tile tile){
|
public boolean isSolidFor(Tile tile){
|
||||||
return tile.getLinked() == null
|
return tile.getLinked() == null
|
||||||
|
|||||||
@@ -158,12 +158,6 @@ public class BuildBlock extends Block{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void drawShadow(Tile tile){
|
|
||||||
//don't
|
|
||||||
//TODO maybe do
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TileEntity newEntity(){
|
public TileEntity newEntity(){
|
||||||
return new BuildEntity();
|
return new BuildEntity();
|
||||||
|
|||||||
@@ -19,12 +19,6 @@ public class TreeBlock extends Block{
|
|||||||
@Override
|
@Override
|
||||||
public void draw(Tile tile){}
|
public void draw(Tile tile){}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void drawShadow(Tile tile){
|
|
||||||
Draw.rect(region, tile.drawx(), tile.drawy(), Mathf.randomSeed(tile.pos(), 0, 4) * 90);
|
|
||||||
Draw.rect(region, tile.drawx() - shadowOffset, tile.drawy() - shadowOffset, Mathf.randomSeed(tile.pos(), 0, 4) * 90);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void drawLayer(Tile tile){
|
public void drawLayer(Tile tile){
|
||||||
Draw.rect(region, tile.drawx(), tile.drawy(), Mathf.randomSeed(tile.pos(), 0, 4) * 90);
|
Draw.rect(region, tile.drawx(), tile.drawy(), Mathf.randomSeed(tile.pos(), 0, 4) * 90);
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ import io.anuke.mindustry.world.Block;
|
|||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumePower;
|
import io.anuke.mindustry.world.consumers.ConsumePower;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
@@ -54,7 +55,7 @@ public class ForceProjector extends Block {
|
|||||||
canOverdrive = false;
|
canOverdrive = false;
|
||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 0.1f)).optional(true).boost(true).update(false);
|
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 0.1f)).optional(true).update(false);
|
||||||
consumePower = new ConsumeForceProjectorPower(60f, 60f);
|
consumePower = new ConsumeForceProjectorPower(60f, 60f);
|
||||||
consumes.add(consumePower);
|
consumes.add(consumePower);
|
||||||
}
|
}
|
||||||
@@ -71,6 +72,8 @@ public class ForceProjector extends Block {
|
|||||||
|
|
||||||
stats.add(BlockStat.powerUse, basePowerDraw * 60f, StatUnit.powerSecond);
|
stats.add(BlockStat.powerUse, basePowerDraw * 60f, StatUnit.powerSecond);
|
||||||
stats.add(BlockStat.powerDamage, powerDamage, StatUnit.powerUnits);
|
stats.add(BlockStat.powerDamage, powerDamage, StatUnit.powerUnits);
|
||||||
|
|
||||||
|
stats.add(BlockStat.boostEffect, phaseRadiusBoost/tilesize, StatUnit.blocks);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -83,10 +86,10 @@ public class ForceProjector extends Block {
|
|||||||
entity.shield.add();
|
entity.shield.add();
|
||||||
}
|
}
|
||||||
|
|
||||||
entity.phaseHeat = Mathf.lerpDelta(entity.phaseHeat, (float)entity.items.get(consumes.item()) / itemCapacity, 0.1f);
|
entity.phaseHeat = Mathf.lerpDelta(entity.phaseHeat, Mathf.num(entity.cons.optionalValid()), 0.1f);
|
||||||
|
|
||||||
if(entity.cons.valid() && !entity.broken && entity.timer.get(timerUse, phaseUseTime) && entity.items.total() > 0){
|
if(entity.cons.optionalValid() && !entity.broken && entity.timer.get(timerUse, phaseUseTime)){
|
||||||
entity.items.remove(consumes.item(), 1);
|
entity.cons.trigger();
|
||||||
}
|
}
|
||||||
|
|
||||||
entity.radscl = Mathf.lerpDelta(entity.radscl, entity.broken ? 0f : 1f, 0.05f);
|
entity.radscl = Mathf.lerpDelta(entity.radscl, entity.broken ? 0f : 1f, 0.05f);
|
||||||
@@ -95,7 +98,7 @@ public class ForceProjector extends Block {
|
|||||||
Effects.effect(Fx.reactorsmoke, tile.drawx() + Mathf.range(tilesize/2f), tile.drawy() + Mathf.range(tilesize/2f));
|
Effects.effect(Fx.reactorsmoke, tile.drawx() + Mathf.range(tilesize/2f), tile.drawy() + Mathf.range(tilesize/2f));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Use Cases:
|
//use cases:
|
||||||
// - There is enough power in the buffer, and there are no shots fired => Draw base power and keep shield up
|
// - There is enough power in the buffer, and there are no shots fired => Draw base power and keep shield up
|
||||||
// - There is enough power in the buffer, but not enough power to cope for shots being fired => Draw all power and break shield
|
// - There is enough power in the buffer, but not enough power to cope for shots being fired => Draw all power and break shield
|
||||||
// - There is enough power in the buffer and enough power to cope for shots being fired => Draw base power + additional power based on shots absorbed
|
// - There is enough power in the buffer and enough power to cope for shots being fired => Draw base power + additional power based on shots absorbed
|
||||||
@@ -120,8 +123,9 @@ public class ForceProjector extends Block {
|
|||||||
|
|
||||||
if(entity.buildup > 0){
|
if(entity.buildup > 0){
|
||||||
float scale = !entity.broken ? cooldownNormal : cooldownBrokenBase;
|
float scale = !entity.broken ? cooldownNormal : cooldownBrokenBase;
|
||||||
if(consumes.get(ConsumeLiquidFilter.class).valid(this, entity)){
|
ConsumeLiquidFilter cons = consumes.get(ConsumeType.liquid);
|
||||||
consumes.get(ConsumeLiquidFilter.class).update(this, entity);
|
if(cons.valid(entity)){
|
||||||
|
cons.update(entity);
|
||||||
scale *= (cooldownLiquid * (1f+(entity.liquids.current().heatCapacity-0.4f)*0.9f));
|
scale *= (cooldownLiquid * (1f+(entity.liquids.current().heatCapacity-0.4f)*0.9f));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -268,8 +272,8 @@ public class ForceProjector extends Block {
|
|||||||
super(powerCapacity / ticksToFill, powerCapacity, true);
|
super(powerCapacity / ticksToFill, powerCapacity, true);
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public boolean valid(Block block, TileEntity entity){
|
public boolean valid(TileEntity entity){
|
||||||
return entity.power.satisfaction >= basePowerDraw / powerCapacity && super.valid(block, entity);
|
return entity.power.satisfaction >= basePowerDraw / powerCapacity && super.valid(entity);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -60,6 +60,9 @@ public class MendProjector extends Block{
|
|||||||
|
|
||||||
stats.add(BlockStat.repairTime, (int)(100f / healPercent * reload / 60f), StatUnit.seconds);
|
stats.add(BlockStat.repairTime, (int)(100f / healPercent * reload / 60f), StatUnit.seconds);
|
||||||
stats.add(BlockStat.range, range / tilesize, StatUnit.blocks);
|
stats.add(BlockStat.range, range / tilesize, StatUnit.blocks);
|
||||||
|
|
||||||
|
stats.add(BlockStat.boostEffect, phaseRangeBoost/tilesize, StatUnit.blocks);
|
||||||
|
stats.add(BlockStat.boostEffect, (phaseBoost + healPercent) / healPercent, StatUnit.timesSpeed);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -68,10 +71,10 @@ public class MendProjector extends Block{
|
|||||||
entity.heat = Mathf.lerpDelta(entity.heat, entity.cons.valid() || tile.isEnemyCheat() ? 1f : 0f, 0.08f);
|
entity.heat = Mathf.lerpDelta(entity.heat, entity.cons.valid() || tile.isEnemyCheat() ? 1f : 0f, 0.08f);
|
||||||
entity.charge += entity.heat * entity.delta();
|
entity.charge += entity.heat * entity.delta();
|
||||||
|
|
||||||
entity.phaseHeat = Mathf.lerpDelta(entity.phaseHeat, (float)entity.items.get(consumes.item()) / itemCapacity, 0.1f);
|
entity.phaseHeat = Mathf.lerpDelta(entity.phaseHeat, Mathf.num(entity.cons.optionalValid()), 0.1f);
|
||||||
|
|
||||||
if(entity.cons.valid() && entity.timer.get(timerUse, useTime) && entity.items.total() > 0){
|
if(entity.cons.optionalValid() && entity.timer.get(timerUse, useTime)){
|
||||||
entity.items.remove(consumes.item(), 1);
|
entity.cons.trigger();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(entity.charge >= reload){
|
if(entity.charge >= reload){
|
||||||
@@ -83,7 +86,7 @@ public class MendProjector extends Block{
|
|||||||
|
|
||||||
for(int x = -tileRange + tile.x; x <= tileRange + tile.x; x++){
|
for(int x = -tileRange + tile.x; x <= tileRange + tile.x; x++){
|
||||||
for(int y = -tileRange + tile.y; y <= tileRange + tile.y; y++){
|
for(int y = -tileRange + tile.y; y <= tileRange + tile.y; y++){
|
||||||
if(Mathf.dst(x, y, tile.x, tile.y) > realRange) continue;
|
if(Mathf.dst(x, y, tile.x, tile.y) > tileRange) continue;
|
||||||
|
|
||||||
Tile other = world.tile(x, y);
|
Tile other = world.tile(x, y);
|
||||||
|
|
||||||
@@ -125,7 +128,7 @@ public class MendProjector extends Block{
|
|||||||
|
|
||||||
Draw.alpha(1f);
|
Draw.alpha(1f);
|
||||||
Lines.stroke((2f * f + 0.2f)* entity.heat);
|
Lines.stroke((2f * f + 0.2f)* entity.heat);
|
||||||
Lines.circle(tile.drawx(), tile.drawy(), (1f-f) * 9f);
|
Lines.circle(tile.drawx(), tile.drawy(), ((1f-f) * 8f) * size/2f);
|
||||||
|
|
||||||
Draw.reset();
|
Draw.reset();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,6 +12,8 @@ import io.anuke.arc.util.Time;
|
|||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
import java.io.DataInput;
|
import java.io.DataInput;
|
||||||
import java.io.DataOutput;
|
import java.io.DataOutput;
|
||||||
@@ -50,16 +52,27 @@ public class OverdriveProjector extends Block{
|
|||||||
topRegion = Core.atlas.find(name + "-top");
|
topRegion = Core.atlas.find(name + "-top");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
stats.add(BlockStat.speedIncrease, (int)(100f * speedBoost), StatUnit.percent);
|
||||||
|
stats.add(BlockStat.range, range / tilesize, StatUnit.blocks);
|
||||||
|
|
||||||
|
stats.add(BlockStat.boostEffect, phaseRangeBoost/tilesize, StatUnit.blocks);
|
||||||
|
stats.add(BlockStat.boostEffect, (int)((speedBoost + speedBoostPhase) * 100f), StatUnit.percent);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Tile tile){
|
public void update(Tile tile){
|
||||||
OverdriveEntity entity = tile.entity();
|
OverdriveEntity entity = tile.entity();
|
||||||
entity.heat = Mathf.lerpDelta(entity.heat, entity.cons.valid() ? 1f : 0f, 0.08f);
|
entity.heat = Mathf.lerpDelta(entity.heat, entity.cons.valid() ? 1f : 0f, 0.08f);
|
||||||
entity.charge += entity.heat * Time.delta();
|
entity.charge += entity.heat * Time.delta();
|
||||||
|
|
||||||
entity.phaseHeat = Mathf.lerpDelta(entity.phaseHeat, (float)entity.items.get(consumes.item()) / itemCapacity, 0.1f);
|
entity.phaseHeat = Mathf.lerpDelta(entity.phaseHeat, Mathf.num(entity.cons.optionalValid()), 0.1f);
|
||||||
|
|
||||||
if(entity.timer.get(timerUse, useTime) && entity.items.total() > 0){
|
if(entity.timer.get(timerUse, useTime)){
|
||||||
entity.items.remove(consumes.item(), 1);
|
entity.cons.trigger();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(entity.charge >= reload){
|
if(entity.charge >= reload){
|
||||||
|
|||||||
@@ -1,21 +1,23 @@
|
|||||||
package io.anuke.mindustry.world.blocks.defense.turrets;
|
package io.anuke.mindustry.world.blocks.defense.turrets;
|
||||||
|
|
||||||
|
import io.anuke.arc.math.Mathf;
|
||||||
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.content.Fx;
|
import io.anuke.mindustry.content.Fx;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
|
||||||
import io.anuke.mindustry.entities.Effects;
|
import io.anuke.mindustry.entities.Effects;
|
||||||
import io.anuke.mindustry.entities.Effects.Effect;
|
import io.anuke.mindustry.entities.Effects.Effect;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidBase;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.tilesize;
|
import static io.anuke.mindustry.Vars.tilesize;
|
||||||
|
|
||||||
public class CooledTurret extends Turret{
|
public class CooledTurret extends Turret{
|
||||||
/**How much reload is lowered by for each unit of liquid of heat capacity 1.*/
|
/**How much reload is lowered by for each unit of liquid of heat capacity.*/
|
||||||
protected float coolantMultiplier = 1f;
|
protected float coolantMultiplier = 2f;
|
||||||
/**Max coolant used per tick.*/
|
|
||||||
protected float maxCoolantUsed = 1f;
|
|
||||||
protected Effect coolEffect = Fx.fuelburn;
|
protected Effect coolEffect = Fx.fuelburn;
|
||||||
|
|
||||||
public CooledTurret(String name){
|
public CooledTurret(String name){
|
||||||
@@ -23,17 +25,28 @@ public class CooledTurret extends Turret{
|
|||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
liquidCapacity = 20f;
|
liquidCapacity = 20f;
|
||||||
|
|
||||||
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 0.01f)).update(false).optional(true);
|
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 0.5f)).update(false).optional(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
float maxUsed = consumes.<ConsumeLiquidBase>get(ConsumeType.liquid).amount;
|
||||||
|
|
||||||
|
stats.add(BlockStat.boostEffect, 1f + maxUsed * coolantMultiplier, StatUnit.timesSpeed);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void updateShooting(Tile tile){
|
protected void updateShooting(Tile tile){
|
||||||
super.updateShooting(tile);
|
super.updateShooting(tile);
|
||||||
|
|
||||||
|
float maxUsed = consumes.<ConsumeLiquidBase>get(ConsumeType.liquid).amount;
|
||||||
|
|
||||||
TurretEntity entity = tile.entity();
|
TurretEntity entity = tile.entity();
|
||||||
Liquid liquid = entity.liquids.current();
|
Liquid liquid = entity.liquids.current();
|
||||||
|
|
||||||
float used = Math.min(Math.min(entity.liquids.get(liquid), maxCoolantUsed * Time.delta()), Math.max(0, ((reload - entity.reload) / coolantMultiplier) / liquid.heatCapacity));
|
float used = Math.min(Math.min(entity.liquids.get(liquid), maxUsed * Time.delta()), Math.max(0, ((reload - entity.reload) / coolantMultiplier) / liquid.heatCapacity));
|
||||||
entity.reload += (used * liquid.heatCapacity) / liquid.heatCapacity;
|
entity.reload += (used * liquid.heatCapacity) / liquid.heatCapacity;
|
||||||
entity.liquids.remove(liquid, used);
|
entity.liquids.remove(liquid, used);
|
||||||
|
|
||||||
@@ -41,9 +54,4 @@ public class CooledTurret extends Turret{
|
|||||||
Effects.effect(coolEffect, tile.drawx() + Mathf.range(size * tilesize / 2f), tile.drawy() + Mathf.range(size * tilesize / 2f));
|
Effects.effect(coolEffect, tile.drawx() + Mathf.range(size * tilesize / 2f), tile.drawy() + Mathf.range(size * tilesize / 2f));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
|
||||||
return super.acceptLiquid(tile, source, liquid, amount) && liquid.temperature <= 0.5f;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,15 +1,17 @@
|
|||||||
package io.anuke.mindustry.world.blocks.defense.turrets;
|
package io.anuke.mindustry.world.blocks.defense.turrets;
|
||||||
|
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.arc.math.Angles;
|
import io.anuke.arc.math.Angles;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.Effects;
|
||||||
import io.anuke.mindustry.entities.bullet.Bullet;
|
import io.anuke.mindustry.entities.bullet.Bullet;
|
||||||
import io.anuke.mindustry.entities.bullet.BulletType;
|
import io.anuke.mindustry.entities.bullet.BulletType;
|
||||||
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidBase;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.tilesize;
|
import static io.anuke.mindustry.Vars.tilesize;
|
||||||
|
|
||||||
@@ -21,7 +23,6 @@ public class LaserTurret extends PowerTurret{
|
|||||||
super(name);
|
super(name);
|
||||||
canOverdrive = false;
|
canOverdrive = false;
|
||||||
|
|
||||||
consumes.remove(ConsumeLiquidFilter.class);
|
|
||||||
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 0.01f)).update(false);
|
consumes.add(new ConsumeLiquidFilter(liquid -> liquid.temperature <= 0.5f && liquid.flammability < 0.1f, 0.01f)).update(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -61,8 +62,9 @@ public class LaserTurret extends PowerTurret{
|
|||||||
entity.reload = 0f;
|
entity.reload = 0f;
|
||||||
}else{
|
}else{
|
||||||
Liquid liquid = entity.liquids.current();
|
Liquid liquid = entity.liquids.current();
|
||||||
|
float maxUsed = consumes.<ConsumeLiquidBase>get(ConsumeType.liquid).amount;
|
||||||
|
|
||||||
float used = Math.min(Math.min(entity.liquids.get(liquid), maxCoolantUsed * Time.delta()), Math.max(0, ((reload - entity.reload) / coolantMultiplier) / liquid.heatCapacity));
|
float used = Math.min(Math.min(entity.liquids.get(liquid), maxUsed * Time.delta()), Math.max(0, ((reload - entity.reload) / coolantMultiplier) / liquid.heatCapacity));
|
||||||
entity.reload += (used * liquid.heatCapacity) / liquid.heatCapacity;
|
entity.reload += (used * liquid.heatCapacity) / liquid.heatCapacity;
|
||||||
entity.liquids.remove(liquid, used);
|
entity.liquids.remove(liquid, used);
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,6 @@ package io.anuke.mindustry.world.blocks.defense.turrets;
|
|||||||
|
|
||||||
import io.anuke.mindustry.entities.bullet.BulletType;
|
import io.anuke.mindustry.entities.bullet.BulletType;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumePower;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
@@ -20,7 +19,7 @@ public abstract class PowerTurret extends CooledTurret{
|
|||||||
public void setStats(){
|
public void setStats(){
|
||||||
super.setStats();
|
super.setStats();
|
||||||
|
|
||||||
stats.add(BlockStat.powerShot, powerUsed * consumes.get(ConsumePower.class).powerCapacity, StatUnit.powerUnits);
|
stats.add(BlockStat.powerShot, powerUsed * consumes.getPower().powerCapacity, StatUnit.powerUnits);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ public class MassDriver extends Block{
|
|||||||
public void setStats(){
|
public void setStats(){
|
||||||
super.setStats();
|
super.setStats();
|
||||||
|
|
||||||
stats.add(BlockStat.powerShot, consumes.get(ConsumePower.class).powerCapacity * powerPercentageUsed, StatUnit.powerUnits);
|
stats.add(BlockStat.powerShot, consumes.getPower().powerCapacity * powerPercentageUsed, StatUnit.powerUnits);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,13 +1,13 @@
|
|||||||
package io.anuke.mindustry.world.blocks.distribution;
|
package io.anuke.mindustry.world.blocks.distribution;
|
||||||
|
|
||||||
import io.anuke.arc.collection.Array;
|
import io.anuke.arc.collection.Array;
|
||||||
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Edges;
|
import io.anuke.mindustry.world.Edges;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.meta.BlockGroup;
|
import io.anuke.mindustry.world.meta.BlockGroup;
|
||||||
import io.anuke.arc.util.Time;
|
|
||||||
|
|
||||||
public class Router extends Block{
|
public class Router extends Block{
|
||||||
protected float speed = 8f;
|
protected float speed = 8f;
|
||||||
@@ -46,7 +46,7 @@ public class Router extends Block{
|
|||||||
public boolean acceptItem(Item item, Tile tile, Tile source){
|
public boolean acceptItem(Item item, Tile tile, Tile source){
|
||||||
SplitterEntity entity = tile.entity();
|
SplitterEntity entity = tile.entity();
|
||||||
|
|
||||||
return tile.getTeamID() == source.getTeamID() && entity.lastItem == null && entity.items.total() == 0;
|
return tile.getTeam() == source.getTeam() && entity.lastItem == null && entity.items.total() == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,28 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.power;
|
|
||||||
|
|
||||||
import io.anuke.mindustry.type.Item;
|
|
||||||
import io.anuke.mindustry.type.Liquid;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItem;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
|
||||||
|
|
||||||
public class DifferentialGenerator extends TurbineGenerator{
|
|
||||||
|
|
||||||
public DifferentialGenerator(String name){
|
|
||||||
super(name);
|
|
||||||
|
|
||||||
hasLiquids = true;
|
|
||||||
consumes.require(ConsumeItem.class);
|
|
||||||
consumes.require(ConsumeLiquid.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptItem(Item item, Tile tile, Tile source){
|
|
||||||
return hasItems && consumes.item() == item && tile.entity.items.total() < itemCapacity;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
|
||||||
return hasLiquids && consumes.liquid() == liquid && tile.entity.liquids.get(liquid) < liquidCapacity;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -16,7 +16,8 @@ import io.anuke.mindustry.entities.type.TileEntity;
|
|||||||
import io.anuke.mindustry.graphics.Pal;
|
import io.anuke.mindustry.graphics.Pal;
|
||||||
import io.anuke.mindustry.ui.Bar;
|
import io.anuke.mindustry.ui.Bar;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumePower;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
import java.io.DataInput;
|
import java.io.DataInput;
|
||||||
import java.io.DataOutput;
|
import java.io.DataOutput;
|
||||||
@@ -29,7 +30,7 @@ public class ImpactReactor extends PowerGenerator{
|
|||||||
|
|
||||||
protected int plasmas = 4;
|
protected int plasmas = 4;
|
||||||
protected float warmupSpeed = 0.001f;
|
protected float warmupSpeed = 0.001f;
|
||||||
protected float useTime = 60f;
|
protected float itemDuration = 60f;
|
||||||
protected int explosionRadius = 30;
|
protected int explosionRadius = 30;
|
||||||
protected int explosionDamage = 180;
|
protected int explosionDamage = 180;
|
||||||
|
|
||||||
@@ -51,12 +52,21 @@ public class ImpactReactor extends PowerGenerator{
|
|||||||
super.setBars();
|
super.setBars();
|
||||||
|
|
||||||
bars.add("poweroutput", entity -> new Bar(() ->
|
bars.add("poweroutput", entity -> new Bar(() ->
|
||||||
Core.bundle.format("blocks.poweroutput",
|
Core.bundle.format("bar.poweroutput",
|
||||||
Strings.toFixed(Math.max(entity.tile.block().getPowerProduction(entity.tile) - consumes.get(ConsumePower.class).powerPerTick, 0)*60 * entity.delta(), 1)),
|
Strings.fixed(Math.max(entity.block.getPowerProduction(entity.tile) - consumes.getPower().powerPerTick, 0)*60 * entity.delta(), 1)),
|
||||||
() -> Pal.powerBar,
|
() -> Pal.powerBar,
|
||||||
() -> ((GeneratorEntity)entity).productionEfficiency));
|
() -> ((GeneratorEntity)entity).productionEfficiency));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
if(hasItems){
|
||||||
|
stats.add(BlockStat.productionTime, itemDuration / 60f, StatUnit.seconds);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Tile tile){
|
public void update(Tile tile){
|
||||||
FusionReactorEntity entity = tile.entity();
|
FusionReactorEntity entity = tile.entity();
|
||||||
@@ -64,8 +74,8 @@ public class ImpactReactor extends PowerGenerator{
|
|||||||
if(entity.cons.valid()){
|
if(entity.cons.valid()){
|
||||||
entity.warmup = Mathf.lerpDelta(entity.warmup, 1f, warmupSpeed);
|
entity.warmup = Mathf.lerpDelta(entity.warmup, 1f, warmupSpeed);
|
||||||
|
|
||||||
if(entity.timer.get(timerUse, useTime)){
|
if(entity.timer.get(timerUse, itemDuration)){
|
||||||
entity.items.remove(consumes.item(), consumes.itemAmount());
|
entity.cons.trigger();
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
entity.warmup = Mathf.lerpDelta(entity.warmup, 0f, 0.01f);
|
entity.warmup = Mathf.lerpDelta(entity.warmup, 0f, 0.01f);
|
||||||
|
|||||||
@@ -1,19 +1,21 @@
|
|||||||
package io.anuke.mindustry.world.blocks.power;
|
package io.anuke.mindustry.world.blocks.power;
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.Color;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.content.Fx;
|
import io.anuke.mindustry.content.Fx;
|
||||||
|
import io.anuke.mindustry.entities.Effects;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItemFilter;
|
import io.anuke.mindustry.world.consumers.ConsumeItemFilter;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidFilter;
|
||||||
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.content;
|
import static io.anuke.mindustry.Vars.content;
|
||||||
import static io.anuke.mindustry.Vars.tilesize;
|
import static io.anuke.mindustry.Vars.tilesize;
|
||||||
@@ -44,11 +46,11 @@ public class ItemLiquidGenerator extends PowerGenerator{
|
|||||||
this.hasLiquids = hasLiquids;
|
this.hasLiquids = hasLiquids;
|
||||||
|
|
||||||
if(hasItems){
|
if(hasItems){
|
||||||
consumes.add(new ConsumeItemFilter(item -> getItemEfficiency(item) >= minItemEfficiency)).update(false).optional(true);
|
consumes.add(new ConsumeItemFilter(item -> getItemEfficiency(item) >= minItemEfficiency)).update(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(hasLiquids){
|
if(hasLiquids){
|
||||||
consumes.add(new ConsumeLiquidFilter(liquid -> getLiquidEfficiency(liquid) >= minLiquidEfficiency, 0.001f, true)).update(false).optional(true);
|
consumes.add(new ConsumeLiquidFilter(liquid -> getLiquidEfficiency(liquid) >= minLiquidEfficiency, maxLiquidGenerate)).update(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -60,6 +62,15 @@ public class ItemLiquidGenerator extends PowerGenerator{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
if(hasItems){
|
||||||
|
stats.add(BlockStat.productionTime, itemDuration / 60f, StatUnit.seconds);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Tile tile){
|
public void update(Tile tile){
|
||||||
ItemLiquidGeneratorEntity entity = tile.entity();
|
ItemLiquidGeneratorEntity entity = tile.entity();
|
||||||
|
|||||||
@@ -12,9 +12,15 @@ import io.anuke.mindustry.entities.Damage;
|
|||||||
import io.anuke.mindustry.entities.Effects;
|
import io.anuke.mindustry.entities.Effects;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.graphics.Pal;
|
import io.anuke.mindustry.graphics.Pal;
|
||||||
|
import io.anuke.mindustry.type.Item;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.ui.Bar;
|
import io.anuke.mindustry.ui.Bar;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeItems;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
import java.io.DataInput;
|
import java.io.DataInput;
|
||||||
import java.io.DataOutput;
|
import java.io.DataOutput;
|
||||||
@@ -29,7 +35,7 @@ public class NuclearReactor extends PowerGenerator{
|
|||||||
|
|
||||||
protected Color coolColor = new Color(1, 1, 1, 0f);
|
protected Color coolColor = new Color(1, 1, 1, 0f);
|
||||||
protected Color hotColor = Color.valueOf("ff9575a3");
|
protected Color hotColor = Color.valueOf("ff9575a3");
|
||||||
protected int fuelUseTime = 120; //time to consume 1 fuel
|
protected int itemDuration = 120; //time to consume 1 fuel
|
||||||
protected float heating = 0.01f; //heating per frame * fullness
|
protected float heating = 0.01f; //heating per frame * fullness
|
||||||
protected float smokeThreshold = 0.3f; //threshold at which block starts smoking
|
protected float smokeThreshold = 0.3f; //threshold at which block starts smoking
|
||||||
protected int explosionRadius = 19;
|
protected int explosionRadius = 19;
|
||||||
@@ -47,6 +53,15 @@ public class NuclearReactor extends PowerGenerator{
|
|||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
if(hasItems){
|
||||||
|
stats.add(BlockStat.productionTime, itemDuration / 60f, StatUnit.seconds);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void load(){
|
public void load(){
|
||||||
super.load();
|
super.load();
|
||||||
@@ -58,27 +73,30 @@ public class NuclearReactor extends PowerGenerator{
|
|||||||
@Override
|
@Override
|
||||||
public void setBars(){
|
public void setBars(){
|
||||||
super.setBars();
|
super.setBars();
|
||||||
bars.add("heat", entity -> new Bar("blocks.heat", Pal.lightOrange, () -> ((NuclearReactorEntity)entity).heat));
|
bars.add("heat", entity -> new Bar("bar.heat", Pal.lightOrange, () -> ((NuclearReactorEntity)entity).heat));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Tile tile){
|
public void update(Tile tile){
|
||||||
NuclearReactorEntity entity = tile.entity();
|
NuclearReactorEntity entity = tile.entity();
|
||||||
|
|
||||||
int fuel = entity.items.get(consumes.item());
|
ConsumeLiquid cliquid = consumes.get(ConsumeType.liquid);
|
||||||
|
Item item = consumes.<ConsumeItems>get(ConsumeType.item).items[0].item;
|
||||||
|
|
||||||
|
int fuel = entity.items.get(item);
|
||||||
float fullness = (float) fuel / itemCapacity;
|
float fullness = (float) fuel / itemCapacity;
|
||||||
entity.productionEfficiency = fullness;
|
entity.productionEfficiency = fullness;
|
||||||
|
|
||||||
if(fuel > 0){
|
if(fuel > 0){
|
||||||
entity.heat += fullness * heating * Math.min(entity.delta(), 4f);
|
entity.heat += fullness * heating * Math.min(entity.delta(), 4f);
|
||||||
|
|
||||||
if(entity.timer.get(timerFuel, fuelUseTime)){
|
if(entity.timer.get(timerFuel, itemDuration)){
|
||||||
entity.cons.trigger();
|
entity.cons.trigger();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Liquid liquid = consumes.liquid();
|
Liquid liquid = cliquid.liquid;
|
||||||
float liquidAmount = consumes.liquidAmount();
|
float liquidAmount = cliquid.amount;
|
||||||
|
|
||||||
if(entity.heat > 0){
|
if(entity.heat > 0){
|
||||||
float maxUsed = Math.min(Math.min(entity.liquids.get(liquid), entity.heat / coolantPower), liquidAmount * entity.delta());
|
float maxUsed = Math.min(Math.min(entity.liquids.get(liquid), entity.heat / coolantPower), liquidAmount * entity.delta());
|
||||||
@@ -109,7 +127,7 @@ public class NuclearReactor extends PowerGenerator{
|
|||||||
|
|
||||||
NuclearReactorEntity entity = tile.entity();
|
NuclearReactorEntity entity = tile.entity();
|
||||||
|
|
||||||
int fuel = entity.items.get(consumes.item());
|
int fuel = entity.items.get(consumes.<ConsumeItems>get(ConsumeType.item).items[0].item);
|
||||||
|
|
||||||
if(fuel < 5 && entity.heat < 0.5f) return;
|
if(fuel < 5 && entity.heat < 0.5f) return;
|
||||||
|
|
||||||
|
|||||||
@@ -37,10 +37,10 @@ public class PowerGenerator extends PowerDistributor{
|
|||||||
public void setBars(){
|
public void setBars(){
|
||||||
super.setBars();
|
super.setBars();
|
||||||
|
|
||||||
if(hasPower && outputsPower && !consumes.has(ConsumePower.class)){
|
if(hasPower && outputsPower && !consumes.hasPower()){
|
||||||
bars.add("power", entity -> new Bar(() ->
|
bars.add("power", entity -> new Bar(() ->
|
||||||
Core.bundle.format("blocks.poweroutput",
|
Core.bundle.format("bar.poweroutput",
|
||||||
Strings.toFixed(entity.tile.block().getPowerProduction(entity.tile)*60 * entity.timeScale, 1)),
|
Strings.fixed(entity.block.getPowerProduction(entity.tile)*60 * entity.timeScale, 1)),
|
||||||
() -> Pal.powerBar,
|
() -> Pal.powerBar,
|
||||||
() -> ((GeneratorEntity)entity).productionEfficiency));
|
() -> ((GeneratorEntity)entity).productionEfficiency));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,8 +54,8 @@ public class PowerGraph{
|
|||||||
float powerNeeded = 0f;
|
float powerNeeded = 0f;
|
||||||
for(Tile consumer : consumers){
|
for(Tile consumer : consumers){
|
||||||
Consumers consumes = consumer.block().consumes;
|
Consumers consumes = consumer.block().consumes;
|
||||||
if(consumes.has(ConsumePower.class)){
|
if(consumes.hasPower()){
|
||||||
ConsumePower consumePower = consumes.get(ConsumePower.class);
|
ConsumePower consumePower = consumes.getPower();
|
||||||
if(otherConsumersAreValid(consumer, consumePower)){
|
if(otherConsumersAreValid(consumer, consumePower)){
|
||||||
powerNeeded += consumePower.requestedPower(consumer.block(), consumer.entity) * consumer.entity.delta();
|
powerNeeded += consumePower.requestedPower(consumer.block(), consumer.entity) * consumer.entity.delta();
|
||||||
}
|
}
|
||||||
@@ -68,8 +68,8 @@ public class PowerGraph{
|
|||||||
float totalAccumulator = 0f;
|
float totalAccumulator = 0f;
|
||||||
for(Tile battery : batteries){
|
for(Tile battery : batteries){
|
||||||
Consumers consumes = battery.block().consumes;
|
Consumers consumes = battery.block().consumes;
|
||||||
if(consumes.has(ConsumePower.class)){
|
if(consumes.hasPower()){
|
||||||
totalAccumulator += battery.entity.power.satisfaction * consumes.get(ConsumePower.class).powerCapacity;
|
totalAccumulator += battery.entity.power.satisfaction * consumes.getPower().powerCapacity;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return totalAccumulator;
|
return totalAccumulator;
|
||||||
@@ -79,8 +79,8 @@ public class PowerGraph{
|
|||||||
float totalCapacity = 0f;
|
float totalCapacity = 0f;
|
||||||
for(Tile battery : batteries){
|
for(Tile battery : batteries){
|
||||||
Consumers consumes = battery.block().consumes;
|
Consumers consumes = battery.block().consumes;
|
||||||
if(consumes.has(ConsumePower.class)){
|
if(consumes.hasPower()){
|
||||||
totalCapacity += consumes.get(ConsumePower.class).requestedPower(battery.block(), battery.entity) * battery.entity.delta();
|
totalCapacity += consumes.getPower().requestedPower(battery.block(), battery.entity) * battery.entity.delta();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return totalCapacity;
|
return totalCapacity;
|
||||||
@@ -94,8 +94,8 @@ public class PowerGraph{
|
|||||||
float consumedPowerPercentage = Math.min(1.0f, needed / stored);
|
float consumedPowerPercentage = Math.min(1.0f, needed / stored);
|
||||||
for(Tile battery : batteries){
|
for(Tile battery : batteries){
|
||||||
Consumers consumes = battery.block().consumes;
|
Consumers consumes = battery.block().consumes;
|
||||||
if(consumes.has(ConsumePower.class)){
|
if(consumes.hasPower()){
|
||||||
ConsumePower consumePower = consumes.get(ConsumePower.class);
|
ConsumePower consumePower = consumes.getPower();
|
||||||
if(consumePower.powerCapacity > 0f){
|
if(consumePower.powerCapacity > 0f){
|
||||||
battery.entity.power.satisfaction = Math.max(0.0f, battery.entity.power.satisfaction - consumedPowerPercentage);
|
battery.entity.power.satisfaction = Math.max(0.0f, battery.entity.power.satisfaction - consumedPowerPercentage);
|
||||||
}
|
}
|
||||||
@@ -110,8 +110,8 @@ public class PowerGraph{
|
|||||||
|
|
||||||
for(Tile battery : batteries){
|
for(Tile battery : batteries){
|
||||||
Consumers consumes = battery.block().consumes;
|
Consumers consumes = battery.block().consumes;
|
||||||
if(consumes.has(ConsumePower.class)){
|
if(consumes.hasPower()){
|
||||||
ConsumePower consumePower = consumes.get(ConsumePower.class);
|
ConsumePower consumePower = consumes.getPower();
|
||||||
if(consumePower.powerCapacity > 0f){
|
if(consumePower.powerCapacity > 0f){
|
||||||
float additionalPowerPercentage = Math.min(1.0f, excess / consumePower.powerCapacity);
|
float additionalPowerPercentage = Math.min(1.0f, excess / consumePower.powerCapacity);
|
||||||
battery.entity.power.satisfaction = Math.min(1.0f, battery.entity.power.satisfaction + additionalPowerPercentage);
|
battery.entity.power.satisfaction = Math.min(1.0f, battery.entity.power.satisfaction + additionalPowerPercentage);
|
||||||
@@ -126,8 +126,8 @@ public class PowerGraph{
|
|||||||
float coverage = Mathf.isZero(needed) ? 1f : Math.min(1, produced / needed);
|
float coverage = Mathf.isZero(needed) ? 1f : Math.min(1, produced / needed);
|
||||||
for(Tile consumer : consumers){
|
for(Tile consumer : consumers){
|
||||||
Consumers consumes = consumer.block().consumes;
|
Consumers consumes = consumer.block().consumes;
|
||||||
if(consumes.has(ConsumePower.class)){
|
if(consumes.hasPower()){
|
||||||
ConsumePower consumePower = consumes.get(ConsumePower.class);
|
ConsumePower consumePower = consumes.getPower();
|
||||||
//currently satisfies power even if it's not required yet
|
//currently satisfies power even if it's not required yet
|
||||||
if(consumePower.isBuffered){
|
if(consumePower.isBuffered){
|
||||||
if(!Mathf.isZero(consumePower.powerCapacity)){
|
if(!Mathf.isZero(consumePower.powerCapacity)){
|
||||||
@@ -176,7 +176,7 @@ public class PowerGraph{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void add(Tile tile){
|
public void add(Tile tile){
|
||||||
if(tile.block().consumes.has(ConsumePower.class) && !tile.block().consumes.get(ConsumePower.class).isBuffered){
|
if(tile.block().consumes.hasPower() && !tile.block().consumes.getPower().isBuffered){
|
||||||
//reset satisfaction to zero in case of direct consumer. There is no reason to clear power from buffered consumers.
|
//reset satisfaction to zero in case of direct consumer. There is no reason to clear power from buffered consumers.
|
||||||
tile.entity.power.satisfaction = 0.0f;
|
tile.entity.power.satisfaction = 0.0f;
|
||||||
}
|
}
|
||||||
@@ -184,7 +184,7 @@ public class PowerGraph{
|
|||||||
tile.entity.power.graph = this;
|
tile.entity.power.graph = this;
|
||||||
all.add(tile);
|
all.add(tile);
|
||||||
|
|
||||||
if(tile.block().outputsPower && tile.block().consumesPower && !tile.block().consumes.get(ConsumePower.class).isBuffered){
|
if(tile.block().outputsPower && tile.block().consumesPower && !tile.block().consumes.getPower().isBuffered){
|
||||||
producers.add(tile);
|
producers.add(tile);
|
||||||
consumers.add(tile);
|
consumers.add(tile);
|
||||||
}else if(tile.block().outputsPower && tile.block().consumesPower){
|
}else if(tile.block().outputsPower && tile.block().consumesPower){
|
||||||
@@ -259,7 +259,7 @@ public class PowerGraph{
|
|||||||
|
|
||||||
private boolean otherConsumersAreValid(Tile tile, Consume consumePower){
|
private boolean otherConsumersAreValid(Tile tile, Consume consumePower){
|
||||||
for(Consume cons : tile.block().consumes.all()){
|
for(Consume cons : tile.block().consumes.all()){
|
||||||
if(cons != consumePower && !cons.isOptional() && !cons.valid(tile.block(), tile.entity())){
|
if(cons != consumePower && !cons.isOptional() && !cons.valid(tile.entity())){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -92,8 +92,8 @@ public class PowerNode extends PowerBlock{
|
|||||||
public void setBars(){
|
public void setBars(){
|
||||||
super.setBars();
|
super.setBars();
|
||||||
bars.add("power", entity -> new Bar(() ->
|
bars.add("power", entity -> new Bar(() ->
|
||||||
Core.bundle.format("blocks.powerbalance",
|
Core.bundle.format("bar.powerbalance",
|
||||||
((entity.power.graph.getPowerBalance() >= 0 ? "+" : "") + Strings.toFixed(entity.power.graph.getPowerBalance()*60, 1))),
|
((entity.power.graph.getPowerBalance() >= 0 ? "+" : "") + Strings.fixed(entity.power.graph.getPowerBalance()*60, 1))),
|
||||||
() -> Pal.powerBar,
|
() -> Pal.powerBar,
|
||||||
() -> Mathf.clamp(entity.power.graph.getPowerProduced() / entity.power.graph.getPowerNeeded())));
|
() -> Mathf.clamp(entity.power.graph.getPowerProduced() / entity.power.graph.getPowerNeeded())));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ public class ThermalGenerator extends PowerGenerator{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void drawPlace(int x, int y, int rotation, boolean valid){
|
public void drawPlace(int x, int y, int rotation, boolean valid){
|
||||||
drawPlaceText(Core.bundle.formatDouble("blocks.efficiency", sumAttribute(Attribute.heat, x, y)*100, 1), x, y, valid);
|
drawPlaceText(Core.bundle.formatFloat("bar.efficiency", sumAttribute(Attribute.heat, x, y)*100, 1), x, y, valid);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,20 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.power;
|
|
||||||
|
|
||||||
import io.anuke.mindustry.type.Liquid;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
|
||||||
|
|
||||||
public class TurbineGenerator extends BurnerGenerator{
|
|
||||||
|
|
||||||
public TurbineGenerator(String name){
|
|
||||||
super(name);
|
|
||||||
singleLiquid = false;
|
|
||||||
|
|
||||||
consumes.require(ConsumeLiquid.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
|
||||||
return (liquid == consumes.liquid() && tile.entity.liquids.get(consumes.liquid()) < liquidCapacity);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,49 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
|
||||||
import io.anuke.arc.graphics.Color;
|
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.blocks.production.GenericCrafter.GenericCrafterEntity;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
|
||||||
|
|
||||||
public class Compressor extends PowerCrafter{
|
|
||||||
protected TextureRegion liquidRegion, topRegion;
|
|
||||||
protected TextureRegion[] frameRegions;
|
|
||||||
|
|
||||||
public Compressor(String name){
|
|
||||||
super(name);
|
|
||||||
hasLiquids = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void load(){
|
|
||||||
super.load();
|
|
||||||
|
|
||||||
frameRegions = new TextureRegion[3];
|
|
||||||
for(int i = 0; i < 3; i++){
|
|
||||||
frameRegions[i] = Core.atlas.find(name + "-frame" + i);
|
|
||||||
}
|
|
||||||
|
|
||||||
liquidRegion = Core.atlas.find(name + "-liquid");
|
|
||||||
topRegion = Core.atlas.find(name + "-top");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
GenericCrafterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
Draw.rect(region, tile.drawx(), tile.drawy());
|
|
||||||
Draw.rect(frameRegions[(int) Mathf.absin(entity.totalProgress, 5f, 2.999f)], tile.drawx(), tile.drawy());
|
|
||||||
Draw.color(Color.CLEAR, tile.entity.liquids.current().color, tile.entity.liquids.total() / liquidCapacity);
|
|
||||||
Draw.rect(liquidRegion, tile.drawx(), tile.drawy());
|
|
||||||
Draw.color();
|
|
||||||
Draw.rect(topRegion, tile.drawx(), tile.drawy());
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TextureRegion[] generateIcons(){
|
|
||||||
return new TextureRegion[]{Core.atlas.find(name), Core.atlas.find(name + "-top")};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -53,7 +53,7 @@ public class Cultivator extends GenericCrafter{
|
|||||||
public void setBars(){
|
public void setBars(){
|
||||||
super.setBars();
|
super.setBars();
|
||||||
bars.add("multiplier", entity -> new Bar(() ->
|
bars.add("multiplier", entity -> new Bar(() ->
|
||||||
Core.bundle.formatDouble("blocks.efficiency",
|
Core.bundle.formatFloat("bar.efficiency",
|
||||||
((((CultivatorEntity)entity).boost + 1f) * ((CultivatorEntity)entity).warmup)*100f,1),
|
((((CultivatorEntity)entity).boost + 1f) * ((CultivatorEntity)entity).warmup)*100f,1),
|
||||||
() -> Pal.ammo,
|
() -> Pal.ammo,
|
||||||
() -> ((CultivatorEntity)entity).warmup));
|
() -> ((CultivatorEntity)entity).warmup));
|
||||||
@@ -61,7 +61,7 @@ public class Cultivator extends GenericCrafter{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void drawPlace(int x, int y, int rotation, boolean valid){
|
public void drawPlace(int x, int y, int rotation, boolean valid){
|
||||||
drawPlaceText(Core.bundle.formatDouble("blocks.efficiency", (1+sumAttribute(Attribute.spores, x, y))*100, 1), x, y, valid);
|
drawPlaceText(Core.bundle.formatFloat("bar.efficiency", (1+sumAttribute(Attribute.spores, x, y))*100, 1), x, y, valid);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -3,17 +3,16 @@ package io.anuke.mindustry.world.blocks.production;
|
|||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
import io.anuke.arc.collection.Array;
|
import io.anuke.arc.collection.Array;
|
||||||
import io.anuke.arc.collection.ObjectIntMap;
|
import io.anuke.arc.collection.ObjectIntMap;
|
||||||
import io.anuke.arc.util.Strings;
|
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.mindustry.entities.Effects.Effect;
|
|
||||||
import io.anuke.arc.graphics.Blending;
|
import io.anuke.arc.graphics.Blending;
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.Color;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
|
import io.anuke.arc.util.Strings;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.content.Fx;
|
import io.anuke.mindustry.content.Fx;
|
||||||
import io.anuke.mindustry.content.Liquids;
|
import io.anuke.mindustry.entities.Effects;
|
||||||
|
import io.anuke.mindustry.entities.Effects.Effect;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.graphics.Layer;
|
import io.anuke.mindustry.graphics.Layer;
|
||||||
import io.anuke.mindustry.graphics.Pal;
|
import io.anuke.mindustry.graphics.Pal;
|
||||||
@@ -22,7 +21,6 @@ import io.anuke.mindustry.type.ItemType;
|
|||||||
import io.anuke.mindustry.ui.Bar;
|
import io.anuke.mindustry.ui.Bar;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockGroup;
|
import io.anuke.mindustry.world.meta.BlockGroup;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
@@ -33,7 +31,6 @@ public class Drill extends Block{
|
|||||||
protected final static float hardnessDrillMultiplier = 50f;
|
protected final static float hardnessDrillMultiplier = 50f;
|
||||||
protected final int timerDump = timers++;
|
protected final int timerDump = timers++;
|
||||||
|
|
||||||
protected final Array<Tile> drawTiles = new Array<>();
|
|
||||||
protected final ObjectIntMap<Item> oreCount = new ObjectIntMap<>();
|
protected final ObjectIntMap<Item> oreCount = new ObjectIntMap<>();
|
||||||
protected final Array<Item> itemArray = new Array<>();
|
protected final Array<Item> itemArray = new Array<>();
|
||||||
|
|
||||||
@@ -41,8 +38,6 @@ public class Drill extends Block{
|
|||||||
protected int tier;
|
protected int tier;
|
||||||
/**Base time to drill one ore, in frames.*/
|
/**Base time to drill one ore, in frames.*/
|
||||||
protected float drillTime = 300;
|
protected float drillTime = 300;
|
||||||
/**Whether the liquid is required to drill. If false, then it will be used as a speed booster.*/
|
|
||||||
protected boolean liquidRequired = false;
|
|
||||||
/**How many times faster the drill will progress when boosted by liquid.*/
|
/**How many times faster the drill will progress when boosted by liquid.*/
|
||||||
protected float liquidBoostIntensity = 1.6f;
|
protected float liquidBoostIntensity = 1.6f;
|
||||||
/**Speed at which the drill speeds up.*/
|
/**Speed at which the drill speeds up.*/
|
||||||
@@ -75,8 +70,6 @@ public class Drill extends Block{
|
|||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
liquidCapacity = 5f;
|
liquidCapacity = 5f;
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
|
|
||||||
consumes.liquid(Liquids.water, 0.05f).optional(true);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -86,7 +79,7 @@ public class Drill extends Block{
|
|||||||
bars.add("drillspeed", e -> {
|
bars.add("drillspeed", e -> {
|
||||||
DrillEntity entity = (DrillEntity)e;
|
DrillEntity entity = (DrillEntity)e;
|
||||||
|
|
||||||
return new Bar(() -> Core.bundle.format("blocks.outputspeed", Strings.toFixed(entity.lastDrillSpeed * 60 * entity.timeScale, 2)), () -> Pal.ammo, () -> entity.warmup);
|
return new Bar(() -> Core.bundle.format("bar.drillspeed", Strings.fixed(entity.lastDrillSpeed * 60 * entity.timeScale, 2)), () -> Pal.ammo, () -> entity.warmup);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -162,6 +155,7 @@ public class Drill extends Block{
|
|||||||
});
|
});
|
||||||
|
|
||||||
stats.add(BlockStat.drillSpeed, 60f / drillTime * size * size, StatUnit.itemsSecond);
|
stats.add(BlockStat.drillSpeed, 60f / drillTime * size * size, StatUnit.itemsSecond);
|
||||||
|
stats.add(BlockStat.boostEffect, liquidBoostIntensity, StatUnit.timesSpeed);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -182,8 +176,13 @@ public class Drill extends Block{
|
|||||||
itemArray.add(item);
|
itemArray.add(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
itemArray.sort((item1, item2) -> Integer.compare(oreCount.get(item1, 0), oreCount.get(item2, 0)));
|
itemArray.sort((item1, item2) -> {
|
||||||
itemArray.sort((item1, item2) -> Boolean.compare(item1.type == ItemType.material, item2.type == ItemType.material));
|
int type = Boolean.compare(item1.type == ItemType.material, item2.type == ItemType.material);
|
||||||
|
if(type != 0) return type;
|
||||||
|
int count = Integer.compare(oreCount.get(item1, 0), oreCount.get(item2, 0));
|
||||||
|
if(count != 0) return count;
|
||||||
|
return Integer.compare(item1.id, item2.id);
|
||||||
|
});
|
||||||
|
|
||||||
if(itemArray.size == 0){
|
if(itemArray.size == 0){
|
||||||
return;
|
return;
|
||||||
@@ -195,8 +194,8 @@ public class Drill extends Block{
|
|||||||
|
|
||||||
float totalHardness = entity.dominantItems * entity.dominantItem.hardness;
|
float totalHardness = entity.dominantItems * entity.dominantItem.hardness;
|
||||||
|
|
||||||
if(entity.timer.get(timerDump, 15)){
|
if(entity.timer.get(timerDump, 5)){
|
||||||
tryDump(tile);
|
tryDump(tile, entity.dominantItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
entity.drillTime += entity.warmup * entity.delta();
|
entity.drillTime += entity.warmup * entity.delta();
|
||||||
@@ -205,9 +204,10 @@ public class Drill extends Block{
|
|||||||
|
|
||||||
float speed = 1f;
|
float speed = 1f;
|
||||||
|
|
||||||
if(entity.consumed(ConsumeLiquid.class) && !liquidRequired){
|
if(entity.cons.optionalValid()){
|
||||||
speed = liquidBoostIntensity;
|
speed = liquidBoostIntensity;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(hasPower){
|
if(hasPower){
|
||||||
speed *= entity.power.satisfaction; // Drill slower when not at full power
|
speed *= entity.power.satisfaction; // Drill slower when not at full power
|
||||||
}
|
}
|
||||||
@@ -270,14 +270,14 @@ public class Drill extends Block{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static class DrillEntity extends TileEntity{
|
public static class DrillEntity extends TileEntity{
|
||||||
public float progress;
|
float progress;
|
||||||
public int index;
|
int index;
|
||||||
public float warmup;
|
float warmup;
|
||||||
public float drillTime;
|
float drillTime;
|
||||||
public float lastDrillSpeed;
|
float lastDrillSpeed;
|
||||||
|
|
||||||
public int dominantItems;
|
int dominantItems;
|
||||||
public Item dominantItem;
|
Item dominantItem;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
package io.anuke.mindustry.world.blocks.production;
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Item;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItem;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
public class Fracker extends SolidPump{
|
public class Fracker extends SolidPump{
|
||||||
protected final float itemUseTime = 100f;
|
protected final float itemUseTime = 100f;
|
||||||
@@ -18,9 +18,13 @@ public class Fracker extends SolidPump{
|
|||||||
public Fracker(String name){
|
public Fracker(String name){
|
||||||
super(name);
|
super(name);
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
singleLiquid = false;
|
}
|
||||||
|
|
||||||
consumes.require(ConsumeItem.class);
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
stats.add(BlockStat.productionTime, itemUseTime / 60f, StatUnit.seconds);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -55,14 +59,13 @@ public class Fracker extends SolidPump{
|
|||||||
@Override
|
@Override
|
||||||
public void update(Tile tile){
|
public void update(Tile tile){
|
||||||
FrackerEntity entity = tile.entity();
|
FrackerEntity entity = tile.entity();
|
||||||
Item item = consumes.item();
|
|
||||||
|
|
||||||
while(entity.accumulator >= itemUseTime && entity.items.has(item, 1)){
|
if(entity.cons.valid() && entity.accumulator < itemUseTime){
|
||||||
entity.items.remove(item, 1);
|
if(entity.accumulator >= itemUseTime){
|
||||||
|
entity.cons.trigger();
|
||||||
entity.accumulator -= itemUseTime;
|
entity.accumulator -= itemUseTime;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(entity.cons.valid() && entity.accumulator < itemUseTime){
|
|
||||||
super.update(tile);
|
super.update(tile);
|
||||||
entity.accumulator += entity.delta() * entity.power.satisfaction;
|
entity.accumulator += entity.delta() * entity.power.satisfaction;
|
||||||
}else{
|
}else{
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
package io.anuke.mindustry.world.blocks.production;
|
||||||
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.function.Consumer;
|
||||||
|
import io.anuke.arc.function.Supplier;
|
||||||
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.Time;
|
||||||
import io.anuke.mindustry.content.Fx;
|
import io.anuke.mindustry.content.Fx;
|
||||||
@@ -8,8 +10,12 @@ import io.anuke.mindustry.entities.Effects;
|
|||||||
import io.anuke.mindustry.entities.Effects.Effect;
|
import io.anuke.mindustry.entities.Effects.Effect;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
|
import io.anuke.mindustry.type.ItemStack;
|
||||||
|
import io.anuke.mindustry.type.LiquidStack;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidBase;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
@@ -20,58 +26,71 @@ import java.io.IOException;
|
|||||||
public class GenericCrafter extends Block{
|
public class GenericCrafter extends Block{
|
||||||
protected final int timerDump = timers++;
|
protected final int timerDump = timers++;
|
||||||
|
|
||||||
protected Item output;
|
protected ItemStack outputItem;
|
||||||
|
protected LiquidStack outputLiquid;
|
||||||
|
|
||||||
protected float craftTime = 80;
|
protected float craftTime = 80;
|
||||||
protected Effect craftEffect = Fx.purify;
|
protected Effect craftEffect = Fx.purify;
|
||||||
protected Effect updateEffect = Fx.none;
|
protected Effect updateEffect = Fx.none;
|
||||||
protected float updateEffectChance = 0.04f;
|
protected float updateEffectChance = 0.04f;
|
||||||
|
|
||||||
|
protected Consumer<Tile> drawer = null;
|
||||||
|
protected Supplier<TextureRegion[]> drawIcons = null;
|
||||||
|
|
||||||
public GenericCrafter(String name){
|
public GenericCrafter(String name){
|
||||||
super(name);
|
super(name);
|
||||||
update = true;
|
update = true;
|
||||||
solid = true;
|
solid = true;
|
||||||
|
hasItems = true;
|
||||||
health = 60;
|
health = 60;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void init(){
|
public void setStats(){
|
||||||
super.init();
|
if(consumes.has(ConsumeType.liquid)){
|
||||||
|
ConsumeLiquidBase cons = consumes.get(ConsumeType.liquid);
|
||||||
produces.set(output);
|
cons.timePeriod = craftTime;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setStats(){
|
|
||||||
super.setStats();
|
super.setStats();
|
||||||
stats.add(BlockStat.craftSpeed, 60f / craftTime, StatUnit.itemsSecond);
|
stats.add(BlockStat.productionTime, craftTime / 60f, StatUnit.seconds);
|
||||||
stats.add(BlockStat.outputItem, output);
|
|
||||||
|
if(outputItem != null){
|
||||||
|
stats.add(BlockStat.output, outputItem);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(outputLiquid != null){
|
||||||
|
stats.add(BlockStat.output, outputLiquid.liquid, outputLiquid.amount, false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void draw(Tile tile){
|
public void draw(Tile tile){
|
||||||
Draw.rect(name, tile.drawx(), tile.drawy());
|
if(drawer == null){
|
||||||
|
super.draw(tile);
|
||||||
|
}else{
|
||||||
|
drawer.accept(tile);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(!hasLiquids) return;
|
@Override
|
||||||
|
public TextureRegion[] generateIcons(){
|
||||||
Draw.color(tile.entity.liquids.current().color);
|
return drawIcons == null ? super.generateIcons() : drawIcons.get();
|
||||||
Draw.alpha(tile.entity.liquids.total() / liquidCapacity);
|
|
||||||
Draw.rect("blank", tile.drawx(), tile.drawy(), 2, 2);
|
|
||||||
Draw.color();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Tile tile){
|
public void update(Tile tile){
|
||||||
GenericCrafterEntity entity = tile.entity();
|
GenericCrafterEntity entity = tile.entity();
|
||||||
|
|
||||||
if(entity.cons.valid() && tile.entity.items.get(output) < itemCapacity){
|
if(entity.cons.valid()){
|
||||||
|
|
||||||
entity.progress += getProgressIncrease(entity, craftTime);
|
entity.progress += getProgressIncrease(entity, craftTime);
|
||||||
entity.totalProgress += entity.delta();
|
entity.totalProgress += entity.delta();
|
||||||
entity.warmup = Mathf.lerpDelta(entity.warmup, 1f, 0.02f);
|
entity.warmup = Mathf.lerpDelta(entity.warmup, 1f, 0.02f);
|
||||||
|
|
||||||
if(Mathf.chance(Time.delta() * updateEffectChance))
|
if(Mathf.chance(Time.delta() * updateEffectChance)){
|
||||||
Effects.effect(updateEffect, entity.x + Mathf.range(size * 4f), entity.y + Mathf.range(size * 4));
|
Effects.effect(updateEffect, entity.x + Mathf.range(size * 4f), entity.y + Mathf.range(size * 4));
|
||||||
|
}
|
||||||
}else{
|
}else{
|
||||||
entity.warmup = Mathf.lerp(entity.warmup, 0f, 0.02f);
|
entity.warmup = Mathf.lerp(entity.warmup, 0f, 0.02f);
|
||||||
}
|
}
|
||||||
@@ -79,14 +98,28 @@ public class GenericCrafter extends Block{
|
|||||||
if(entity.progress >= 1f){
|
if(entity.progress >= 1f){
|
||||||
entity.cons.trigger();
|
entity.cons.trigger();
|
||||||
|
|
||||||
useContent(tile, output);
|
if(outputItem != null){
|
||||||
offloadNear(tile, output);
|
useContent(tile, outputItem.item);
|
||||||
|
for(int i = 0; i < outputItem.amount; i++){
|
||||||
|
offloadNear(tile, outputItem.item);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(outputLiquid != null){
|
||||||
|
useContent(tile, outputLiquid.liquid);
|
||||||
|
handleLiquid(tile, tile, outputLiquid.liquid, outputLiquid.amount);
|
||||||
|
}
|
||||||
|
|
||||||
Effects.effect(craftEffect, tile.drawx(), tile.drawy());
|
Effects.effect(craftEffect, tile.drawx(), tile.drawy());
|
||||||
entity.progress = 0f;
|
entity.progress = 0f;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(tile.entity.timer.get(timerDump, 5)){
|
if(outputItem != null && tile.entity.timer.get(timerDump, 5)){
|
||||||
tryDump(tile, output);
|
tryDump(tile, outputItem.item);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(outputLiquid != null){
|
||||||
|
tryDumpLiquid(tile, outputLiquid.liquid);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,50 @@
|
|||||||
|
package io.anuke.mindustry.world.blocks.production;
|
||||||
|
|
||||||
|
import io.anuke.arc.Core;
|
||||||
|
import io.anuke.arc.graphics.Color;
|
||||||
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
|
import io.anuke.arc.graphics.g2d.Fill;
|
||||||
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
|
import io.anuke.arc.math.Mathf;
|
||||||
|
import io.anuke.arc.util.Time;
|
||||||
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
|
||||||
|
/**A GenericCrafter with a new glowing region drawn on top.*/
|
||||||
|
public class GenericSmelter extends GenericCrafter{
|
||||||
|
protected Color flameColor = Color.valueOf("ffc999");
|
||||||
|
protected TextureRegion topRegion;
|
||||||
|
|
||||||
|
public GenericSmelter(String name){
|
||||||
|
super(name);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void load(){
|
||||||
|
super.load();
|
||||||
|
topRegion = Core.atlas.find(name + "-top");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void draw(Tile tile){
|
||||||
|
super.draw(tile);
|
||||||
|
|
||||||
|
GenericCrafterEntity entity = tile.entity();
|
||||||
|
|
||||||
|
//draw glowing center
|
||||||
|
if(entity.warmup > 0f && flameColor.a > 0.001f){
|
||||||
|
float g = 0.3f;
|
||||||
|
float r = 0.06f;
|
||||||
|
float cr = Mathf.random(0.1f);
|
||||||
|
|
||||||
|
Draw.alpha(((1f - g) + Mathf.absin(Time.time(), 8f, g) + Mathf.random(r) - r) * entity.warmup);
|
||||||
|
|
||||||
|
Draw.tint(flameColor);
|
||||||
|
Fill.circle(tile.drawx(), tile.drawy(), 3f + Mathf.absin(Time.time(), 5f, 2f) + cr);
|
||||||
|
Draw.color(1f, 1f, 1f, entity.warmup);
|
||||||
|
Draw.rect(topRegion, tile.drawx(), tile.drawy());
|
||||||
|
Fill.circle(tile.drawx(), tile.drawy(), 1.9f + Mathf.absin(Time.time(), 5f, 1f) + cr);
|
||||||
|
|
||||||
|
Draw.color();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,93 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
|
||||||
import io.anuke.mindustry.type.Liquid;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.blocks.LiquidBlock;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
|
||||||
import io.anuke.mindustry.world.modules.LiquidModule;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
|
|
||||||
public class LiquidMixer extends LiquidBlock{
|
|
||||||
protected Liquid outputLiquid;
|
|
||||||
protected float liquidPerItem = 50f;
|
|
||||||
|
|
||||||
public LiquidMixer(String name){
|
|
||||||
super(name);
|
|
||||||
hasItems = true;
|
|
||||||
rotate = false;
|
|
||||||
solid = true;
|
|
||||||
singleLiquid = false;
|
|
||||||
outputsLiquid = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void init(){
|
|
||||||
super.init();
|
|
||||||
|
|
||||||
produces.set(outputLiquid);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setStats(){
|
|
||||||
super.setStats();
|
|
||||||
|
|
||||||
stats.add(BlockStat.liquidOutput, outputLiquid);
|
|
||||||
stats.add(BlockStat.liquidOutputSpeed, 60f * consumes.get(ConsumeLiquid.class).used(), StatUnit.liquidSecond);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean shouldConsume(Tile tile){
|
|
||||||
return tile.entity.liquids.get(outputLiquid) < liquidCapacity;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void update(Tile tile){
|
|
||||||
LiquidMixerEntity entity = tile.entity();
|
|
||||||
|
|
||||||
if(tile.entity.cons.valid()){
|
|
||||||
float use = Math.min(consumes.get(ConsumeLiquid.class).used() * entity.delta(), liquidCapacity - entity.liquids.get(outputLiquid));
|
|
||||||
if(hasPower){
|
|
||||||
use *= entity.power.satisfaction; // Produce less liquid if power is not maxed
|
|
||||||
}
|
|
||||||
entity.accumulator += use;
|
|
||||||
entity.liquids.add(outputLiquid, use);
|
|
||||||
for(int i = 0; i < (int) (entity.accumulator / liquidPerItem); i++){
|
|
||||||
if(!entity.items.has(consumes.item())) break;
|
|
||||||
entity.items.remove(consumes.item(), 1);
|
|
||||||
entity.accumulator -= liquidPerItem;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
tryDumpLiquid(tile, outputLiquid);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
LiquidModule mod = tile.entity.liquids;
|
|
||||||
|
|
||||||
int rotation = rotate ? tile.getRotation() * 90 : 0;
|
|
||||||
|
|
||||||
Draw.rect(bottomRegion, tile.drawx(), tile.drawy(), rotation);
|
|
||||||
|
|
||||||
if(mod.total() > 0.001f){
|
|
||||||
Draw.color(outputLiquid.color);
|
|
||||||
Draw.alpha(mod.get(outputLiquid) / liquidCapacity);
|
|
||||||
Draw.rect(liquidRegion, tile.drawx(), tile.drawy(), rotation);
|
|
||||||
Draw.color();
|
|
||||||
}
|
|
||||||
|
|
||||||
Draw.rect(topRegion, tile.drawx(), tile.drawy(), rotation);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TileEntity newEntity(){
|
|
||||||
return new LiquidMixerEntity();
|
|
||||||
}
|
|
||||||
|
|
||||||
static class LiquidMixerEntity extends TileEntity{
|
|
||||||
float accumulator;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,66 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
import io.anuke.arc.graphics.g2d.Lines;
|
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
|
||||||
import io.anuke.mindustry.Vars;
|
|
||||||
import io.anuke.mindustry.graphics.Pal;
|
|
||||||
import io.anuke.mindustry.graphics.Shaders;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
|
|
||||||
public class PhaseWeaver extends PowerSmelter{
|
|
||||||
protected TextureRegion bottomRegion;
|
|
||||||
protected TextureRegion weaveRegion;
|
|
||||||
|
|
||||||
public PhaseWeaver(String name){
|
|
||||||
super(name);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void load(){
|
|
||||||
super.load();
|
|
||||||
|
|
||||||
bottomRegion = Core.atlas.find(name + "-bottom");
|
|
||||||
weaveRegion = Core.atlas.find(name + "-weave");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TextureRegion[] generateIcons(){
|
|
||||||
return new TextureRegion[]{Core.atlas.find(name + "-bottom"), Core.atlas.find(name)};
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
PowerSmelterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
Draw.rect(bottomRegion, tile.drawx(), tile.drawy());
|
|
||||||
|
|
||||||
float progress = 0.5f;
|
|
||||||
|
|
||||||
Shaders.build.region = weaveRegion;
|
|
||||||
Shaders.build.progress = progress;
|
|
||||||
Shaders.build.color.set(Pal.accent);
|
|
||||||
Shaders.build.color.a = entity.heat;
|
|
||||||
Shaders.build.time = -entity.time / 10f;
|
|
||||||
|
|
||||||
Draw.shader(Shaders.build, false);
|
|
||||||
Shaders.build.apply();
|
|
||||||
Draw.rect(weaveRegion, tile.drawx(), tile.drawy(), entity.time);
|
|
||||||
Draw.shader();
|
|
||||||
|
|
||||||
Draw.color(Pal.accent);
|
|
||||||
Draw.alpha(entity.heat);
|
|
||||||
|
|
||||||
Lines.lineAngleCenter(
|
|
||||||
tile.drawx() + Mathf.sin(entity.time, 6f, Vars.tilesize / 3f * size),
|
|
||||||
tile.drawy(),
|
|
||||||
90,
|
|
||||||
size * Vars.tilesize / 2f);
|
|
||||||
|
|
||||||
Draw.reset();
|
|
||||||
|
|
||||||
Draw.rect(region, tile.drawx(), tile.drawy());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
|
||||||
|
|
||||||
public class PlastaniumCompressor extends GenericCrafter{
|
|
||||||
protected TextureRegion topRegion;
|
|
||||||
|
|
||||||
public PlastaniumCompressor(String name){
|
|
||||||
super(name);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void load(){
|
|
||||||
super.load();
|
|
||||||
|
|
||||||
topRegion = Core.atlas.find(name + "-top");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
super.draw(tile);
|
|
||||||
|
|
||||||
GenericCrafterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
Draw.alpha(Mathf.absin(entity.totalProgress, 3f, 0.9f) * entity.warmup);
|
|
||||||
Draw.rect(topRegion, tile.drawx(), tile.drawy());
|
|
||||||
Draw.reset();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,111 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
|
||||||
import io.anuke.mindustry.type.Item;
|
|
||||||
import io.anuke.mindustry.type.Liquid;
|
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.blocks.production.GenericCrafter.GenericCrafterEntity;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
|
||||||
|
|
||||||
/**Similar to GenericCrafter, but also optionally outputs liquids.
|
|
||||||
* TODO consolidate into one class*/
|
|
||||||
public class PowerCrafter extends Block{
|
|
||||||
protected final int timerDump = timers++;
|
|
||||||
protected final int timerContentCheck = timers++;
|
|
||||||
|
|
||||||
/**Optional.*/
|
|
||||||
protected Item outputItem;
|
|
||||||
/**Optional. Set hasLiquids to true when using.*/
|
|
||||||
protected Liquid outputLiquid;
|
|
||||||
protected float outputLiquidAmount;
|
|
||||||
protected float craftTime;
|
|
||||||
|
|
||||||
public PowerCrafter(String name){
|
|
||||||
super(name);
|
|
||||||
solid = true;
|
|
||||||
update = true;
|
|
||||||
hasPower = true;
|
|
||||||
hasItems = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void init(){
|
|
||||||
super.init();
|
|
||||||
|
|
||||||
if(outputLiquid != null){
|
|
||||||
outputsLiquid = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if(outputLiquid != null){
|
|
||||||
produces.set(outputLiquid);
|
|
||||||
}else if(outputItem != null){
|
|
||||||
produces.set(outputItem);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setStats(){
|
|
||||||
super.setStats();
|
|
||||||
|
|
||||||
if(outputItem != null){
|
|
||||||
stats.add(BlockStat.outputItem, outputItem);
|
|
||||||
}
|
|
||||||
|
|
||||||
if(outputLiquid != null){
|
|
||||||
stats.add(BlockStat.liquidOutput, outputLiquid);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean canProduce(Tile tile){
|
|
||||||
if(outputItem != null && tile.entity.items.get(outputItem) >= itemCapacity){
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return outputLiquid == null || !(tile.entity.liquids.get(outputLiquid) >= liquidCapacity - 0.01f);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void update(Tile tile){
|
|
||||||
GenericCrafterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
if(entity.cons.valid()){
|
|
||||||
entity.progress += getProgressIncrease(entity, craftTime);
|
|
||||||
entity.totalProgress += entity.delta();
|
|
||||||
}
|
|
||||||
|
|
||||||
if(entity.progress >= 1f){
|
|
||||||
entity.items.remove(consumes.item(), consumes.itemAmount());
|
|
||||||
if(outputItem != null){
|
|
||||||
offloadNear(tile, outputItem);
|
|
||||||
useContent(tile, outputItem);
|
|
||||||
}
|
|
||||||
|
|
||||||
if(outputLiquid != null){
|
|
||||||
handleLiquid(tile, tile, outputLiquid, outputLiquidAmount);
|
|
||||||
if(tile.entity.liquids.currentAmount() > 0f && tile.entity.timer.get(timerContentCheck, 10)){
|
|
||||||
useContent(tile, outputLiquid);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
entity.progress = 0f;
|
|
||||||
}
|
|
||||||
|
|
||||||
if(outputItem != null && entity.timer.get(timerDump, 5)){
|
|
||||||
tryDump(tile, outputItem);
|
|
||||||
}
|
|
||||||
|
|
||||||
if(outputLiquid != null){
|
|
||||||
tryDumpLiquid(tile, entity.liquids.current());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TileEntity newEntity(){
|
|
||||||
return new GenericCrafterEntity();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,175 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.mindustry.entities.Effects.Effect;
|
|
||||||
import io.anuke.arc.graphics.Color;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
import io.anuke.arc.graphics.g2d.Fill;
|
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
|
||||||
import io.anuke.arc.util.Time;
|
|
||||||
import io.anuke.mindustry.content.Fx;
|
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
|
||||||
import io.anuke.mindustry.type.Item;
|
|
||||||
import io.anuke.mindustry.type.ItemStack;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.blocks.PowerBlock;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
|
||||||
|
|
||||||
import java.io.DataInput;
|
|
||||||
import java.io.DataOutput;
|
|
||||||
import java.io.IOException;
|
|
||||||
|
|
||||||
public class PowerSmelter extends PowerBlock{
|
|
||||||
protected final int timerDump = timers++;
|
|
||||||
|
|
||||||
protected Item output;
|
|
||||||
|
|
||||||
protected float heatUpTime = 80f;
|
|
||||||
protected float minHeat = 0.5f;
|
|
||||||
|
|
||||||
protected float craftTime = 20f; //time to craft one item, so max 3 items per second by default
|
|
||||||
protected float burnEffectChance = 0.01f;
|
|
||||||
protected Effect craftEffect = Fx.smelt,
|
|
||||||
burnEffect = Fx.fuelburn;
|
|
||||||
protected Color flameColor = Color.valueOf("ffc999");
|
|
||||||
|
|
||||||
protected TextureRegion topRegion;
|
|
||||||
|
|
||||||
public PowerSmelter(String name){
|
|
||||||
super(name);
|
|
||||||
hasItems = true;
|
|
||||||
update = true;
|
|
||||||
solid = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void init(){
|
|
||||||
super.init();
|
|
||||||
|
|
||||||
produces.set(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void load(){
|
|
||||||
super.load();
|
|
||||||
topRegion = Core.atlas.find(name + "-top");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setStats(){
|
|
||||||
super.setStats();
|
|
||||||
|
|
||||||
stats.add(BlockStat.outputItem, output);
|
|
||||||
stats.add(BlockStat.craftSpeed, 60f / craftTime, StatUnit.itemsSecond);
|
|
||||||
stats.add(BlockStat.inputItemCapacity, itemCapacity, StatUnit.items);
|
|
||||||
stats.add(BlockStat.outputItemCapacity, itemCapacity, StatUnit.items);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void update(Tile tile){
|
|
||||||
|
|
||||||
PowerSmelterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
if(entity.timer.get(timerDump, 5) && entity.items.has(output)){
|
|
||||||
tryDump(tile, output);
|
|
||||||
}
|
|
||||||
|
|
||||||
//heat it up if there's enough power
|
|
||||||
if(entity.cons.valid()){
|
|
||||||
entity.heat += 1f / heatUpTime * entity.delta();
|
|
||||||
if(Mathf.chance(entity.delta() * burnEffectChance))
|
|
||||||
Effects.effect(burnEffect, entity.x + Mathf.range(size * 4f), entity.y + Mathf.range(size * 4));
|
|
||||||
}else{
|
|
||||||
entity.heat -= 1f / heatUpTime * Time.delta();
|
|
||||||
}
|
|
||||||
|
|
||||||
entity.heat = Mathf.clamp(entity.heat);
|
|
||||||
entity.time += entity.heat * entity.delta();
|
|
||||||
|
|
||||||
if(!entity.cons.valid()){
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
entity.craftTime += entity.delta() * entity.power.satisfaction;
|
|
||||||
|
|
||||||
if(entity.items.get(output) >= itemCapacity //output full
|
|
||||||
|| entity.heat <= minHeat //not burning
|
|
||||||
|| entity.craftTime < craftTime){ //not yet time
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
entity.craftTime = 0f;
|
|
||||||
|
|
||||||
for(ItemStack item : consumes.items()){
|
|
||||||
entity.items.remove(item.item, item.amount);
|
|
||||||
}
|
|
||||||
|
|
||||||
offloadNear(tile, output);
|
|
||||||
Effects.effect(craftEffect, flameColor, tile.drawx(), tile.drawy());
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptItem(Item item, Tile tile, Tile source){
|
|
||||||
|
|
||||||
for(ItemStack stack : consumes.items()){
|
|
||||||
if(stack.item == item){
|
|
||||||
return tile.entity.items.get(item) < itemCapacity;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int getMaximumAccepted(Tile tile, Item item){
|
|
||||||
return itemCapacity;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
super.draw(tile);
|
|
||||||
|
|
||||||
PowerSmelterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
//draw glowing center
|
|
||||||
if(entity.heat > 0f && flameColor.a > 0.001f){
|
|
||||||
float g = 0.3f;
|
|
||||||
float r = 0.06f;
|
|
||||||
float cr = Mathf.random(0.1f);
|
|
||||||
|
|
||||||
Draw.alpha(((1f - g) + Mathf.absin(Time.time(), 8f, g) + Mathf.random(r) - r) * entity.heat);
|
|
||||||
|
|
||||||
Draw.tint(flameColor);
|
|
||||||
Fill.circle(tile.drawx(), tile.drawy(), 3f + Mathf.absin(Time.time(), 5f, 2f) + cr);
|
|
||||||
Draw.color(1f, 1f, 1f, entity.heat);
|
|
||||||
Draw.rect(topRegion, tile.drawx(), tile.drawy());
|
|
||||||
Fill.circle(tile.drawx(), tile.drawy(), 1.9f + Mathf.absin(Time.time(), 5f, 1f) + cr);
|
|
||||||
|
|
||||||
Draw.color();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TileEntity newEntity(){
|
|
||||||
return new PowerSmelterEntity();
|
|
||||||
}
|
|
||||||
|
|
||||||
class PowerSmelterEntity extends TileEntity{
|
|
||||||
public float heat;
|
|
||||||
public float time;
|
|
||||||
public float craftTime;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void write(DataOutput stream) throws IOException{
|
|
||||||
stream.writeFloat(heat);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void read(DataInput stream) throws IOException{
|
|
||||||
heat = stream.readFloat();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,35 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
|
|
||||||
public class Pulverizer extends GenericCrafter{
|
|
||||||
protected TextureRegion rotatorRegion;
|
|
||||||
|
|
||||||
public Pulverizer(String name){
|
|
||||||
super(name);
|
|
||||||
hasItems = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void load(){
|
|
||||||
super.load();
|
|
||||||
|
|
||||||
rotatorRegion = Core.atlas.find(name + "-rotator");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
GenericCrafterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
Draw.rect(region, tile.drawx(), tile.drawy());
|
|
||||||
Draw.rect(rotatorRegion, tile.drawx(), tile.drawy(), entity.totalProgress * 2f);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TextureRegion[] generateIcons(){
|
|
||||||
return new TextureRegion[]{Core.atlas.find(name), Core.atlas.find(name + "-rotator")};
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,17 +1,16 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
package io.anuke.mindustry.world.blocks.production;
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
import io.anuke.arc.Core;
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.arc.collection.Array;
|
import io.anuke.arc.collection.Array;
|
||||||
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
|
import io.anuke.arc.graphics.g2d.TextureRegion;
|
||||||
import io.anuke.mindustry.graphics.Layer;
|
import io.anuke.mindustry.graphics.Layer;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.blocks.LiquidBlock;
|
import io.anuke.mindustry.world.blocks.LiquidBlock;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeLiquid;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockGroup;
|
import io.anuke.mindustry.world.meta.BlockGroup;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
|
|
||||||
public class Pump extends LiquidBlock{
|
public class Pump extends LiquidBlock{
|
||||||
protected final Array<Tile> drawTiles = new Array<>();
|
protected final Array<Tile> drawTiles = new Array<>();
|
||||||
@@ -40,7 +39,7 @@ public class Pump extends LiquidBlock{
|
|||||||
@Override
|
@Override
|
||||||
public void setStats(){
|
public void setStats(){
|
||||||
super.setStats();
|
super.setStats();
|
||||||
stats.add(BlockStat.liquidOutputSpeed, 60f * pumpAmount, StatUnit.liquidSecond);
|
stats.add(BlockStat.output, 60f * pumpAmount, StatUnit.liquidSecond);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -107,11 +106,6 @@ public class Pump extends LiquidBlock{
|
|||||||
tryDumpLiquid(tile, tile.entity.liquids.current());
|
tryDumpLiquid(tile, tile.entity.liquids.current());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptLiquid(Tile tile, Tile source, Liquid liquid, float amount){
|
|
||||||
return consumes.has(ConsumeLiquid.class) && consumes.liquid() == liquid && super.acceptLiquid(tile, source, liquid, amount);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected boolean isValid(Tile tile){
|
protected boolean isValid(Tile tile){
|
||||||
return tile != null && tile.floor().liquidDrop != null;
|
return tile != null && tile.floor().liquidDrop != null;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
package io.anuke.mindustry.world.blocks.production;
|
||||||
|
|
||||||
import io.anuke.arc.Core;
|
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.Color;
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
import io.anuke.arc.graphics.g2d.Draw;
|
||||||
import io.anuke.arc.graphics.g2d.Lines;
|
import io.anuke.arc.graphics.g2d.Lines;
|
||||||
import io.anuke.arc.graphics.g2d.TextureRegion;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.Mathf;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
@@ -12,8 +10,10 @@ import io.anuke.mindustry.type.ItemStack;
|
|||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.blocks.production.GenericCrafter.GenericCrafterEntity;
|
import io.anuke.mindustry.world.blocks.production.GenericCrafter.GenericCrafterEntity;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItem;
|
import io.anuke.mindustry.world.consumers.ConsumeLiquidBase;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
import io.anuke.mindustry.world.meta.values.ItemFilterValue;
|
import io.anuke.mindustry.world.meta.values.ItemFilterValue;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -23,14 +23,14 @@ public class Separator extends Block{
|
|||||||
protected final int timerDump = timers++;
|
protected final int timerDump = timers++;
|
||||||
|
|
||||||
protected ItemStack[] results;
|
protected ItemStack[] results;
|
||||||
protected float filterTime;
|
protected float craftTime;
|
||||||
protected float spinnerRadius = 2.5f;
|
protected float spinnerRadius = 2.5f;
|
||||||
protected float spinnerLength = 1f;
|
protected float spinnerLength = 1f;
|
||||||
protected float spinnerThickness = 1f;
|
protected float spinnerThickness = 1f;
|
||||||
protected float spinnerSpeed = 2f;
|
protected float spinnerSpeed = 2f;
|
||||||
|
|
||||||
protected Color color = Color.valueOf("858585");
|
protected Color color = Color.valueOf("858585");
|
||||||
protected TextureRegion liquidRegion;
|
protected int liquidRegion;
|
||||||
|
|
||||||
public Separator(String name){
|
public Separator(String name){
|
||||||
super(name);
|
super(name);
|
||||||
@@ -38,25 +38,28 @@ public class Separator extends Block{
|
|||||||
solid = true;
|
solid = true;
|
||||||
hasItems = true;
|
hasItems = true;
|
||||||
hasLiquids = true;
|
hasLiquids = true;
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
liquidRegion = reg("liquid");
|
||||||
public void load(){
|
|
||||||
super.load();
|
|
||||||
|
|
||||||
liquidRegion = Core.atlas.find(name + "-liquid");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setStats(){
|
public void setStats(){
|
||||||
|
if(consumes.has(ConsumeType.liquid)){
|
||||||
|
ConsumeLiquidBase cons = consumes.get(ConsumeType.liquid);
|
||||||
|
cons.timePeriod = craftTime;
|
||||||
|
}
|
||||||
|
|
||||||
super.setStats();
|
super.setStats();
|
||||||
|
|
||||||
stats.add(BlockStat.outputItem, new ItemFilterValue(item -> {
|
stats.add(BlockStat.output, new ItemFilterValue(item -> {
|
||||||
for(ItemStack i : results){
|
for(ItemStack i : results){
|
||||||
if(item == i.item) return true;
|
if(item == i.item) return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
stats.add(BlockStat.productionTime, craftTime / 60f, StatUnit.seconds);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -67,7 +70,7 @@ public class Separator extends Block{
|
|||||||
|
|
||||||
Draw.color(tile.entity.liquids.current().color);
|
Draw.color(tile.entity.liquids.current().color);
|
||||||
Draw.alpha(tile.entity.liquids.total() / liquidCapacity);
|
Draw.alpha(tile.entity.liquids.total() / liquidCapacity);
|
||||||
Draw.rect(liquidRegion, tile.drawx(), tile.drawy());
|
Draw.rect(reg(liquidRegion), tile.drawx(), tile.drawy());
|
||||||
|
|
||||||
Draw.color(color);
|
Draw.color(color);
|
||||||
Lines.stroke(spinnerThickness);
|
Lines.stroke(spinnerThickness);
|
||||||
@@ -82,7 +85,7 @@ public class Separator extends Block{
|
|||||||
entity.totalProgress += entity.warmup * entity.delta();
|
entity.totalProgress += entity.warmup * entity.delta();
|
||||||
|
|
||||||
if(entity.cons.valid()){
|
if(entity.cons.valid()){
|
||||||
entity.progress += getProgressIncrease(entity, filterTime);
|
entity.progress += getProgressIncrease(entity, craftTime);
|
||||||
entity.warmup = Mathf.lerpDelta(entity.warmup, 1f, 0.02f);
|
entity.warmup = Mathf.lerpDelta(entity.warmup, 1f, 0.02f);
|
||||||
}else{
|
}else{
|
||||||
entity.warmup = Mathf.lerpDelta(entity.warmup, 0f, 0.02f);
|
entity.warmup = Mathf.lerpDelta(entity.warmup, 0f, 0.02f);
|
||||||
@@ -106,9 +109,7 @@ public class Separator extends Block{
|
|||||||
count += stack.amount;
|
count += stack.amount;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(consumes.has(ConsumeItem.class)){
|
entity.cons.trigger();
|
||||||
entity.items.remove(consumes.item(), consumes.itemAmount());
|
|
||||||
}
|
|
||||||
|
|
||||||
if(item != null && entity.items.get(item) < itemCapacity){
|
if(item != null && entity.items.get(item) < itemCapacity){
|
||||||
offloadNear(tile, item);
|
offloadNear(tile, item);
|
||||||
|
|||||||
@@ -1,148 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.blocks.production;
|
|
||||||
|
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.mindustry.entities.Effects.Effect;
|
|
||||||
import io.anuke.arc.graphics.Color;
|
|
||||||
import io.anuke.arc.graphics.g2d.Draw;
|
|
||||||
import io.anuke.arc.graphics.g2d.Fill;
|
|
||||||
import io.anuke.arc.math.Mathf;
|
|
||||||
import io.anuke.arc.util.Time;
|
|
||||||
import io.anuke.mindustry.content.Fx;
|
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
|
||||||
import io.anuke.mindustry.type.Item;
|
|
||||||
import io.anuke.mindustry.type.ItemStack;
|
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItem;
|
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItems;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
|
||||||
|
|
||||||
public class Smelter extends Block{
|
|
||||||
protected final int timerDump = timers++;
|
|
||||||
|
|
||||||
protected Item result;
|
|
||||||
|
|
||||||
protected float craftTime = 20f;
|
|
||||||
protected float burnDuration = 50f;
|
|
||||||
protected Effect craftEffect = Fx.smelt, burnEffect = Fx.fuelburn;
|
|
||||||
protected Color flameColor = Color.valueOf("ffb879");
|
|
||||||
|
|
||||||
public Smelter(String name){
|
|
||||||
super(name);
|
|
||||||
update = true;
|
|
||||||
hasItems = true;
|
|
||||||
solid = true;
|
|
||||||
|
|
||||||
consumes.require(ConsumeItems.class);
|
|
||||||
consumes.require(ConsumeItem.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setStats(){
|
|
||||||
super.setStats();
|
|
||||||
|
|
||||||
stats.add(BlockStat.fuelBurnTime, burnDuration / 60f, StatUnit.seconds);
|
|
||||||
stats.add(BlockStat.outputItem, result);
|
|
||||||
stats.add(BlockStat.craftSpeed, 60f / craftTime, StatUnit.itemsSecond);
|
|
||||||
stats.add(BlockStat.inputItemCapacity, itemCapacity, StatUnit.items);
|
|
||||||
stats.add(BlockStat.outputItemCapacity, itemCapacity, StatUnit.items);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void init(){
|
|
||||||
super.init();
|
|
||||||
produces.set(result);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void update(Tile tile){
|
|
||||||
SmelterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
if(entity.timer.get(timerDump, 5) && entity.items.has(result)){
|
|
||||||
tryDump(tile, result);
|
|
||||||
}
|
|
||||||
|
|
||||||
//add fuel
|
|
||||||
if(entity.consumed(ConsumeItem.class) && entity.burnTime <= 0f){
|
|
||||||
entity.items.remove(consumes.item(), 1);
|
|
||||||
entity.burnTime += burnDuration;
|
|
||||||
Effects.effect(burnEffect, entity.x + Mathf.range(2f), entity.y + Mathf.range(2f));
|
|
||||||
}
|
|
||||||
|
|
||||||
//decrement burntime
|
|
||||||
if(entity.burnTime > 0){
|
|
||||||
entity.burnTime -= entity.delta();
|
|
||||||
entity.heat = Mathf.lerpDelta(entity.heat, 1f, 0.02f);
|
|
||||||
}else{
|
|
||||||
entity.heat = Mathf.lerpDelta(entity.heat, 0f, 0.02f);
|
|
||||||
}
|
|
||||||
|
|
||||||
//make sure it has all the items
|
|
||||||
if(!entity.cons.valid()){
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
entity.craftTime += entity.delta();
|
|
||||||
|
|
||||||
if(entity.items.get(result) >= itemCapacity //output full
|
|
||||||
|| entity.burnTime <= 0 //not burning
|
|
||||||
|| entity.craftTime < craftTime){ //not yet time
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
entity.craftTime = 0f;
|
|
||||||
for(ItemStack item : consumes.items()){
|
|
||||||
entity.items.remove(item.item, item.amount);
|
|
||||||
}
|
|
||||||
|
|
||||||
offloadNear(tile, result);
|
|
||||||
Effects.effect(craftEffect, flameColor, tile.drawx(), tile.drawy());
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptItem(Item item, Tile tile, Tile source){
|
|
||||||
boolean isInput = false;
|
|
||||||
|
|
||||||
for(ItemStack req : consumes.items()){
|
|
||||||
if(req.item == item){
|
|
||||||
isInput = true;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return (isInput && tile.entity.items.get(item) < itemCapacity) || (item == consumes.item() && tile.entity.items.get(consumes.item()) < itemCapacity);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void draw(Tile tile){
|
|
||||||
super.draw(tile);
|
|
||||||
|
|
||||||
SmelterEntity entity = tile.entity();
|
|
||||||
|
|
||||||
//draw glowing center
|
|
||||||
if(entity.heat > 0f){
|
|
||||||
float g = 0.1f;
|
|
||||||
|
|
||||||
Draw.alpha(((1f - g) + Mathf.absin(Time.time(), 8f, g)) * entity.heat);
|
|
||||||
|
|
||||||
Draw.tint(flameColor);
|
|
||||||
Fill.circle(tile.drawx(), tile.drawy(), 2f + Mathf.absin(Time.time(), 5f, 0.8f));
|
|
||||||
Draw.color(1f, 1f, 1f, entity.heat);
|
|
||||||
Fill.circle(tile.drawx(), tile.drawy(), 1f + Mathf.absin(Time.time(), 5f, 0.7f));
|
|
||||||
|
|
||||||
Draw.color();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TileEntity newEntity(){
|
|
||||||
return new SmelterEntity();
|
|
||||||
}
|
|
||||||
|
|
||||||
public class SmelterEntity extends TileEntity{
|
|
||||||
public float burnTime;
|
|
||||||
public float heat;
|
|
||||||
public float craftTime;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -42,7 +42,7 @@ public class SolidPump extends Pump{
|
|||||||
@Override
|
@Override
|
||||||
public void drawPlace(int x, int y, int rotation, boolean valid){
|
public void drawPlace(int x, int y, int rotation, boolean valid){
|
||||||
if(attribute != null){
|
if(attribute != null){
|
||||||
drawPlaceText(Core.bundle.formatDouble("blocks.efficiency", (sumAttribute(attribute, x, y) + 1f)*100, 1), x, y, valid);
|
drawPlaceText(Core.bundle.formatFloat("bar.efficiency", (sumAttribute(attribute, x, y) + 1f)*100, 1), x, y, valid);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -50,7 +50,7 @@ public class SolidPump extends Pump{
|
|||||||
public void setBars(){
|
public void setBars(){
|
||||||
super.setBars();
|
super.setBars();
|
||||||
bars.add("efficiency", entity -> new Bar(() ->
|
bars.add("efficiency", entity -> new Bar(() ->
|
||||||
Core.bundle.formatDouble("blocks.efficiency",
|
Core.bundle.formatFloat("bar.efficiency",
|
||||||
((((SolidPumpEntity)entity).boost + 1f) * ((SolidPumpEntity)entity).warmup) * 100, 1),
|
((((SolidPumpEntity)entity).boost + 1f) * ((SolidPumpEntity)entity).warmup) * 100, 1),
|
||||||
() -> Pal.ammo,
|
() -> Pal.ammo,
|
||||||
() -> ((SolidPumpEntity)entity).warmup));
|
() -> ((SolidPumpEntity)entity).warmup));
|
||||||
@@ -60,7 +60,8 @@ public class SolidPump extends Pump{
|
|||||||
public void setStats(){
|
public void setStats(){
|
||||||
super.setStats();
|
super.setStats();
|
||||||
|
|
||||||
stats.add(BlockStat.liquidOutput, result);
|
stats.remove(BlockStat.output);
|
||||||
|
stats.add(BlockStat.output, result, 60f * pumpAmount, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -23,6 +23,8 @@ import io.anuke.mindustry.graphics.Shaders;
|
|||||||
import io.anuke.mindustry.type.Mech;
|
import io.anuke.mindustry.type.Mech;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
|
|
||||||
import java.io.DataInput;
|
import java.io.DataInput;
|
||||||
import java.io.DataOutput;
|
import java.io.DataOutput;
|
||||||
@@ -45,6 +47,13 @@ public class MechPad extends Block{
|
|||||||
hasPower = true;
|
hasPower = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setStats(){
|
||||||
|
super.setStats();
|
||||||
|
|
||||||
|
stats.add(BlockStat.productionTime, buildTime/60f, StatUnit.seconds);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void init(){
|
public void init(){
|
||||||
super.init();
|
super.init();
|
||||||
|
|||||||
@@ -25,10 +25,10 @@ import io.anuke.mindustry.ui.Bar;
|
|||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.Block;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.consumers.ConsumeItems;
|
import io.anuke.mindustry.world.consumers.ConsumeItems;
|
||||||
|
import io.anuke.mindustry.world.consumers.ConsumeType;
|
||||||
import io.anuke.mindustry.world.meta.BlockFlag;
|
import io.anuke.mindustry.world.meta.BlockFlag;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
import io.anuke.mindustry.world.meta.StatUnit;
|
||||||
import io.anuke.mindustry.world.modules.ItemModule;
|
|
||||||
|
|
||||||
import java.io.DataInput;
|
import java.io.DataInput;
|
||||||
import java.io.DataOutput;
|
import java.io.DataOutput;
|
||||||
@@ -45,6 +45,7 @@ public class UnitFactory extends Block{
|
|||||||
protected float launchVelocity = 0f;
|
protected float launchVelocity = 0f;
|
||||||
protected TextureRegion topRegion;
|
protected TextureRegion topRegion;
|
||||||
protected int maxSpawn = 2;
|
protected int maxSpawn = 2;
|
||||||
|
protected int[] capacities;
|
||||||
|
|
||||||
public UnitFactory(String name){
|
public UnitFactory(String name){
|
||||||
super(name);
|
super(name);
|
||||||
@@ -53,8 +54,6 @@ public class UnitFactory extends Block{
|
|||||||
hasItems = true;
|
hasItems = true;
|
||||||
solid = false;
|
solid = false;
|
||||||
flags = EnumSet.of(BlockFlag.producer);
|
flags = EnumSet.of(BlockFlag.producer);
|
||||||
|
|
||||||
consumes.require(ConsumeItems.class);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Remote(called = Loc.server)
|
@Remote(called = Loc.server)
|
||||||
@@ -79,6 +78,19 @@ public class UnitFactory extends Block{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void init(){
|
||||||
|
super.init();
|
||||||
|
|
||||||
|
capacities = new int[Vars.content.items().size];
|
||||||
|
if(consumes.has(ConsumeType.item)){
|
||||||
|
ConsumeItems cons = consumes.get(ConsumeType.item);
|
||||||
|
for(ItemStack stack : cons.items){
|
||||||
|
capacities[stack.item.id] = stack.amount*2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void load(){
|
public void load(){
|
||||||
super.load();
|
super.load();
|
||||||
@@ -89,8 +101,8 @@ public class UnitFactory extends Block{
|
|||||||
@Override
|
@Override
|
||||||
public void setBars(){
|
public void setBars(){
|
||||||
super.setBars();
|
super.setBars();
|
||||||
bars.add("progress", entity -> new Bar("blocks.progress", Pal.ammo, () -> ((UnitFactoryEntity)entity).buildTime / produceTime));
|
bars.add("progress", entity -> new Bar("bar.progress", Pal.ammo, () -> ((UnitFactoryEntity)entity).buildTime / produceTime));
|
||||||
bars.add("spawned", entity -> new Bar(() -> Core.bundle.format("blocks.spawned", ((UnitFactoryEntity)entity).spawned, maxSpawn), () -> Pal.command, () -> (float)((UnitFactoryEntity)entity).spawned / maxSpawn));
|
bars.add("spawned", entity -> new Bar(() -> Core.bundle.format("bar.spawned", ((UnitFactoryEntity)entity).spawned, maxSpawn), () -> Pal.command, () -> (float)((UnitFactoryEntity)entity).spawned / maxSpawn));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -102,7 +114,8 @@ public class UnitFactory extends Block{
|
|||||||
public void setStats(){
|
public void setStats(){
|
||||||
super.setStats();
|
super.setStats();
|
||||||
|
|
||||||
stats.add(BlockStat.craftSpeed, produceTime / 60f, StatUnit.seconds);
|
stats.remove(BlockStat.itemCapacity);
|
||||||
|
stats.add(BlockStat.productionTime, produceTime / 60f, StatUnit.seconds);
|
||||||
stats.add(BlockStat.maxUnits, maxSpawn, StatUnit.none);
|
stats.add(BlockStat.maxUnits, maxSpawn, StatUnit.none);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -162,7 +175,7 @@ public class UnitFactory extends Block{
|
|||||||
|
|
||||||
if(!tile.isEnemyCheat()){
|
if(!tile.isEnemyCheat()){
|
||||||
//player-made spawners have default behavior
|
//player-made spawners have default behavior
|
||||||
if(hasRequirements(entity.items, entity.buildTime / produceTime) && entity.cons.valid()){
|
if(entity.cons.valid()){
|
||||||
entity.time += entity.delta() * entity.speedScl;
|
entity.time += entity.delta() * entity.speedScl;
|
||||||
entity.buildTime += entity.delta() * entity.power.satisfaction;
|
entity.buildTime += entity.delta() * entity.power.satisfaction;
|
||||||
entity.speedScl = Mathf.lerpDelta(entity.speedScl, 1f, 0.05f);
|
entity.speedScl = Mathf.lerpDelta(entity.speedScl, 1f, 0.05f);
|
||||||
@@ -186,30 +199,13 @@ public class UnitFactory extends Block{
|
|||||||
Call.onUnitFactorySpawn(tile, entity.spawned + 1);
|
Call.onUnitFactorySpawn(tile, entity.spawned + 1);
|
||||||
useContent(tile, type);
|
useContent(tile, type);
|
||||||
|
|
||||||
for(ItemStack stack : consumes.items()){
|
entity.cons.trigger();
|
||||||
entity.items.remove(stack.item, stack.amount);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean acceptItem(Item item, Tile tile, Tile source){
|
|
||||||
for(ItemStack stack : consumes.items()){
|
|
||||||
if(item == stack.item && tile.entity.items.get(item) < stack.amount * 2){
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getMaximumAccepted(Tile tile, Item item){
|
public int getMaximumAccepted(Tile tile, Item item){
|
||||||
for(ItemStack stack : consumes.items()){
|
return capacities[item.id];
|
||||||
if(item == stack.item){
|
|
||||||
return stack.amount * 2;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -223,21 +219,12 @@ public class UnitFactory extends Block{
|
|||||||
return entity.spawned < maxSpawn;
|
return entity.spawned < maxSpawn;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected boolean hasRequirements(ItemModule inv, float fraction){
|
|
||||||
for(ItemStack stack : consumes.items()){
|
|
||||||
if(!inv.has(stack.item, (int) (fraction * stack.amount))){
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static class UnitFactoryEntity extends TileEntity{
|
public static class UnitFactoryEntity extends TileEntity{
|
||||||
public float buildTime;
|
float buildTime;
|
||||||
public float time;
|
float time;
|
||||||
public float speedScl;
|
float speedScl;
|
||||||
public float warmup; //only for enemy spawners
|
float warmup; //only for enemy spawners
|
||||||
public int spawned;
|
int spawned;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void write(DataOutput stream) throws IOException{
|
public void write(DataOutput stream) throws IOException{
|
||||||
|
|||||||
@@ -2,14 +2,25 @@ package io.anuke.mindustry.world.consumers;
|
|||||||
|
|
||||||
import io.anuke.arc.scene.ui.layout.Table;
|
import io.anuke.arc.scene.ui.layout.Table;
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
|
|
||||||
/**An abstract class that defines a type of resource that a block can consume.*/
|
/**An abstract class that defines a type of resource that a block can consume.*/
|
||||||
public abstract class Consume{
|
public abstract class Consume{
|
||||||
protected boolean optional;
|
protected boolean optional;
|
||||||
protected boolean update = true, boost = false;
|
protected boolean update = true;
|
||||||
|
|
||||||
|
/**Apply a filter to items accepted.
|
||||||
|
* This should set all item IDs that are present in the filter to true.*/
|
||||||
|
public void applyItemFilter(boolean[] filter){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**Apply a filter to liquids accepted.
|
||||||
|
* This should set all liquid IDs that are present in the filter to true.*/
|
||||||
|
public void applyLiquidFilter(boolean[] filter){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public Consume optional(boolean optional){
|
public Consume optional(boolean optional){
|
||||||
this.optional = optional;
|
this.optional = optional;
|
||||||
@@ -21,11 +32,6 @@ public abstract class Consume{
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Consume boost(boolean boost){
|
|
||||||
this.boost = boost;
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean isOptional(){
|
public boolean isOptional(){
|
||||||
return optional;
|
return optional;
|
||||||
}
|
}
|
||||||
@@ -34,18 +40,20 @@ public abstract class Consume{
|
|||||||
return update;
|
return update;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public abstract ConsumeType type();
|
||||||
|
|
||||||
public abstract void build(Tile tile, Table table);
|
public abstract void build(Tile tile, Table table);
|
||||||
|
|
||||||
/**Called when a consumption is triggered manually.*/
|
/**Called when a consumption is triggered manually.*/
|
||||||
public void trigger(Block block, TileEntity entity){
|
public void trigger(TileEntity entity){
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public abstract String getIcon();
|
public abstract String getIcon();
|
||||||
|
|
||||||
public abstract void update(Block block, TileEntity entity);
|
public abstract void update(TileEntity entity);
|
||||||
|
|
||||||
public abstract boolean valid(Block block, TileEntity entity);
|
public abstract boolean valid(TileEntity entity);
|
||||||
|
|
||||||
public abstract void display(BlockStats stats);
|
public abstract void display(BlockStats stats);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,66 +0,0 @@
|
|||||||
package io.anuke.mindustry.world.consumers;
|
|
||||||
|
|
||||||
import io.anuke.arc.scene.ui.layout.Table;
|
|
||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
|
||||||
import io.anuke.mindustry.type.Item;
|
|
||||||
import io.anuke.mindustry.type.Item.Icon;
|
|
||||||
import io.anuke.mindustry.type.ItemStack;
|
|
||||||
import io.anuke.mindustry.ui.ItemImage;
|
|
||||||
import io.anuke.mindustry.ui.ReqImage;
|
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
|
||||||
|
|
||||||
public class ConsumeItem extends Consume{
|
|
||||||
private final Item item;
|
|
||||||
private final int amount;
|
|
||||||
|
|
||||||
public ConsumeItem(Item item){
|
|
||||||
this.item = item;
|
|
||||||
this.amount = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ConsumeItem(Item item, int amount){
|
|
||||||
this.item = item;
|
|
||||||
this.amount = amount;
|
|
||||||
}
|
|
||||||
|
|
||||||
public int getAmount(){
|
|
||||||
return amount;
|
|
||||||
}
|
|
||||||
|
|
||||||
public Item get(){
|
|
||||||
return item;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void trigger(Block block, TileEntity entity){
|
|
||||||
entity.items.remove(item, amount);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void build(Tile tile, Table table){
|
|
||||||
table.add(new ReqImage(new ItemImage(item.icon(Icon.large), amount), () -> valid(tile.block(), tile.entity))).size(8*4);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getIcon(){
|
|
||||||
return "icon-item";
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void update(Block block, TileEntity entity){
|
|
||||||
//doesn't update because consuming items is very specific
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean valid(Block block, TileEntity entity){
|
|
||||||
return entity != null && entity.items != null && entity.items.has(item, amount);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void display(BlockStats stats){
|
|
||||||
stats.add(boost ? BlockStat.boostItem : BlockStat.inputItem, new ItemStack(item, amount));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -9,7 +9,6 @@ import io.anuke.mindustry.type.Item.Icon;
|
|||||||
import io.anuke.mindustry.ui.ItemImage;
|
import io.anuke.mindustry.ui.ItemImage;
|
||||||
import io.anuke.mindustry.ui.MultiReqImage;
|
import io.anuke.mindustry.ui.MultiReqImage;
|
||||||
import io.anuke.mindustry.ui.ReqImage;
|
import io.anuke.mindustry.ui.ReqImage;
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
@@ -18,12 +17,22 @@ import io.anuke.mindustry.world.meta.values.ItemFilterValue;
|
|||||||
import static io.anuke.mindustry.Vars.content;
|
import static io.anuke.mindustry.Vars.content;
|
||||||
|
|
||||||
public class ConsumeItemFilter extends Consume{
|
public class ConsumeItemFilter extends Consume{
|
||||||
private final Predicate<Item> filter;
|
public final Predicate<Item> filter;
|
||||||
|
|
||||||
public ConsumeItemFilter(Predicate<Item> item){
|
public ConsumeItemFilter(Predicate<Item> item){
|
||||||
this.filter = item;
|
this.filter = item;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void applyItemFilter(boolean[] arr){
|
||||||
|
content.items().each(filter, item -> arr[item.id] = true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ConsumeType type(){
|
||||||
|
return ConsumeType.item;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void build(Tile tile, Table table){
|
public void build(Tile tile, Table table){
|
||||||
Array<Item> list = content.items().select(filter);
|
Array<Item> list = content.items().select(filter);
|
||||||
@@ -39,12 +48,12 @@ public class ConsumeItemFilter extends Consume{
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Block block, TileEntity entity){
|
public void update(TileEntity entity){
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void trigger(Block block, TileEntity entity){
|
public void trigger(TileEntity entity){
|
||||||
for(int i = 0; i < content.items().size; i++){
|
for(int i = 0; i < content.items().size; i++){
|
||||||
Item item = content.item(i);
|
Item item = content.item(i);
|
||||||
if(entity.items != null && entity.items.has(item) && this.filter.test(item)){
|
if(entity.items != null && entity.items.has(item) && this.filter.test(item)){
|
||||||
@@ -55,7 +64,7 @@ public class ConsumeItemFilter extends Consume{
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean valid(Block block, TileEntity entity){
|
public boolean valid(TileEntity entity){
|
||||||
for(int i = 0; i < content.items().size; i++){
|
for(int i = 0; i < content.items().size; i++){
|
||||||
Item item = content.item(i);
|
Item item = content.item(i);
|
||||||
if(entity.items != null && entity.items.has(item) && this.filter.test(item)){
|
if(entity.items != null && entity.items.has(item) && this.filter.test(item)){
|
||||||
@@ -67,6 +76,6 @@ public class ConsumeItemFilter extends Consume{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void display(BlockStats stats){
|
public void display(BlockStats stats){
|
||||||
stats.add(boost ? BlockStat.boostItem : BlockStat.inputItem, new ItemFilterValue(filter));
|
stats.add(optional ? BlockStat.booster : BlockStat.input, new ItemFilterValue(filter));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,21 +6,28 @@ import io.anuke.mindustry.type.Item.Icon;
|
|||||||
import io.anuke.mindustry.type.ItemStack;
|
import io.anuke.mindustry.type.ItemStack;
|
||||||
import io.anuke.mindustry.ui.ItemImage;
|
import io.anuke.mindustry.ui.ItemImage;
|
||||||
import io.anuke.mindustry.ui.ReqImage;
|
import io.anuke.mindustry.ui.ReqImage;
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
import io.anuke.mindustry.world.meta.values.ItemListValue;
|
import io.anuke.mindustry.world.meta.values.ItemListValue;
|
||||||
|
|
||||||
public class ConsumeItems extends Consume{
|
public class ConsumeItems extends Consume{
|
||||||
private ItemStack[] items;
|
public final ItemStack[] items;
|
||||||
|
|
||||||
public ConsumeItems(ItemStack[] items){
|
public ConsumeItems(ItemStack[] items){
|
||||||
this.items = items;
|
this.items = items;
|
||||||
}
|
}
|
||||||
|
|
||||||
public ItemStack[] getItems(){
|
@Override
|
||||||
return items;
|
public void applyItemFilter(boolean[] filter){
|
||||||
|
for(ItemStack stack : items){
|
||||||
|
filter[stack.item.id] = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ConsumeType type(){
|
||||||
|
return ConsumeType.item;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -36,24 +43,24 @@ public class ConsumeItems extends Consume{
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Block block, TileEntity entity){
|
public void update(TileEntity entity){
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void trigger(Block block, TileEntity entity){
|
public void trigger(TileEntity entity){
|
||||||
for(ItemStack stack : items){
|
for(ItemStack stack : items){
|
||||||
entity.items.remove(stack);
|
entity.items.remove(stack);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean valid(Block block, TileEntity entity){
|
public boolean valid(TileEntity entity){
|
||||||
return entity.items != null && entity.items.has(items);
|
return entity.items != null && entity.items.has(items);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void display(BlockStats stats){
|
public void display(BlockStats stats){
|
||||||
stats.add(boost ? BlockStat.boostItem : BlockStat.inputItems, new ItemListValue(items));
|
stats.add(optional ? BlockStat.booster : BlockStat.input, new ItemListValue(items));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,32 +4,26 @@ import io.anuke.arc.scene.ui.layout.Table;
|
|||||||
import io.anuke.mindustry.entities.type.TileEntity;
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.ui.ReqImage;
|
import io.anuke.mindustry.ui.ReqImage;
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
|
||||||
|
|
||||||
public class ConsumeLiquid extends Consume{
|
public class ConsumeLiquid extends ConsumeLiquidBase{
|
||||||
protected final float use;
|
public final Liquid liquid;
|
||||||
protected final Liquid liquid;
|
|
||||||
|
|
||||||
public ConsumeLiquid(Liquid liquid, float use){
|
public ConsumeLiquid(Liquid liquid, float amount){
|
||||||
|
super(amount);
|
||||||
this.liquid = liquid;
|
this.liquid = liquid;
|
||||||
this.use = use;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public float used(){
|
@Override
|
||||||
return use;
|
public void applyLiquidFilter(boolean[] filter){
|
||||||
}
|
filter[liquid.id] = true;
|
||||||
|
|
||||||
public Liquid get(){
|
|
||||||
return liquid;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void build(Tile tile, Table table){
|
public void build(Tile tile, Table table){
|
||||||
table.add(new ReqImage(liquid.getContentIcon(), () -> valid(tile.block(), tile.entity))).size(8*4);
|
table.add(new ReqImage(liquid.getContentIcon(), () -> valid(tile.entity))).size(8*4);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -38,26 +32,17 @@ public class ConsumeLiquid extends Consume{
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Block block, TileEntity entity){
|
public void update(TileEntity entity){
|
||||||
entity.liquids.remove(liquid, Math.min(use(block, entity), entity.liquids.get(liquid)));
|
entity.liquids.remove(liquid, Math.min(use(entity), entity.liquids.get(liquid)));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean valid(Block block, TileEntity entity){
|
public boolean valid(TileEntity entity){
|
||||||
return entity != null && entity.liquids != null && entity.liquids.get(liquid) >= use(block, entity);
|
return entity != null && entity.liquids != null && entity.liquids.get(liquid) >= use(entity);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void display(BlockStats stats){
|
public void display(BlockStats stats){
|
||||||
if(!boost){
|
stats.add(optional ? BlockStat.booster : BlockStat.input, liquid, amount * timePeriod, timePeriod == 60);
|
||||||
stats.add(BlockStat.liquidUse, use * 60f, StatUnit.liquidSecond);
|
|
||||||
stats.add(BlockStat.inputLiquid, liquid);
|
|
||||||
}else{
|
|
||||||
stats.add(BlockStat.boostLiquid, liquid);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
float use(Block block, TileEntity entity){
|
|
||||||
return Math.min(use * entity.delta(), block.liquidCapacity);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package io.anuke.mindustry.world.consumers;
|
||||||
|
|
||||||
|
import io.anuke.mindustry.entities.type.TileEntity;
|
||||||
|
|
||||||
|
public abstract class ConsumeLiquidBase extends Consume{
|
||||||
|
/**amount used per frame*/
|
||||||
|
public final float amount;
|
||||||
|
/**How much time is taken to use this liquid, in ticks. Used only for visual purposes.
|
||||||
|
* Example: a normal ConsumeLiquid with 10/s and a 10 second timePeriod would display as "100 seconds".
|
||||||
|
* Without a time override, it would display as "10 liquid/second".
|
||||||
|
* This is used for generic crafters.*/
|
||||||
|
public float timePeriod = 60;
|
||||||
|
|
||||||
|
public ConsumeLiquidBase(float amount){
|
||||||
|
this.amount = amount;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ConsumeType type(){
|
||||||
|
return ConsumeType.liquid;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected float use(TileEntity entity){
|
||||||
|
return Math.min(amount * entity.delta(), entity.block.liquidCapacity);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -7,35 +7,31 @@ import io.anuke.mindustry.entities.type.TileEntity;
|
|||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.ui.MultiReqImage;
|
import io.anuke.mindustry.ui.MultiReqImage;
|
||||||
import io.anuke.mindustry.ui.ReqImage;
|
import io.anuke.mindustry.ui.ReqImage;
|
||||||
import io.anuke.mindustry.world.Block;
|
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.Tile;
|
||||||
import io.anuke.mindustry.world.meta.BlockStat;
|
import io.anuke.mindustry.world.meta.BlockStat;
|
||||||
import io.anuke.mindustry.world.meta.BlockStats;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
import io.anuke.mindustry.world.meta.StatUnit;
|
|
||||||
import io.anuke.mindustry.world.meta.values.LiquidFilterValue;
|
import io.anuke.mindustry.world.meta.values.LiquidFilterValue;
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.content;
|
import static io.anuke.mindustry.Vars.content;
|
||||||
|
|
||||||
public class ConsumeLiquidFilter extends Consume{
|
public class ConsumeLiquidFilter extends ConsumeLiquidBase{
|
||||||
private final Predicate<Liquid> filter;
|
public final Predicate<Liquid> filter;
|
||||||
private final float use;
|
|
||||||
private final boolean isFuel;
|
|
||||||
|
|
||||||
public ConsumeLiquidFilter(Predicate<Liquid> liquid, float amount, boolean isFuel){
|
|
||||||
this.filter = liquid;
|
|
||||||
this.use = amount;
|
|
||||||
this.isFuel = isFuel;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ConsumeLiquidFilter(Predicate<Liquid> liquid, float amount){
|
public ConsumeLiquidFilter(Predicate<Liquid> liquid, float amount){
|
||||||
this(liquid, amount, false);
|
super(amount);
|
||||||
|
this.filter = liquid;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void applyLiquidFilter(boolean[] arr){
|
||||||
|
content.liquids().each(filter, item -> arr[item.id] = true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void build(Tile tile, Table table){
|
public void build(Tile tile, Table table){
|
||||||
Array<Liquid> list = content.liquids().select(l -> !l.isHidden() && filter.test(l));
|
Array<Liquid> list = content.liquids().select(l -> !l.isHidden() && filter.test(l));
|
||||||
MultiReqImage image = new MultiReqImage();
|
MultiReqImage image = new MultiReqImage();
|
||||||
list.each(liquid -> image.add(new ReqImage(liquid.getContentIcon(), () -> tile.entity != null && tile.entity.liquids != null && tile.entity.liquids.get(liquid) >= use(tile.block(), tile.entity))));
|
list.each(liquid -> image.add(new ReqImage(liquid.getContentIcon(), () -> tile.entity != null && tile.entity.liquids != null && tile.entity.liquids.get(liquid) >= use(tile.entity))));
|
||||||
|
|
||||||
table.add(image).size(8*4);
|
table.add(image).size(8*4);
|
||||||
}
|
}
|
||||||
@@ -46,29 +42,17 @@ public class ConsumeLiquidFilter extends Consume{
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Block block, TileEntity entity){
|
public void update(TileEntity entity){
|
||||||
entity.liquids.remove(entity.liquids.current(), use(block, entity));
|
entity.liquids.remove(entity.liquids.current(), use(entity));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean valid(Block block, TileEntity entity){
|
public boolean valid(TileEntity entity){
|
||||||
return entity != null && entity.liquids != null && filter.test(entity.liquids.current()) && entity.liquids.currentAmount() >= use(block, entity);
|
return entity != null && entity.liquids != null && filter.test(entity.liquids.current()) && entity.liquids.currentAmount() >= use(entity);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void display(BlockStats stats){
|
public void display(BlockStats stats){
|
||||||
if(boost){
|
stats.add(optional ? BlockStat.booster : BlockStat.input, new LiquidFilterValue(filter, amount * timePeriod, timePeriod == 60f));
|
||||||
stats.add(BlockStat.boostLiquid, new LiquidFilterValue(filter));
|
|
||||||
}else if(isFuel){
|
|
||||||
stats.add(BlockStat.inputLiquidFuel, new LiquidFilterValue(filter));
|
|
||||||
stats.add(BlockStat.liquidFuelUse, 60f * use, StatUnit.liquidSecond);
|
|
||||||
}else {
|
|
||||||
stats.add(BlockStat.inputLiquid, new LiquidFilterValue(filter));
|
|
||||||
stats.add(BlockStat.liquidUse, 60f * use, StatUnit.liquidSecond);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
float use(Block block, TileEntity entity){
|
|
||||||
return Math.min(use * entity.delta(), block.liquidCapacity);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,6 +24,11 @@ public class ConsumePower extends Consume{
|
|||||||
this.isBuffered = isBuffered;
|
this.isBuffered = isBuffered;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ConsumeType type(){
|
||||||
|
return ConsumeType.power;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void build(Tile tile, Table table){
|
public void build(Tile tile, Table table){
|
||||||
//No tooltip for power, for now
|
//No tooltip for power, for now
|
||||||
@@ -35,12 +40,12 @@ public class ConsumePower extends Consume{
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Block block, TileEntity entity){
|
public void update(TileEntity entity){
|
||||||
// Nothing to do since PowerGraph directly updates entity.power.satisfaction
|
// Nothing to do since PowerGraph directly updates entity.power.satisfaction
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean valid(Block block, TileEntity entity){
|
public boolean valid(TileEntity entity){
|
||||||
if(isBuffered){
|
if(isBuffered){
|
||||||
return true;
|
return true;
|
||||||
}else{
|
}else{
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
package io.anuke.mindustry.world.consumers;
|
||||||
|
|
||||||
|
public enum ConsumeType{
|
||||||
|
item,
|
||||||
|
power,
|
||||||
|
liquid
|
||||||
|
}
|
||||||
@@ -1,39 +1,39 @@
|
|||||||
package io.anuke.mindustry.world.consumers;
|
package io.anuke.mindustry.world.consumers;
|
||||||
|
|
||||||
import io.anuke.arc.collection.Array;
|
import io.anuke.arc.util.Structs;
|
||||||
import io.anuke.arc.collection.ObjectMap;
|
import io.anuke.mindustry.Vars;
|
||||||
import io.anuke.arc.collection.ObjectSet;
|
|
||||||
import io.anuke.arc.function.Consumer;
|
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
import io.anuke.mindustry.type.ItemStack;
|
import io.anuke.mindustry.type.ItemStack;
|
||||||
import io.anuke.mindustry.type.Liquid;
|
import io.anuke.mindustry.type.Liquid;
|
||||||
import io.anuke.mindustry.world.Block;
|
import io.anuke.mindustry.world.meta.BlockStats;
|
||||||
|
|
||||||
public class Consumers{
|
public class Consumers{
|
||||||
private ObjectMap<Class<? extends Consume>, Consume> map = new ObjectMap<>();
|
private Consume[] map = new Consume[ConsumeType.values().length];
|
||||||
private ObjectSet<Class<? extends Consume>> required = new ObjectSet<>();
|
private Consume[] results, optionalResults;
|
||||||
private Array<Consume> results = new Array<>();
|
|
||||||
|
|
||||||
public void require(Class<? extends Consume> type){
|
public final boolean[] itemFilters = new boolean[Vars.content.items().size];
|
||||||
required.add(type);
|
public final boolean[] liquidfilters = new boolean[Vars.content.liquids().size];
|
||||||
}
|
|
||||||
|
|
||||||
public void checkRequired(Block block){
|
public void init(){
|
||||||
for(Class<? extends Consume> c : required){
|
results = Structs.filter(Consume.class, map, m -> m != null);
|
||||||
if(!map.containsKey(c)){
|
optionalResults = Structs.filter(Consume.class, map, m -> m != null && m.isOptional());
|
||||||
throw new RuntimeException("Missing required consumer of type \"" + c + "\" in block \"" + block.name + "\"!");
|
|
||||||
|
for(Consume cons : results){
|
||||||
|
cons.applyItemFilter(itemFilters);
|
||||||
|
cons.applyLiquidFilter(liquidfilters);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for(Consume cons : map.values()){
|
public ConsumePower getPower(){
|
||||||
results.add(cons);
|
return get(ConsumeType.power);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean hasPower(){
|
||||||
|
return has(ConsumeType.power);
|
||||||
}
|
}
|
||||||
|
|
||||||
public ConsumeLiquid liquid(Liquid liquid, float amount){
|
public ConsumeLiquid liquid(Liquid liquid, float amount){
|
||||||
ConsumeLiquid c = new ConsumeLiquid(liquid, amount);
|
return add(new ConsumeLiquid(liquid, amount));
|
||||||
add(c);
|
|
||||||
return c;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -42,9 +42,7 @@ public class Consumers{
|
|||||||
* @return the created consumer object.
|
* @return the created consumer object.
|
||||||
*/
|
*/
|
||||||
public ConsumePower power(float powerPerTick){
|
public ConsumePower power(float powerPerTick){
|
||||||
ConsumePower c = new ConsumePower(powerPerTick, 0.0f, false);
|
return add(new ConsumePower(powerPerTick, 0.0f, false));
|
||||||
add(c);
|
|
||||||
return c;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -62,83 +60,55 @@ public class Consumers{
|
|||||||
* @param ticksToFill The number of ticks it shall take to fill the buffer.
|
* @param ticksToFill The number of ticks it shall take to fill the buffer.
|
||||||
*/
|
*/
|
||||||
public ConsumePower powerBuffered(float powerCapacity, float ticksToFill){
|
public ConsumePower powerBuffered(float powerCapacity, float ticksToFill){
|
||||||
ConsumePower c = new ConsumePower(powerCapacity / ticksToFill, powerCapacity, true);
|
return add(new ConsumePower(powerCapacity / ticksToFill, powerCapacity, true));
|
||||||
add(c);
|
|
||||||
return c;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public ConsumeItem item(Item item){
|
public ConsumeItems item(Item item){
|
||||||
return item(item, 1);
|
return item(item, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
public ConsumeItem item(Item item, int amount){
|
public ConsumeItems item(Item item, int amount){
|
||||||
ConsumeItem i = new ConsumeItem(item, amount);
|
return add(new ConsumeItems(new ItemStack[]{new ItemStack(item, amount)}));
|
||||||
add(i);
|
|
||||||
return i;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public ConsumeItems items(ItemStack... items){
|
public ConsumeItems items(ItemStack... items){
|
||||||
ConsumeItems i = new ConsumeItems(items);
|
return add(new ConsumeItems(items));
|
||||||
add(i);
|
|
||||||
return i;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public Item item(){
|
public <T extends Consume> T add(T consume){
|
||||||
return get(ConsumeItem.class).get();
|
map[consume.type().ordinal()] = consume;
|
||||||
}
|
|
||||||
|
|
||||||
public ItemStack[] items(){
|
|
||||||
return get(ConsumeItems.class).getItems();
|
|
||||||
}
|
|
||||||
|
|
||||||
public int itemAmount(){
|
|
||||||
return get(ConsumeItem.class).getAmount();
|
|
||||||
}
|
|
||||||
|
|
||||||
public Liquid liquid(){
|
|
||||||
return get(ConsumeLiquid.class).get();
|
|
||||||
}
|
|
||||||
|
|
||||||
public float liquidAmount(){
|
|
||||||
return get(ConsumeLiquid.class).use;
|
|
||||||
}
|
|
||||||
|
|
||||||
public Consume add(Consume consume){
|
|
||||||
map.put((consume instanceof ConsumePower ? ConsumePower.class : consume.getClass()), consume);
|
|
||||||
return consume;
|
return consume;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void remove(Class<? extends Consume> type){
|
public void remove(ConsumeType type){
|
||||||
map.remove(type);
|
map[type.ordinal()] = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean has(Class<? extends Consume> type){
|
public boolean has(ConsumeType type){
|
||||||
return map.containsKey(type);
|
return map[type.ordinal()] != null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
public <T extends Consume> T get(Class<T> type){
|
public <T extends Consume> T get(ConsumeType type){
|
||||||
if(!map.containsKey(type)){
|
if(map[type.ordinal()] == null){
|
||||||
throw new IllegalArgumentException("Block does not contain consumer of type '" + type + "'!");
|
throw new IllegalArgumentException("Block does not contain consumer of type '" + type + "'!");
|
||||||
}
|
}
|
||||||
return (T) map.get(type);
|
return (T) map[type.ordinal()];
|
||||||
}
|
}
|
||||||
|
|
||||||
public Iterable<Consume> all(){
|
public Consume[] all(){
|
||||||
return map.values();
|
|
||||||
}
|
|
||||||
|
|
||||||
public Array<Consume> array(){
|
|
||||||
return results;
|
return results;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean hasAny(){
|
public Consume[] optionals(){
|
||||||
return map.size > 0;
|
return optionalResults;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void forEach(Consumer<Consume> cons){
|
public void display(BlockStats stats){
|
||||||
for(Consume c : all()){
|
for(Consume c : map){
|
||||||
cons.accept(c);
|
if(c != null){
|
||||||
|
c.display(stats);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,38 +10,25 @@ public enum BlockStat{
|
|||||||
size(StatCategory.general),
|
size(StatCategory.general),
|
||||||
|
|
||||||
itemCapacity(StatCategory.items),
|
itemCapacity(StatCategory.items),
|
||||||
inputItemCapacity(StatCategory.items),
|
|
||||||
outputItemCapacity(StatCategory.items),
|
|
||||||
itemsMoved(StatCategory.items),
|
itemsMoved(StatCategory.items),
|
||||||
launchTime(StatCategory.items),
|
launchTime(StatCategory.items),
|
||||||
|
|
||||||
liquidCapacity(StatCategory.liquids),
|
liquidCapacity(StatCategory.liquids),
|
||||||
liquidOutput(StatCategory.liquids),
|
|
||||||
liquidOutputSpeed(StatCategory.liquids),
|
|
||||||
coolant(StatCategory.liquids),
|
|
||||||
coolantUse(StatCategory.liquids),
|
|
||||||
|
|
||||||
powerCapacity(StatCategory.power),
|
powerCapacity(StatCategory.power),
|
||||||
powerUse(StatCategory.power),
|
powerUse(StatCategory.power),
|
||||||
powerDamage(StatCategory.power),
|
powerDamage(StatCategory.power),
|
||||||
powerRange(StatCategory.power),
|
powerRange(StatCategory.power),
|
||||||
powerTransferSpeed(StatCategory.power),
|
|
||||||
basePowerGeneration(StatCategory.power),
|
basePowerGeneration(StatCategory.power),
|
||||||
inputLiquidFuel(StatCategory.power),
|
|
||||||
liquidFuelUse(StatCategory.power),
|
|
||||||
|
|
||||||
inputLiquid(StatCategory.crafting),
|
input(StatCategory.crafting),
|
||||||
liquidUse(StatCategory.crafting),
|
output(StatCategory.crafting),
|
||||||
inputItem(StatCategory.crafting),
|
productionTime(StatCategory.crafting),
|
||||||
inputItems(StatCategory.crafting),
|
|
||||||
inputFuel(StatCategory.crafting),
|
|
||||||
fuelBurnTime(StatCategory.crafting),
|
|
||||||
craftSpeed(StatCategory.crafting),
|
|
||||||
outputItem(StatCategory.crafting),
|
|
||||||
drillTier(StatCategory.crafting),
|
drillTier(StatCategory.crafting),
|
||||||
drillSpeed(StatCategory.crafting),
|
drillSpeed(StatCategory.crafting),
|
||||||
maxUnits(StatCategory.crafting),
|
maxUnits(StatCategory.crafting),
|
||||||
|
|
||||||
|
speedIncrease(StatCategory.shooting),
|
||||||
repairTime(StatCategory.shooting),
|
repairTime(StatCategory.shooting),
|
||||||
range(StatCategory.shooting),
|
range(StatCategory.shooting),
|
||||||
shootRange(StatCategory.shooting),
|
shootRange(StatCategory.shooting),
|
||||||
@@ -53,9 +40,8 @@ public enum BlockStat{
|
|||||||
targetsGround(StatCategory.shooting),
|
targetsGround(StatCategory.shooting),
|
||||||
ammo(StatCategory.shooting),
|
ammo(StatCategory.shooting),
|
||||||
|
|
||||||
boostItem(StatCategory.optional),
|
booster(StatCategory.optional),
|
||||||
boostLiquid(StatCategory.optional),
|
boostEffect(StatCategory.optional)
|
||||||
|
|
||||||
;
|
;
|
||||||
|
|
||||||
public final StatCategory category;
|
public final StatCategory category;
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package io.anuke.mindustry.world.meta;
|
package io.anuke.mindustry.world.meta;
|
||||||
|
|
||||||
|
import io.anuke.arc.collection.Array;
|
||||||
import io.anuke.arc.collection.ObjectMap.Entry;
|
import io.anuke.arc.collection.ObjectMap.Entry;
|
||||||
import io.anuke.arc.collection.OrderedMap;
|
import io.anuke.arc.collection.OrderedMap;
|
||||||
import io.anuke.mindustry.type.Item;
|
import io.anuke.mindustry.type.Item;
|
||||||
@@ -9,7 +10,7 @@ import io.anuke.mindustry.world.meta.values.*;
|
|||||||
|
|
||||||
/**Hold and organizes a list of block stats.*/
|
/**Hold and organizes a list of block stats.*/
|
||||||
public class BlockStats{
|
public class BlockStats{
|
||||||
private final OrderedMap<StatCategory, OrderedMap<BlockStat, StatValue>> map = new OrderedMap<>();
|
private final OrderedMap<StatCategory, OrderedMap<BlockStat, Array<StatValue>>> map = new OrderedMap<>();
|
||||||
private boolean dirty;
|
private boolean dirty;
|
||||||
|
|
||||||
/**Adds a single float value with this stat, formatted to 2 decimal places.*/
|
/**Adds a single float value with this stat, formatted to 2 decimal places.*/
|
||||||
@@ -24,17 +25,17 @@ public class BlockStats{
|
|||||||
|
|
||||||
/**Adds an item value.*/
|
/**Adds an item value.*/
|
||||||
public void add(BlockStat stat, Item item){
|
public void add(BlockStat stat, Item item){
|
||||||
add(stat, new ItemValue(new ItemStack(item, 1)));
|
add(stat, new ItemListValue(new ItemStack(item, 1)));
|
||||||
}
|
|
||||||
|
|
||||||
/**Adds a liquid value.*/
|
|
||||||
public void add(BlockStat stat, Liquid liquid){
|
|
||||||
add(stat, new LiquidValue(liquid));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**Adds an item value.*/
|
/**Adds an item value.*/
|
||||||
public void add(BlockStat stat, ItemStack item){
|
public void add(BlockStat stat, ItemStack item){
|
||||||
add(stat, new ItemValue(item));
|
add(stat, new ItemListValue(item));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**Adds an item value.*/
|
||||||
|
public void add(BlockStat stat, Liquid liquid, float amount, boolean perSecond){
|
||||||
|
add(stat, new LiquidValue(liquid, amount, perSecond));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**Adds a single string value with this stat.*/
|
/**Adds a single string value with this stat.*/
|
||||||
@@ -44,15 +45,11 @@ public class BlockStats{
|
|||||||
|
|
||||||
/**Adds a stat value.*/
|
/**Adds a stat value.*/
|
||||||
public void add(BlockStat stat, StatValue value){
|
public void add(BlockStat stat, StatValue value){
|
||||||
if(map.containsKey(stat.category) && map.get(stat.category).containsKey(stat)){
|
|
||||||
throw new RuntimeException("Duplicate stat entry: \"" + stat + "\" in block.");
|
|
||||||
}
|
|
||||||
|
|
||||||
if(!map.containsKey(stat.category)){
|
if(!map.containsKey(stat.category)){
|
||||||
map.put(stat.category, new OrderedMap<>());
|
map.put(stat.category, new OrderedMap<>());
|
||||||
}
|
}
|
||||||
|
|
||||||
map.get(stat.category).put(stat, value);
|
map.get(stat.category).getOr(stat, Array::new).add(value);
|
||||||
|
|
||||||
dirty = true;
|
dirty = true;
|
||||||
}
|
}
|
||||||
@@ -68,11 +65,11 @@ public class BlockStats{
|
|||||||
dirty = true;
|
dirty = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public OrderedMap<StatCategory, OrderedMap<BlockStat, StatValue>> toMap(){
|
public OrderedMap<StatCategory, OrderedMap<BlockStat, Array<StatValue>>> toMap(){
|
||||||
//sort stats by index if they've been modified
|
//sort stats by index if they've been modified
|
||||||
if(dirty){
|
if(dirty){
|
||||||
map.orderedKeys().sort();
|
map.orderedKeys().sort();
|
||||||
for(Entry<StatCategory, OrderedMap<BlockStat, StatValue>> entry : map.entries()){
|
for(Entry<StatCategory, OrderedMap<BlockStat, Array<StatValue>>> entry : map.entries()){
|
||||||
entry.value.orderedKeys().sort();
|
entry.value.orderedKeys().sort();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user