mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-21 13:17:39 +07:00
Illuminator tweaks
This commit is contained in:
@ -1824,10 +1824,10 @@ public class Blocks implements ContentList{
|
|||||||
}};
|
}};
|
||||||
|
|
||||||
illuminator = new LightBlock("illuminator"){{
|
illuminator = new LightBlock("illuminator"){{
|
||||||
requirements(Category.effect, BuildVisibility.lightingOnly, with(Items.graphite, 4, Items.silicon, 2));
|
requirements(Category.effect, BuildVisibility.lightingOnly, with(Items.graphite, 10, Items.silicon, 8));
|
||||||
brightness = 0.67f;
|
brightness = 0.67f;
|
||||||
radius = 120f;
|
radius = 130f;
|
||||||
consumes.power(0.05f);
|
consumes.power(0.06f);
|
||||||
}};
|
}};
|
||||||
|
|
||||||
//endregion
|
//endregion
|
||||||
|
@ -304,7 +304,7 @@ public class UnitTypes implements ContentList{
|
|||||||
immunities = ObjectSet.with(StatusEffects.burning, StatusEffects.melting);
|
immunities = ObjectSet.with(StatusEffects.burning, StatusEffects.melting);
|
||||||
legCount = 6;
|
legCount = 6;
|
||||||
legLength = 13f;
|
legLength = 13f;
|
||||||
legTrns = 0.7f;
|
legTrns = 0.8f;
|
||||||
legMoveSpace = 1.4f;
|
legMoveSpace = 1.4f;
|
||||||
legBaseOffset = 2f;
|
legBaseOffset = 2f;
|
||||||
hovering = true;
|
hovering = true;
|
||||||
|
@ -68,7 +68,6 @@ abstract class PayloadComp implements Posc, Rotc{
|
|||||||
}
|
}
|
||||||
|
|
||||||
boolean dropUnit(UnitPayload payload){
|
boolean dropUnit(UnitPayload payload){
|
||||||
//TODO create an effect here and/or make them be at a lower elevation
|
|
||||||
Unit u = payload.unit;
|
Unit u = payload.unit;
|
||||||
|
|
||||||
//can't drop ground units
|
//can't drop ground units
|
||||||
|
@ -2,6 +2,7 @@ package mindustry.world.blocks.power;
|
|||||||
|
|
||||||
import arc.graphics.*;
|
import arc.graphics.*;
|
||||||
import arc.graphics.g2d.*;
|
import arc.graphics.g2d.*;
|
||||||
|
import arc.math.*;
|
||||||
import arc.scene.ui.layout.*;
|
import arc.scene.ui.layout.*;
|
||||||
import arc.util.*;
|
import arc.util.*;
|
||||||
import arc.util.io.*;
|
import arc.util.io.*;
|
||||||
@ -29,6 +30,7 @@ public class LightBlock extends Block{
|
|||||||
|
|
||||||
public class LightEntity extends Building{
|
public class LightEntity extends Building{
|
||||||
public int color = Pal.accent.rgba();
|
public int color = Pal.accent.rgba();
|
||||||
|
public float smoothTime = 1f;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void draw(){
|
public void draw(){
|
||||||
@ -40,6 +42,11 @@ public class LightBlock extends Block{
|
|||||||
Draw.blend();
|
Draw.blend();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateTile(){
|
||||||
|
smoothTime = Mathf.lerpDelta(smoothTime, timeScale, 0.1f);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void buildConfiguration(Table table){
|
public void buildConfiguration(Table table){
|
||||||
table.button(Icon.pencil, () -> {
|
table.button(Icon.pencil, () -> {
|
||||||
@ -50,7 +57,7 @@ public class LightBlock extends Block{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void drawLight(){
|
public void drawLight(){
|
||||||
Drawf.light(team, x, y, radius, Tmp.c1.set(color), brightness * efficiency());
|
Drawf.light(team, x, y, radius * Math.min(smoothTime, 2f), Tmp.c1.set(color), brightness * efficiency());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Reference in New Issue
Block a user