From d5c587a3062c295422b46ddaa7e076a515db6158 Mon Sep 17 00:00:00 2001 From: Slotterleet <62336673+Slotterleet@users.noreply.github.com> Date: Thu, 22 Aug 2024 20:13:19 +0300 Subject: [PATCH] Particulator rebalance & Eliminators visual fix --- res/bundles/bundle.properties | 2 +- res/bundles/bundle_ru.properties | 2 +- src/fos/content/FOSBlocks.java | 141 ++++++++++++++++++++---------- src/fos/content/FOSUnitTypes.java | 12 +-- src/fos/core/FOSMod.java | 1 - 5 files changed, 104 insertions(+), 54 deletions(-) diff --git a/res/bundles/bundle.properties b/res/bundles/bundle.properties index ce9dd68..1f4be25 100644 --- a/res/bundles/bundle.properties +++ b/res/bundles/bundle.properties @@ -213,7 +213,7 @@ block.fos-sludge.description = Launches bursts of tokicite to slow down enemy ta block.fos-dot.name = Dot block.fos-dot.description = Shoots lasers at enemy targets at a very fast rate. block.fos-particulator.name = Particulator -block.fos-particulator.description = Shoots a large projectile at enemy targets that splits into many shards that stay on ground. +block.fos-particulator.description = Shoots cluster shells at enemy targets. block.fos-firefly.name = Firefly block.fos-firefly.description = Burns ground enemy targets with napalm. block.fos-pulse.name = Pulse diff --git a/res/bundles/bundle_ru.properties b/res/bundles/bundle_ru.properties index fa086b9..9793a53 100644 --- a/res/bundles/bundle_ru.properties +++ b/res/bundles/bundle_ru.properties @@ -213,7 +213,7 @@ block.fos-sludge.description = Запускает пузыри токицита block.fos-dot.name = Точка block.fos-dot.description = Очень быстро стреляет лазерами по вражеской цели. block.fos-particulator.name = Партикулятор -block.fos-particulator.description = Стреляет большим снарядом, разлетающимся на много осколков, которые остаются лежать на земле. +block.fos-particulator.description = Стреляет кассетными снарядами по вражеским целям. block.fos-firefly.name = Светлячок block.fos-firefly.description = Поджигает наземные цели с помощью напалма. block.fos-pulse.name = Пульс diff --git a/src/fos/content/FOSBlocks.java b/src/fos/content/FOSBlocks.java index 414b5fb..48ad95e 100644 --- a/src/fos/content/FOSBlocks.java +++ b/src/fos/content/FOSBlocks.java @@ -48,6 +48,7 @@ import multicraft.*; import static arc.graphics.g2d.Draw.color; +import static arc.graphics.g2d.Lines.*; import static arc.math.Angles.randLenVectors; import static fos.content.FOSFluids.*; import static fos.content.FOSItems.*; @@ -556,7 +557,7 @@ silicon, new MissileBulletType(3f, 48){{ fragBullet = new BasicBulletType(2f, 15){{ lifetime = 20f; pierce = true; - pierceCap = 1; + pierceCap = 2; buildingDamageMultiplier = 0.3f; }}; }}, @@ -778,69 +779,117 @@ public void hit(Bullet b, float x, float y){ shootSound = Sounds.shootBig; squareSprite = false; ammo( - silver, new BasicBulletType(4f, 80){{ - lifetime = 60f; + silicon, new BasicBulletType(4f, 80){{ + lifetime = 60f * 10; width = 16f; height = 24f; - backColor = FOSPal.silverBack; - frontColor = trailColor = lightColor = FOSPal.silver; - trailEffect = Fx.artilleryTrail; - trailWidth = 4; - trailLength = 20; ammoMultiplier = 1; - splashDamage = 10f; - splashDamageRadius = 24f; + splashDamage = 40f; + splashDamageRadius = 32f; knockback = 3.2f; fragOnHit = true; - hitEffect = despawnEffect = Fx.explosion; + scaleLife = true; buildingDamageMultiplier = 0.3f; - fragBullets = 6; - fragBullet = new BasicBulletType(0.8f, 10){{ - lifetime = 60f * 5; //frags will stay for pretty long - drag = 0.024f; - width = height = 6f; - backColor = FOSPal.silverBack; - frontColor = trailColor = FOSPal.silver; - trailEffect = Fx.artilleryTrail; - trailLength = 8; - pierceArmor = true; + + backColor = Pal.unitBack; + frontColor = trailColor = lightColor = Pal.unitFront; + trailEffect = Fx.artilleryTrail; + trailWidth = 3.4f; + trailLength = 20; + hitShake = 4f; + hitSound = Sounds.largeExplosion; + hitEffect = despawnEffect = new Effect(30, e -> { + // Fx.flakExplosionBig except with different color + color(Pal.bulletYellowBack); + + e.scaled(6, i -> { + stroke(3f * i.fout()); + Lines.circle(e.x, e.y, 3f + i.fin() * 25f); + }); + + color(Pal.unitFront); + + randLenVectors(e.id, 6, 2f + 23f * e.finpow(), (x, y) -> { + Fill.circle(e.x + x, e.y + y, e.fout() * 4f + 0.5f); + }); + + color(Pal.bulletYellow); + stroke(e.fout()); + + randLenVectors(e.id + 1, 4, 1f + 23f * e.finpow(), (x, y) -> { + lineAngle(e.x + x, e.y + y, Mathf.angle(x, y), 1f + e.fout() * 3f); + }); + + Drawf.light(e.x, e.y, 60f, Pal.bulletYellowBack, 0.7f * e.fout()); + }); + + fragBullets = 4; + fragVelocityMin = 0.6f; + fragVelocityMax = 1.4f; + fragBullet = new BasicBulletType(){{ + damage = 0; + speed = 0.8f; + lifetime = 60f * 10; + drag = 0.048f; + width = height = 8f; + sprite = "shell"; + + backColor = Pal.unitBack; + frontColor = trailColor = lightColor = Pal.unitFront; + trailWidth = 1.2f; + trailLength = 12; + hitEffect = new MultiEffect(Fx.explosion, Fx.blockExplosionSmoke); + hitSound = Sounds.explosion; + despawnHit = true; + hitShake = 3f; + + splashDamage = 48f; + splashDamageRadius = 28f; + hitSize = 8f; collidesAir = false; collidesTiles = true; - collideTerrain = false; - hitEffect = Fx.hitBulletSmall; - despawnEffect = Fx.none; + collideTerrain = true; buildingDamageMultiplier = 0.3f; }}; }}, - vanadium, new BasicBulletType(6f, 120){{ + vanadium, new BasicBulletType(6f, 160){{ lifetime = 40f; width = 16f; height = 24f; + ammoMultiplier = 1; + knockback = 4f; + buildingDamageMultiplier = 0.3f; + backColor = vanadium.color.cpy().mul(0.8f); frontColor = trailColor = lightColor = vanadium.color; trailEffect = Fx.artilleryTrail; - trailWidth = 4; + trailWidth = 3.4f; trailLength = 20; - ammoMultiplier = 1; - splashDamage = 25f; - splashDamageRadius = 24f; - knockback = 4f; + hitShake = 2.5f; + hitSound = Sounds.explosion; + hitEffect = despawnEffect = Fx.flakExplosionBig; + fragOnHit = true; - hitEffect = despawnEffect = Fx.explosion; - buildingDamageMultiplier = 0.3f; - fragBullets = 7; - fragBullet = new BasicBulletType(0.8f, 16){{ - lifetime = 60f * 5; //frags will stay for pretty long - drag = 0.024f; + fragBullets = 2; + fragRandomSpread = 30f; + fragVelocityMin = 0.5f; + fragVelocityMax = 1.5f; + fragBullet = new BasicBulletType(1.6f, 25){{ + lifetime = 60f * 5; + drag = 0.048f; width = height = 6f; + + hitEffect = Fx.hitBulletSmall; + despawnEffect = Fx.none; backColor = vanadium.color.cpy().mul(0.8f); - frontColor = trailColor = vanadium.color; - trailEffect = Fx.artilleryTrail; - trailLength = 8; + frontColor = trailColor = lightColor = vanadium.color; + trailWidth = 1.2f; + trailLength = 12; + pierceArmor = true; - collidesAir = false; + pierce = true; + pierceCap = 2; collidesTiles = true; - collideTerrain = false; - hitEffect = Fx.hitBulletSmall; - despawnEffect = Fx.none; + collideTerrain = true; + hittable = false; buildingDamageMultiplier = 0.3f; }}; }} @@ -875,7 +924,7 @@ arkycite, new LiquidBulletType(arkycite){{ pierce = true; pierceCap = 2; despawnHit = true; - hitEffect = fireLong; + hittable = false; //scaleLife = true; puddleSize = 5f; @@ -883,6 +932,7 @@ arkycite, new LiquidBulletType(arkycite){{ puddles = 3; orbSize = 4f; + hitEffect = fireLong; trailEffect = fire; //trailColor = arkycite.color; trailParam = 6f; @@ -900,7 +950,7 @@ oil, new LiquidBulletType(oil){{ pierce = true; pierceCap = 2; despawnHit = true; - hitEffect = fireLong; + hittable = false; //scaleLife = true; puddleSize = 5f; @@ -908,6 +958,7 @@ oil, new LiquidBulletType(oil){{ puddles = 3; orbSize = 4f; + hitEffect = fireLong; trailEffect = fire; //trailColor = oil.color; trailParam = 6f; diff --git a/src/fos/content/FOSUnitTypes.java b/src/fos/content/FOSUnitTypes.java index 451cb7d..ff82664 100644 --- a/src/fos/content/FOSUnitTypes.java +++ b/src/fos/content/FOSUnitTypes.java @@ -866,7 +866,7 @@ public static void load(){ legMoveSpace = 2F; weapons.add( - new Weapon("cp-e-weapon"){{ + new Weapon("fos-e-weapon"){{ x = 0; y = 3; recoil = 1f; mirror = false; @@ -931,7 +931,7 @@ public static void load(){ //buildingDamageMultiplier = 1.25f; }}); - weapons.add(new PointDefenseWeapon("cp-e-point-defense-small"){{ + weapons.add(new PointDefenseWeapon("fos-e-point-defense-small"){{ x = 9; y = -3; mirror = true; rotate = true; @@ -973,7 +973,7 @@ public static void load(){ legMoveSpace = 1.085F; weapons.add( - new Weapon("cp-e-railgun"){{ + new Weapon("fos-e-railgun"){{ x = 9.5f; y = 4f; recoil = 3f; rotate = true; @@ -985,14 +985,14 @@ public static void load(){ shootSound = Sounds.shootSmite; bullet = new RailBulletType(){{ - pierceCap = 1; + pierceCap = 2; pierce = pierceBuilding = true; collidesAir = false; damage = 75f; //buildingDamageMultiplier = 0.75f; length = 100f; hitColor = Pal.surge; - hitEffect = endEffect = Fx.dynamicSpikes.wrap(Pal.surge, 16f); + endEffect = Fx.dynamicSpikes.wrap(Pal.surge, 16f); shootEffect = Fx.shootBig2; smokeEffect = Fx.colorSpark; lineEffect = Fx.chainLightning; @@ -1011,7 +1011,7 @@ public static void load(){ }}; }}; }}, - new PointDefenseWeapon("cp-e-point-defense-small"){{ + new PointDefenseWeapon("fos-e-point-defense-small"){{ x = 30f/4f; y = -25f/4f; mirror = true; rotate = true; diff --git a/src/fos/core/FOSMod.java b/src/fos/core/FOSMod.java index 13d0427..1841017 100644 --- a/src/fos/core/FOSMod.java +++ b/src/fos/core/FOSMod.java @@ -158,7 +158,6 @@ public void init() { if (FOSVars.deathMapController.deathMap[i] == 0) continue; Draw.z(Layer.light); - Draw.color(Color.red); Draw.alpha(FOSVars.deathMapController.deathMap[i] / 100f); Draw.rect("empty", world.tiles.geti(i).worldx(), world.tiles.geti(i).worldy());