Many bugfixes
This commit is contained in:
@@ -152,13 +152,13 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
|
||||
public boolean inFogTo(Team viewer){
|
||||
if(this.team == viewer || !state.rules.fog) return false;
|
||||
|
||||
if(hitSize <= 14f){
|
||||
if(hitSize <= 16f){
|
||||
return !fogControl.isVisible(viewer, x, y);
|
||||
}else{
|
||||
//for large hitsizes, check around the unit instead
|
||||
float trns = hitSize / 2f;
|
||||
for(var p : Geometry.d8){
|
||||
if(fogControl.isVisible(team, x + p.x * trns, y + p.y * trns)){
|
||||
if(fogControl.isVisible(viewer, x + p.x * trns, y + p.y * trns)){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user