Bugfixes
This commit is contained in:
@@ -400,7 +400,7 @@ public class UnitTypes implements ContentList{
|
||||
|
||||
hovering = true;
|
||||
allowLegStep = true;
|
||||
visualElevation = 0.4f;
|
||||
visualElevation = 0.65f;
|
||||
groundLayer = Layer.legUnit;
|
||||
|
||||
BulletType sapper = new SapBulletType(){{
|
||||
@@ -474,7 +474,7 @@ public class UnitTypes implements ContentList{
|
||||
|
||||
toxopid = new UnitType("toxopid"){{
|
||||
drag = 0.1f;
|
||||
speed = 0.6f;
|
||||
speed = 0.5f;
|
||||
hitsize = 21f;
|
||||
health = 23000;
|
||||
armor = 14f;
|
||||
@@ -489,7 +489,7 @@ public class UnitTypes implements ContentList{
|
||||
legBaseOffset = 8f;
|
||||
landShake = 1f;
|
||||
legSpeed = 0.1f;
|
||||
legLengthScl = 1f;
|
||||
legLengthScl = 0.93f;
|
||||
rippleScale = 3f;
|
||||
legSpeed = 0.19f;
|
||||
|
||||
@@ -498,7 +498,7 @@ public class UnitTypes implements ContentList{
|
||||
|
||||
hovering = true;
|
||||
allowLegStep = true;
|
||||
visualElevation = 0.43f;
|
||||
visualElevation = 0.95f;
|
||||
groundLayer = Layer.legUnit;
|
||||
|
||||
weapons.add(
|
||||
|
||||
@@ -261,7 +261,7 @@ public class UnitType extends UnlockableContent{
|
||||
drawControl(unit);
|
||||
}
|
||||
|
||||
if(unit.isFlying()){
|
||||
if(unit.isFlying() || visualElevation > 0){
|
||||
Draw.z(Math.min(Layer.darkness, z - 1f));
|
||||
drawShadow(unit);
|
||||
}
|
||||
@@ -478,7 +478,6 @@ public class UnitType extends UnlockableContent{
|
||||
}
|
||||
|
||||
public <T extends Unit & Legsc> void drawLegs(T unit){
|
||||
//Draw.z(Layer.groundUnit - 0.02f);
|
||||
|
||||
Leg[] legs = unit.legs();
|
||||
|
||||
@@ -494,8 +493,9 @@ public class UnitType extends UnlockableContent{
|
||||
Draw.rect(baseRegion, unit.x, unit.y, rotation);
|
||||
}
|
||||
|
||||
//TODO figure out layering
|
||||
for(int i = 0; i < legs.length; i++){
|
||||
//legs are drawn front first
|
||||
for(int j = legs.length - 1; j >= 0; j--){
|
||||
int i = (j % 2 == 0 ? j/2 : legs.length - 1 - j/2);
|
||||
Leg leg = legs[i];
|
||||
float angle = unit.legAngle(rotation, i);
|
||||
boolean flip = i >= legs.length/2f;
|
||||
|
||||
Reference in New Issue
Block a user