Added land effect / Cleanup

This commit is contained in:
Anuken
2018-08-21 13:25:04 -04:00
parent 34f2704dc7
commit 0003a58210
5 changed files with 35 additions and 14 deletions
@@ -11,7 +11,7 @@ import io.anuke.ucore.util.Angles;
import io.anuke.ucore.util.Mathf;
public class UnitFx extends FxList implements ContentList{
public static Effect vtolHover, unitDrop, unitPickup, pickup;
public static Effect vtolHover, unitDrop, unitPickup, unitLand, pickup;
@Override
public void load(){
@@ -32,6 +32,14 @@ public class UnitFx extends FxList implements ContentList{
Draw.reset();
});
unitLand = new GroundEffect(30, e -> {
Draw.color(Palette.lightishGray, e.color, e.rotation);
Angles.randLenVectors(e.id, 6, 17f * e.finpow(), (x, y) -> {
Fill.circle(e.x + x, e.y + y, e.fout() * 4f + 0.3f);
});
Draw.reset();
});
unitPickup = new GroundEffect(18, e -> {
Draw.color(Palette.lightishGray);
Lines.stroke(e.fin() * 2f);