Javelin abilities

This commit is contained in:
Anuken
2018-08-24 17:53:54 -04:00
parent 88ba8f6f55
commit 8c3f3ac304
11 changed files with 579 additions and 505 deletions
@@ -360,9 +360,9 @@ public class Player extends Unit implements BuilderTrait, CarryTrait, ShooterTra
if(mech.flying || boostHeat > 0.001f){
float wobblyness = 0.6f;
trail.update(x + Angles.trnsx(rotation + 180f, 5f) + Mathf.range(wobblyness),
if(!state.isPaused()) trail.update(x + Angles.trnsx(rotation + 180f, 5f) + Mathf.range(wobblyness),
y + Angles.trnsy(rotation + 180f, 5f) + Mathf.range(wobblyness));
trail.draw(Hue.mix(mech.trailColor, mech.trailColorTo, boostHeat, Tmp.c1), 5f * (isFlying() ? 1f : boostHeat));
trail.draw(Hue.mix(mech.trailColor, mech.trailColorTo, mech.flying ? 0f : boostHeat, Tmp.c1), 5f * (isFlying() ? 1f : boostHeat));
}else{
trail.clear();
}
@@ -587,7 +587,7 @@ public class Player extends Unit implements BuilderTrait, CarryTrait, ShooterTra
float baseLerp = mech.getRotationAlpha(this);
if(!isShooting()){
if(!movement.isZero()){
rotation = Mathf.slerpDelta(rotation, movement.angle(), 0.13f * baseLerp);
rotation = Mathf.slerpDelta(rotation, mech.flying ? velocity.angle() : movement.angle(), 0.13f * baseLerp);
}
}else{
float angle = control.input(playerIndex).mouseAngle(x, y);
@@ -36,7 +36,7 @@ public class BasicBulletType extends BulletType{
public float incendChance = 1f;
public float homingPower = 0f;
public float homingRange = 40f;
public float homingRange = 50f;
public TextureRegion backRegion;
public TextureRegion frontRegion;
@@ -14,7 +14,7 @@ public class MissileBulletType extends BasicBulletType{
super(speed, damage, bulletSprite);
backColor = Palette.missileYellowBack;
frontColor = Palette.missileYellow;
homingPower = 6f;
homingPower = 7f;
}
@Override
@@ -149,7 +149,7 @@ public class Lightning extends TimedEntity implements Poolable, DrawTrait{
Draw.color(color, Color.WHITE, fin());
for(int i = 0; i < lines.size; i++){
Vector2 v = lines.get(i);
Lines.stroke(fout() * 3f + 1f - (float) i / lines.size);
Lines.stroke(fout() * 3f * (1.5f - (float) i / lines.size));
Lines.line(lx, ly, v.x, v.y);
lx = v.x;
ly = v.y;