Fixed #2729
This commit is contained in:
@@ -16,7 +16,7 @@ public class FlyingAI extends AIController{
|
||||
moveTo(target, unit.range() * 0.8f);
|
||||
unit.lookAt(target);
|
||||
}else{
|
||||
attack(80f);
|
||||
attack(100f);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -885,7 +885,7 @@ public class UnitTypes implements ContentList{
|
||||
weapons.add(new Weapon(){{
|
||||
y = 0f;
|
||||
x = 2f;
|
||||
reload = 15f;
|
||||
reload = 13f;
|
||||
ejectEffect = Fx.shellEjectSmall;
|
||||
bullet = Bullets.standardCopper;
|
||||
shootSound = Sounds.shoot;
|
||||
|
||||
@@ -170,12 +170,13 @@ public class Weathers implements ContentList{
|
||||
sandstorm = new Weather("sandstorm"){
|
||||
TextureRegion region;
|
||||
float size = 140f, padding = size, invDensity = 1500f, baseSpeed = 6.1f;
|
||||
float force = 0.45f;
|
||||
float force = 0.4f;
|
||||
Color color = Color.valueOf("f7cba4");
|
||||
Texture noise;
|
||||
|
||||
{
|
||||
attrs.set(Attribute.light, -0.1f);
|
||||
opacityMultiplier = 0.85f;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -17,7 +17,8 @@ import static mindustry.Vars.*;
|
||||
|
||||
public abstract class Weather extends UnlockableContent{
|
||||
/** Default duration of this weather event in ticks. */
|
||||
public float duration = 9f * Time.toMinutes;
|
||||
public float duration = 8f * Time.toMinutes;
|
||||
public float opacityMultiplier = 1f;
|
||||
public Attributes attrs = new Attributes();
|
||||
|
||||
//internals
|
||||
@@ -122,7 +123,7 @@ public abstract class Weather extends UnlockableContent{
|
||||
|
||||
/** Creates a weather entry with some approximate weather values. */
|
||||
public WeatherEntry(Weather weather){
|
||||
this(weather, weather.duration * 1f, weather.duration * 3f, weather.duration / 2f, weather.duration * 1.5f);
|
||||
this(weather, weather.duration * 3f, weather.duration * 6f, weather.duration / 2f, weather.duration * 1.5f);
|
||||
}
|
||||
|
||||
public WeatherEntry(Weather weather, float minFrequency, float maxFrequency, float minDuration, float maxDuration){
|
||||
@@ -177,14 +178,14 @@ public abstract class Weather extends UnlockableContent{
|
||||
if(renderer.weatherAlpha() > 0.0001f){
|
||||
Draw.draw(Layer.weather, () -> {
|
||||
weather.rand.setSeed(0);
|
||||
Draw.alpha(renderer.weatherAlpha() * opacity);
|
||||
Draw.alpha(renderer.weatherAlpha() * opacity * weather.opacityMultiplier);
|
||||
weather.drawOver(self());
|
||||
Draw.reset();
|
||||
});
|
||||
|
||||
Draw.draw(Layer.debris, () -> {
|
||||
weather.rand.setSeed(0);
|
||||
Draw.alpha(renderer.weatherAlpha() * opacity);
|
||||
Draw.alpha(renderer.weatherAlpha() * opacity * weather.opacityMultiplier);
|
||||
weather.drawUnder(self());
|
||||
Draw.reset();
|
||||
});
|
||||
|
||||
@@ -105,7 +105,10 @@ public class Build{
|
||||
int wx = dx + offsetx + x, wy = dy + offsety + y;
|
||||
|
||||
Tile check = world.tile(wx, wy);
|
||||
if(check == null || !check.interactable(team) || (!check.block.alwaysReplace && check.block != tile.block && !(check.block.size == 1 && type.canReplace(check.block)))) return false;
|
||||
if(check == null ||
|
||||
(check.floor().isDeep() && !type.floating && !type.requiresWater && !type.placeableLiquid) ||
|
||||
!check.interactable(team) ||
|
||||
(!check.block.alwaysReplace && check.block != tile.block && !(check.block.size == 1 && type.canReplace(check.block)))) return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user