ZSGG Public Library
Lasher
Grell T1 Army Unit
import { GrellArmyUnit } from "../../../../defaults/grell.js";
import { Attack, Spell, Upgrade } from "../../../../engine/ability.js";
export class Lasher extends GrellArmyUnit {
override uuid: string;
static override src = "src/zerospace/faction/grell/unit/lasher.ts";
constructor() {
super();
this.hexiteCost = 50;
this.fluxCost = 25;
this.buildTime = 26;
this.buildCount = 1;
this.name = "Lasher";
this.description = "Ranged combat unit.";
this.tier = "T1";
this.hotkey = "R";
this.uuid = "6c1ec0c5-af3f-4bb1-867f-bd16792d2de6";
this.internalId = "Troop_GrellLasher_C";
this.internalPath = "/Game/Nova/Archetypes_Troops/Troop_GrellLasher.Default__Troop_GrellLasher_C";
this.internalTags = [
"Attackable.Unit.Troop",
"Attackable.Unit.Light",
"Attackable.ArmorType.Light",
"Attackable.Biological",
];
this.internalSecondaryTags = ["Biological"];
this.unlockedBy = ["faction/grell/building/broodwomb"];
this.createdBy = ["faction/grell/building/broodwomb"];
this.upgradedBy = ["faction/grell/building/young-canopy"];
const unit = this;
this.hp = 150;
this.shields = 0;
this.armor = 0;
this.armorType = "light";
this.speed = 550;
this.supply = 2;
this.vision = 1800;
this.turnSpeed = 4000;
this.attacks.acidicSpines = new Attack({
name: "Acidic Spines",
damage: 17,
range: 800,
cooldown: 1.2,
armorPenetration: 0,
delay: 0.12,
targets: ["air", "ground"],
bonusDamage: [{ multiplier: 1.5, vs: ["armor:medium"] }],
parentId: this.id,
parentUUID: this.uuid,
});
this.spells.camouflage = new Spell({
name: "Camouflage",
description: "Grants invisibility and +75% movement speed for 6s",
hotkey: "X",
cooldown: 20,
duration: 6,
unlocked: false,
parentId: this.id,
parentUUID: this.uuid,
});
this.upgrades.causticSpines = new Upgrade({
name: "Caustic Spines",
description: "+2.5 attack range.",
tier: "T1.5",
fluxCost: 100,
researchTime: 50,
apply() {
unit.attacks.attack!.range = (unit.attacks.attack!.range || 0) + 200;
},
parentId: this.id,
parentUUID: this.uuid,
});
this.upgrades.sinuousMusculature = new Upgrade({
name: "Sinuous Musculature",
description: "+30% movement speed.",
tier: "T1.5",
fluxCost: 100,
researchTime: 50,
apply() {
unit.speed = (unit.speed || 0) * 1.25;
},
parentId: this.id,
parentUUID: this.uuid,
});
this.upgrades.corrosiveSecretion = new Upgrade({
name: "Corrosive Secretion",
description: "+50% damage against medium armor",
tier: "T2.5",
fluxCost: 100,
researchTime: 50,
apply() {
unit.attacks.attack!.bonusDamage = [{ multiplier: 2.0, vs: ["armor:medium"] }];
},
parentId: this.id,
parentUUID: this.uuid,
});
this.upgrades.camouflage = new Upgrade({
name: "Camouflage",
description: "Unlocks the Camouflage ability (+25% movement speed and cloak for 6s)",
tier: "T3.5",
fluxCost: 150,
researchTime: 60,
apply() {
unit.spells.camouflage!.unlocked = true;
},
parentId: this.id,
parentUUID: this.uuid,
});
}
}
export default Lasher;