Misc fog improvements
This commit is contained in:
@@ -446,6 +446,11 @@ abstract class BuildingComp implements Posc, Teamc, Healthc, Buildingc, Timerc,
|
||||
return nearby(Geometry.d4(rotation + 3).x * trns, Geometry.d4(rotation + 3).y * trns);
|
||||
}
|
||||
|
||||
/** Any class that overrides this method and changes the value must call Vars.fogControl.forceUpdate(team). */
|
||||
public float fogRadius(){
|
||||
return block.fogRadius;
|
||||
}
|
||||
|
||||
public int pos(){
|
||||
return tile.pos();
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ abstract class MechComp implements Posc, Flyingc, Hitboxc, Unitc, Mechc, Elevati
|
||||
|
||||
float lastExtend = walkExtension;
|
||||
|
||||
if(extendScl < lastExtend && base % 2f > 1f && !isFlying()){
|
||||
if(!headless && extendScl < lastExtend && base % 2f > 1f && !isFlying() && !inFogTo(player.team())){
|
||||
int side = -Mathf.sign(extend);
|
||||
float width = hitSize / 2f * side, length = type.mechStride * 1.35f;
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ abstract class TankComp implements Posc, Flyingc, Hitboxc, Unitc, ElevationMovec
|
||||
@Override
|
||||
public void update(){
|
||||
//dust
|
||||
if(walked && !headless){
|
||||
if(walked && !headless && !inFogTo(player.team())){
|
||||
treadEffectTime += Time.delta;
|
||||
if(treadEffectTime >= 6f && type.treadRects.length > 0){
|
||||
var treadRegion = type.treadRegion;
|
||||
|
||||
Reference in New Issue
Block a user