package BossTwo import Boss import PresetBuffs import Heightmap public constant buffAbil = compiletime(createDummyBuffObject("Tentacolous", "The boss spawns tentacles when it loses hitpoints", "ReplaceableTextures\\CommandButtons\\BTNTentacle.blp")) constant TENTACLE_ID = 'u00W' public class SludgeBuff extends ShieldBuff private color currentCol = color(155,255,155) private color nextCol = color(155,255,155) private real dmgHold = 0 construct(real dur) super(dur, buffAbil, 6500) currentCol = color(155,255,155) override function update() super.update() currentCol = currentCol.lerp(nextCol, 0.35) target.setVertexColor(currentCol) override function defenseModifier() dmgHold += DamageEvent.getAmount() if dmgHold > 500 dmgHold -= 500 nextCol = color(GetRandomInt(25,255),GetRandomInt(25,255),GetRandomInt(25,255)) new Tentacle(target.getPos().polarOffset(target.getFacingAngle() + angle(GetRandomReal(-0.75, 0.75)), GetRandomReal(64, 188)).withHeightMap()).actor.issueImmediateOrder("stop") public class Tentacle extends Creep construct(vec3 pos) super(pos, TENTACLE_ID, 6, middle, GetRandomReal(0, PI2).fromRad()) actor.setPropWindow(0 .fromDeg()) public class BossTwo extends Boss construct(vec3 pos, int typId, int bounty, vec2 target) super(pos, typId, bounty, target) new SludgeBuff(99999).apply(actor)