Merge remote-tracking branch 'origin/7.0-features' into 7.0-features

This commit is contained in:
Epowerj
2022-05-02 15:47:36 -04:00
16 changed files with 108 additions and 27 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 319 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 483 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 696 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

View File

@@ -1942,12 +1942,12 @@ block.cyanogen-synthesizer.name = Cyanogen Synthesizer
block.phase-synthesizer.name = Phase Synthesizer block.phase-synthesizer.name = Phase Synthesizer
block.heat-reactor.name = Heat Reactor block.heat-reactor.name = Heat Reactor
block.beryllium-wall.name = Beryllium Wall block.beryllium-wall.name = Beryllium Wall
block.beryllium-wall-large.name = Beryllium Wall Large block.beryllium-wall-large.name = Large Beryllium Wall
block.tungsten-wall.name = Tungsten Wall block.tungsten-wall.name = Tungsten Wall
block.tungsten-wall-large.name = Tungsten Wall Large block.tungsten-wall-large.name = Large Tungsten Wall
block.blast-door.name = Blast Door block.blast-door.name = Blast Door
block.carbide-wall.name = Carbide Wall block.carbide-wall.name = Carbide Wall
block.carbide-wall-large.name = Carbide Wall Large block.carbide-wall-large.name = Large Carbide Wall
block.radar.name = Radar block.radar.name = Radar
block.build-tower.name = Build Tower block.build-tower.name = Build Tower
block.regen-projector.name = Regen Projector block.regen-projector.name = Regen Projector
@@ -2002,6 +2002,12 @@ block.small-deconstructor.name = Small Deconstructor
block.canvas.name = Canvas block.canvas.name = Canvas
block.world-processor.name = World Processor block.world-processor.name = World Processor
block.world-cell.name = World Cell block.world-cell.name = World Cell
block.shield-breaker.name = Shield Breaker
block.tank-fabricator.name = Tank Fabricator
block.mech-fabricator.name = Mech Fabricator
block.ship-fabricator.name = Ship Fabricator
block.basic-reconstructor.name = Basic Reconstructor
block.unit-repair-tower.name = Unit Repair Tower
status.slow.name = Slow status.slow.name = Slow
status.shielded.name = Shielded status.shielded.name = Shielded
status.corroded.name = Corroded status.corroded.name = Corroded
@@ -2015,15 +2021,18 @@ unit.bulwark.name = Bulwark
unit.krepost.name = Krepost unit.krepost.name = Krepost
unit.avert.name = Avert unit.avert.name = Avert
unit.quell.name = Quell unit.quell.name = Quell
unit.quell-missile.name = Quell Missile
unit.disrupt.name = Disrupt unit.disrupt.name = Disrupt
unit.disrupt-missile.name = Disrupt Missile
unit.evoke.name = Evoke unit.evoke.name = Evoke
unit.incite.name = Incite unit.incite.name = Incite
unit.emanate.name = Emanate unit.emanate.name = Emanate
unit.manifold.name = Manifold unit.manifold.name = Manifold
unit.assembly-drone.name = Assembly Drone unit.assembly-drone.name = Assembly Drone
unit.effect-drone.name = Effect Drone unit.effect-drone.name = Effect Drone
unit.precept.name = Precept
unit.merui.name = Merui
unit.anthicus.name = Anthicus
unit.osc.name = Osc
unit.obviate.name = Obviate
sector.two.name = Two sector.two.name = Two
sector.three.name = Three sector.three.name = Three
sector.four.name = Four sector.four.name = Four

View File

@@ -557,3 +557,4 @@
63135=unit-repair-tower|block-unit-repair-tower-ui 63135=unit-repair-tower|block-unit-repair-tower-ui
63134=merui|unit-merui-ui 63134=merui|unit-merui-ui
63133=osc|unit-osc-ui 63133=osc|unit-osc-ui
63132=precept|unit-precept-ui

Binary file not shown.

View File

@@ -824,12 +824,6 @@ public class Fx{
Drawf.light(e.x, e.y, 23f, e.color, e.fout() * 0.7f); Drawf.light(e.x, e.y, 23f, e.color, e.fout() * 0.7f);
}), }),
hitYellowLaser = new Effect(8, e -> {
color(Color.white, Pal.lightTrail, e.fin());
stroke(0.5f + e.fout());
Lines.circle(e.x, e.y, e.fin() * 5f);
}),
despawn = new Effect(12, e -> { despawn = new Effect(12, e -> {
color(Pal.lighterOrange, Color.gray, e.fin()); color(Pal.lighterOrange, Color.gray, e.fin());
stroke(e.fout()); stroke(e.fout());

View File

@@ -80,7 +80,7 @@ public class UnitTypes{
public static @EntityDef({Unitc.class, BuildingTetherc.class, Payloadc.class}) UnitType manifold, assemblyDrone, effectDrone; public static @EntityDef({Unitc.class, BuildingTetherc.class, Payloadc.class}) UnitType manifold, assemblyDrone, effectDrone;
//tank //tank
public static @EntityDef({Unitc.class, Tankc.class}) UnitType stell, locus, vanquish, conquer; public static @EntityDef({Unitc.class, Tankc.class}) UnitType stell, locus, precept, vanquish, conquer;
//endregion //endregion
@@ -2585,6 +2585,72 @@ public class UnitTypes{
}}); }});
}}; }};
precept = new TankUnitType("precept"){{
hitSize = 26f;
treadPullOffset = 5;
speed = 0.64f;
rotateSpeed = 1.5f;
health = 4500;
armor = 10f;
itemCapacity = 0;
treadRects = new Rect[]{new Rect(16, 38, 30, 75), new Rect(44, 7, 17, 60)};
researchCostMultiplier = 0f;
weapons.add(new Weapon("precept-weapon"){{
layerOffset = 0.0001f;
reload = 85f;
shootY = 16f;
recoil = 3f;
rotate = true;
rotateSpeed = 1.3f;
mirror = false;
shootCone = 2f;
x = 0f;
y = -1f;
heatColor = Color.valueOf("f9350f");
cooldownTime = 30f;
bullet = new BasicBulletType(7f, 90){{
sprite = "missile-large";
width = 7.5f;
height = 13f;
lifetime = 28f;
hitSize = 6f;
pierceCap = 2;
pierce = true;
pierceBuilding = true;
hitColor = backColor = trailColor = Color.valueOf("feb380");
frontColor = Color.white;
trailWidth = 2.8f;
trailLength = 8;
hitEffect = despawnEffect = Fx.blastExplosion;
shootEffect = Fx.shootTitan;
smokeEffect = Fx.shootSmokeTitan;
splashDamageRadius = 20f;
splashDamage = 50f;
trailEffect = Fx.hitSquaresColor;
trailRotation = true;
trailInterval = 3f;
fragBullets = 4;
fragBullet = new BasicBulletType(5f, 25){{
sprite = "missile-large";
width = 5f;
height = 7f;
lifetime = 15f;
hitSize = 4f;
hitColor = backColor = trailColor = Color.valueOf("feb380");
frontColor = Color.white;
trailWidth = 1.7f;
trailLength = 3;
drag = 0.01f;
despawnEffect = hitEffect = Fx.hitBulletColor;
}};
}};
}});
}};
vanquish = new TankUnitType("vanquish"){{ vanquish = new TankUnitType("vanquish"){{
hitSize = 28f; hitSize = 28f;
treadPullOffset = 4; treadPullOffset = 4;
@@ -2597,7 +2663,7 @@ public class UnitTypes{
weapons.add(new Weapon("vanquish-weapon"){{ weapons.add(new Weapon("vanquish-weapon"){{
layerOffset = 0.0001f; layerOffset = 0.0001f;
reload = 120f; reload = 110f;
shootY = 71f / 4f; shootY = 71f / 4f;
shake = 5f; shake = 5f;
recoil = 4f; recoil = 4f;
@@ -2610,7 +2676,7 @@ public class UnitTypes{
heatColor = Color.valueOf("f9350f"); heatColor = Color.valueOf("f9350f");
cooldownTime = 80f; cooldownTime = 80f;
bullet = new BasicBulletType(8f, 130){{ bullet = new BasicBulletType(8f, 140){{
sprite = "missile-large"; sprite = "missile-large";
width = 9.5f; width = 9.5f;
height = 15f; height = 15f;
@@ -2618,7 +2684,7 @@ public class UnitTypes{
hitSize = 6f; hitSize = 6f;
shootEffect = Fx.shootTitan; shootEffect = Fx.shootTitan;
smokeEffect = Fx.shootSmokeTitan; smokeEffect = Fx.shootSmokeTitan;
pierceCap = 2; pierceCap = 3;
pierce = true; pierce = true;
pierceBuilding = true; pierceBuilding = true;
hitColor = backColor = trailColor = Color.valueOf("feb380"); hitColor = backColor = trailColor = Color.valueOf("feb380");

View File

@@ -25,6 +25,7 @@ import mindustry.world.blocks.defense.Wall.*;
import static mindustry.Vars.*; import static mindustry.Vars.*;
//TODO document
public class BulletType extends Content implements Cloneable{ public class BulletType extends Content implements Cloneable{
/** Lifetime in ticks. */ /** Lifetime in ticks. */
public float lifetime = 40f; public float lifetime = 40f;

View File

@@ -332,7 +332,7 @@ public class BlockRenderer{
procLinks.clear(); procLinks.clear();
procLights.clear(); procLights.clear();
var bounds = camera.bounds(Tmp.r3).grow(tilesize); var bounds = camera.bounds(Tmp.r3).grow(tilesize * 2f);
//draw floor lights //draw floor lights
floorTree.intersect(bounds, tile -> lightview.add(tile)); floorTree.intersect(bounds, tile -> lightview.add(tile));

View File

@@ -362,17 +362,26 @@ public class UnitType extends UnlockableContent{
/** how much of a top part of a tread sprite is "cut off" relative to the pattern; this is corrected for */ /** how much of a top part of a tread sprite is "cut off" relative to the pattern; this is corrected for */
public int treadPullOffset = 0; public int treadPullOffset = 0;
//SEGMENTED / CRAWL UNITS //SEGMENTED / CRAWL UNITS (this is WIP content!)
//for crawlers /** number of independent segments */
public int segments = 0; public int segments = 0;
public float segmentSpacing = 2f, segmentScl = 4f, segmentPhase = 5f, segmentRotSpeed = 1f, segmentMaxRot = 30f; /** magnitude of sine offset between segments */
public float segmentMag = 2f,
/** scale of sine offset between segments */
segmentScl = 4f,
/** index multiplier of sine offset between segments */
segmentPhase = 5f,
/** how fast each segment moves towards the next one */
segmentRotSpeed = 1f,
/** maximum difference between segment angles */
segmentMaxRot = 30f,
/** speed multiplier this unit will have when crawlSlowdownFrac is met. */ /** speed multiplier this unit will have when crawlSlowdownFrac is met. */
public float crawlSlowdown = 0.5f; crawlSlowdown = 0.5f,
/** damage dealt to blocks under this tank/crawler every frame. */ /** damage dealt to blocks under this tank/crawler every frame. */
public float crushDamage = 0f; crushDamage = 0f,
/** the fraction of solids under this block necessary for it to reach crawlSlowdown. */ /** the fraction of solids under this block necessary for it to reach crawlSlowdown. */
public float crawlSlowdownFrac = 0.55f; crawlSlowdownFrac = 0.55f;
//MISSILE UNITS //MISSILE UNITS
@@ -1377,6 +1386,7 @@ public class UnitType extends UnlockableContent{
Draw.reset(); Draw.reset();
} }
//TODO
public void drawCrawl(Crawlc crawl){ public void drawCrawl(Crawlc crawl){
Unit unit = (Unit)crawl; Unit unit = (Unit)crawl;
applyColor(unit); applyColor(unit);
@@ -1386,20 +1396,18 @@ public class UnitType extends UnlockableContent{
TextureRegion[] regions = p == 0 ? segmentOutlineRegions : segmentRegions; TextureRegion[] regions = p == 0 ? segmentOutlineRegions : segmentRegions;
for(int i = 0; i < segments; i++){ for(int i = 0; i < segments; i++){
float trns = Mathf.sin(crawl.crawlTime() + i * segmentPhase, segmentScl, segmentSpacing); float trns = Mathf.sin(crawl.crawlTime() + i * segmentPhase, segmentScl, segmentMag);
//at segment 0, rotation = segmentRot, but at the last segment it is rotation //at segment 0, rotation = segmentRot, but at the last segment it is rotation
float rot = Mathf.slerp(crawl.segmentRot(), unit.rotation, i / (float)(segments - 1)); float rot = Mathf.slerp(crawl.segmentRot(), unit.rotation, i / (float)(segments - 1));
float tx = Angles.trnsx(rot, trns), ty = Angles.trnsy(rot, trns); float tx = Angles.trnsx(rot, trns), ty = Angles.trnsy(rot, trns);
//shadow //shadow
Draw.color(0f, 0f, 0f, 0.2f); Draw.color(0f, 0f, 0f, 0.2f);
//Draw.rect(regions[i], unit.x + tx + 2f, unit.y + ty - 2f, rot - 90); //Draw.rect(regions[i], unit.x + tx + 2f, unit.y + ty - 2f, rot - 90);
applyColor(unit); applyColor(unit);
//TODO merge outlines? //TODO merge outlines?
Draw.rect(regions[i], unit.x + tx, unit.y + ty, rot - 90); Draw.rect(regions[i], unit.x + tx, unit.y + ty, rot - 90);
} }

View File

@@ -55,10 +55,12 @@ public class Block extends UnlockableContent implements Senseable{
public boolean acceptsItems = false; public boolean acceptsItems = false;
public boolean separateItemCapacity = false; public boolean separateItemCapacity = false;
/** maximum items this block can carry (usually, this is per-type of item) */
public int itemCapacity = 10; public int itemCapacity = 10;
/** maximum total liquids this block can carry if hasLiquids = true */
public float liquidCapacity = 10f; public float liquidCapacity = 10f;
/** higher numbers increase liquid output speed; TODO remove and replace with better liquids system */
public float liquidPressure = 1f; public float liquidPressure = 1f;
/** If true, this block outputs to its facing direction, when applicable. /** If true, this block outputs to its facing direction, when applicable.
* Used for blending calculations. */ * Used for blending calculations. */
public boolean outputFacing = true; public boolean outputFacing = true;

View File

@@ -25,4 +25,4 @@ org.gradle.caching=true
#used for slow jitpack builds; TODO see if this actually works #used for slow jitpack builds; TODO see if this actually works
org.gradle.internal.http.socketTimeout=100000 org.gradle.internal.http.socketTimeout=100000
org.gradle.internal.http.connectionTimeout=100000 org.gradle.internal.http.connectionTimeout=100000
archash=7f36a32bec archash=9ae34c37ed