ZeroSpace.gg

Loi'Kru

Chakru Hero Unit

import { ChakruHeroUnit } from "../../../../defaults/chakru.js"; import { Attack, Spell, SpellModeSwitch } from "../../../../engine/ability.js"; class LoiKru extends ChakruHeroUnit { override uuid: string; static override src = "src/zerospace/mercenary/chakru/hero/loi-kru.ts"; constructor() { super(); this.name = "Loi'Kru"; this.description = "Melee hero who transforms between a shielding Earth form and Healing water form."; this.buildTime = 5; this.hotkey = ""; this.uuid = "9cc9a8dd-c47f-4534-9e09-25636685c21f"; this.internalId = "Troop_MP_ChakruHero_C"; this.internalTags = [ "Attackable.Unit.Hero", "Logic.SpawnAtOldestSpawner", "Attackable.Biological", "Logic.NoVeterancy", ]; this.internalSecondaryTags = ["Infantry"]; this.vision = 1800; this.turnSpeed = 6000; this.pushability = 0.1; this.healthRegen = 12; this.hp = 300; this.shields = 0; this.armor = 0; this.armorType = "hero"; this.speed = 500; this.modes = [ { slug: "water", name: "Water", description: "Gains Water abilities and +2 health regeneration." }, { slug: "earth", name: "Earth", description: "Gains Earth abilities and +1 armor." }, ]; this.attacks.leviathanSlash = new Attack({ name: "Leviathan Slash", damage: 23, range: 1200, cooldown: 1.3, armorPenetration: 0, delay: 0.18, targets: ["ground"], parentId: this.id, parentUUID: this.uuid, }); this.spellModes.transform = new SpellModeSwitch({ name: "Transform", description: "Transforms between Earth and Water forms with different abilities. \nEarth form has +1 armor. \nWater form has +2 health regeneration.", hotkey: "E", switchBetween: ["water", "earth"], parentId: this.id, parentUUID: this.uuid, }); this.spells.torrent = new Spell({ name: "Torrent", description: "Shoots a burst of water at a target unit, dealing 75 damage and knocking it back. \nIf cast on an allied unit, heals instead of damages.", cooldown: 12, targets: ["ground", "air"], hotkey: "Q", requiresMode: "water", parentId: this.id, parentUUID: this.uuid, }); this.spells.healingWave = new Spell({ name: "Healing Wave", description: "Create a wave in target direction, knocking back enemies, and healing allies for 50 health.", cooldown: 15, hotkey: "W", targets: ["map"], targetMode: "strip", requiresMode: "water", parentId: this.id, parentUUID: this.uuid, }); this.spells.earthShield = new Spell({ name: "Earth Shield", description: "Give the target unit a shield which absrbs up to 50 damage. \nShield deals 50 damage to enemies when broken. Lasts 10 seconds.", duration: 10, cooldown: 15, hotkey: "Q", targets: ["ground", "air"], requiresMode: "earth", parentId: this.id, parentUUID: this.uuid, }); this.spells.boulder = new Spell({ name: "Boulder", description: "Gather nearby allies and roll towards a target direction. \nStops upon impact with an enemy unit, stunning the struck unit for 2 seconds and dealing 75 damage", requiresMode: "earth", cooldown: 15, hotkey: "W", targets: ["map"], targetMode: "strip", parentId: this.id, parentUUID: this.uuid, }); } } export default LoiKru;