mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-01-20 09:17:19 +07:00
Better splash damage handling for small radii
This commit is contained in:
parent
a81b5778a0
commit
06b8dd61c7
@ -138,7 +138,7 @@ public class UnitTypes implements ContentList{
|
||||
collides = true;
|
||||
collidesTiles = true;
|
||||
splashDamageRadius = 28f;
|
||||
splashDamage = 54f;
|
||||
splashDamage = 52f;
|
||||
backColor = Pal.bulletYellowBack;
|
||||
frontColor = Pal.bulletYellow;
|
||||
}};
|
||||
|
@ -363,8 +363,7 @@ public class Damage{
|
||||
|
||||
if(ground){
|
||||
if(!complete){
|
||||
//increase damage slightly to compensate for new algorithm
|
||||
tileDamage(team, World.toTile(x), World.toTile(y), radius / tilesize, damage * 1.1f);
|
||||
tileDamage(team, World.toTile(x), World.toTile(y), radius / tilesize, damage);
|
||||
}else{
|
||||
completeDamage(team, x, y, radius, damage);
|
||||
}
|
||||
@ -381,7 +380,7 @@ public class Damage{
|
||||
//this needs to be compensated
|
||||
if(in != null && in.team != team && in.block.size > 1 && in.health > damage){
|
||||
//deal the damage of an entire side + 1, to be equivalent with maximum 'standard' damage
|
||||
in.damage(damage * (in.block.size + 1));
|
||||
in.damage(damage * Math.min((in.block.size + 1), baseRadius * 0.44f));
|
||||
//no need to continue with the explosion
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user