Tank crush damage tweaks
This commit is contained in:
@@ -2438,7 +2438,6 @@ public class UnitTypes{
|
|||||||
rotateSpeed = 3.5f;
|
rotateSpeed = 3.5f;
|
||||||
health = 800;
|
health = 800;
|
||||||
armor = 5f;
|
armor = 5f;
|
||||||
areaDamage = 5f;
|
|
||||||
treadRects = new Rect[]{new Rect(12, 7, 14, 51)};
|
treadRects = new Rect[]{new Rect(12, 7, 14, 51)};
|
||||||
researchCostMultiplier = 0f;
|
researchCostMultiplier = 0f;
|
||||||
|
|
||||||
@@ -2479,7 +2478,6 @@ public class UnitTypes{
|
|||||||
rotateSpeed = 2.6f;
|
rotateSpeed = 2.6f;
|
||||||
health = 2000;
|
health = 2000;
|
||||||
armor = 8f;
|
armor = 8f;
|
||||||
areaDamage = 8f;
|
|
||||||
treadRects = new Rect[]{new Rect(17, 10, 19, 76)};
|
treadRects = new Rect[]{new Rect(17, 10, 19, 76)};
|
||||||
researchCostMultiplier = 0f;
|
researchCostMultiplier = 0f;
|
||||||
|
|
||||||
@@ -2565,7 +2563,7 @@ public class UnitTypes{
|
|||||||
speed = 0.63f;
|
speed = 0.63f;
|
||||||
health = 9000;
|
health = 9000;
|
||||||
armor = 20f;
|
armor = 20f;
|
||||||
areaDamage = 13f;
|
crushDamage = 13f / 5f;
|
||||||
treadRects = new Rect[]{new Rect(22, 16, 28, 130)};
|
treadRects = new Rect[]{new Rect(22, 16, 28, 130)};
|
||||||
|
|
||||||
weapons.add(new Weapon("vanquish-weapon"){{
|
weapons.add(new Weapon("vanquish-weapon"){{
|
||||||
@@ -2637,7 +2635,7 @@ public class UnitTypes{
|
|||||||
speed = 0.48f;
|
speed = 0.48f;
|
||||||
health = 20000;
|
health = 20000;
|
||||||
armor = 25f;
|
armor = 25f;
|
||||||
areaDamage = 30f;
|
crushDamage = 25f / 5f;
|
||||||
rotateSpeed = 0.8f;
|
rotateSpeed = 0.8f;
|
||||||
treadRects = new Rect[]{new Rect(27, 152, 56, 73), new Rect(24, 51 - 9, 29, 17), new Rect(59, 18 - 9, 39, 19)};
|
treadRects = new Rect[]{new Rect(27, 152, 56, 73), new Rect(24, 51 - 9, 29, 17), new Rect(59, 18 - 9, 39, 19)};
|
||||||
|
|
||||||
@@ -3358,7 +3356,7 @@ public class UnitTypes{
|
|||||||
drawCell = false;
|
drawCell = false;
|
||||||
segments = 4;
|
segments = 4;
|
||||||
drawBody = false;
|
drawBody = false;
|
||||||
areaDamage = 2f;
|
crushDamage = 2f;
|
||||||
|
|
||||||
segmentScl = 4f;
|
segmentScl = 4f;
|
||||||
segmentPhase = 5f;
|
segmentPhase = 5f;
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ abstract class CrawlComp implements Posc, Rotc, Hitboxc, Unitc{
|
|||||||
|
|
||||||
//TODO area damage to units
|
//TODO area damage to units
|
||||||
if(t.build != null && t.build.team != team){
|
if(t.build != null && t.build.team != team){
|
||||||
t.build.damage(team, type.areaDamage * Time.delta);
|
t.build.damage(team, type.crushDamage * Time.delta);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(Mathf.chanceDelta(0.025)){
|
if(Mathf.chanceDelta(0.025)){
|
||||||
|
|||||||
@@ -63,11 +63,11 @@ abstract class TankComp implements Posc, Flyingc, Hitboxc, Unitc, ElevationMovec
|
|||||||
}
|
}
|
||||||
|
|
||||||
//TODO should this apply to the player team(s)? currently PvE due to balancing
|
//TODO should this apply to the player team(s)? currently PvE due to balancing
|
||||||
if(walked && t != null && t.build != null && t.build.team != team && (state.rules.waves && team == state.rules.waveTeam)
|
if(type.crushDamage > 0 && walked && t != null && t.build != null && t.build.team != team
|
||||||
//damage radius is 1 tile smaller to prevent it from just touching walls as it passes
|
//damage radius is 1 tile smaller to prevent it from just touching walls as it passes
|
||||||
&& Math.max(Math.abs(dx), Math.abs(dy)) <= r - 1){
|
&& Math.max(Math.abs(dx), Math.abs(dy)) <= r - 1){
|
||||||
|
|
||||||
t.build.damage(team, type.areaDamage * Time.delta);
|
t.build.damage(team, type.crushDamage * Time.delta * t.block().crushDamageMultiplier);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -194,8 +194,8 @@ public class UnitType extends UnlockableContent{
|
|||||||
public float segmentScl = 4f, segmentPhase = 5f;
|
public float segmentScl = 4f, segmentPhase = 5f;
|
||||||
public float segmentRotSpeed = 1f, segmentMaxRot = 30f;
|
public float segmentRotSpeed = 1f, segmentMaxRot = 30f;
|
||||||
public float crawlSlowdown = 0.5f;
|
public float crawlSlowdown = 0.5f;
|
||||||
//used for tanks too
|
/** Damage dealt to blocks under this tank/crawler every frame. */
|
||||||
public float areaDamage = 0.5f;
|
public float crushDamage = 0f;
|
||||||
public float crawlSlowdownFrac = 0.55f;
|
public float crawlSlowdownFrac = 0.55f;
|
||||||
|
|
||||||
public ObjectSet<StatusEffect> immunities = new ObjectSet<>();
|
public ObjectSet<StatusEffect> immunities = new ObjectSet<>();
|
||||||
|
|||||||
@@ -156,6 +156,8 @@ public class Block extends UnlockableContent implements Senseable{
|
|||||||
public float clipSize = -1f;
|
public float clipSize = -1f;
|
||||||
/** When placeRangeCheck is enabled, this is the range checked for enemy blocks. */
|
/** When placeRangeCheck is enabled, this is the range checked for enemy blocks. */
|
||||||
public float placeOverlapRange = 50f;
|
public float placeOverlapRange = 50f;
|
||||||
|
/** Multiplier of damage dealt to this block by tanks. Does not apply to crawlers. */
|
||||||
|
public float crushDamageMultiplier = 1f;
|
||||||
/** Max of timers used. */
|
/** Max of timers used. */
|
||||||
public int timers = 0;
|
public int timers = 0;
|
||||||
/** Cache layer. Only used for 'cached' rendering. */
|
/** Cache layer. Only used for 'cached' rendering. */
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ public class Wall extends Block{
|
|||||||
buildCostMultiplier = 6f;
|
buildCostMultiplier = 6f;
|
||||||
canOverdrive = false;
|
canOverdrive = false;
|
||||||
drawDisabled = false;
|
drawDisabled = false;
|
||||||
|
crushDamageMultiplier = 5f;
|
||||||
|
|
||||||
//it's a wall of course it's supported everywhere
|
//it's a wall of course it's supported everywhere
|
||||||
envEnabled = Env.any;
|
envEnabled = Env.any;
|
||||||
|
|||||||
Reference in New Issue
Block a user