UNPKG

@zerospacegg/iolin

Version:

Pure TypeScript implementation of ZeroSpace game data processing (PKL-free)

99 lines 3.99 kB
"use strict"; /** * Steelsworn - Legion's elite warrior unit with momentum building * Professional soldiers who combine faith with flawless combat technique */ var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.Steelsworn = void 0; const ability_js_1 = require("../../../../engine/ability.cjs"); const legion_classes_js_1 = require("../../legion-classes.cjs"); const citadel_js_1 = __importDefault(require("../building/citadel.cjs")); const legion_barracks_js_1 = __importDefault(require("../building/legion-barracks.cjs")); class Steelsworn extends legion_classes_js_1.LegionArmyUnit { constructor() { super(); this.name = "Steelsworn"; this.tier = "T1"; this.hexiteCost = 75; this.fluxCost = 0; this.buildTime = 24; this.buildCount = 1; this.uuid = "94c059bd-31df-459c-9fb7-cf20ac2bf2a9"; // Mutable properties - elite warrior with superior capabilities this.supply = 2; this.hp = 320; // Elite durability this.shields = 0; this.armor = 1; this.armorType = "medium"; this.speed = 500; // Enhanced by training and faith this.hotkey = "W"; // Relationships - created by Legion Barracks this.createdBy = [legion_barracks_js_1.default.id]; this.unlockedBy = [legion_barracks_js_1.default.id]; this.upgradedBy = [citadel_js_1.default.id]; this.description = "Tanky melee infantry. Attacks ground units."; // Tags for identification and targeting this.tag("legion:thrall"); // Elite melee combat system with anti-light armor specialization this.attacks.attack = new ability_js_1.Attack({ name: "Attack", damage: 18, cooldown: 1.37, range: 120, targets: ["ground"], bonusDamage: [{ multiplier: 1.5, vs: ["armor:light"] }], parentId: this.id, parentUUID: this.uuid, }); // Capture instance for upgrade apply methods const unit = this; // Alloy Armor upgrade - stacking attack speed bonus this.upgrades.alloyArmor = new ability_js_1.Upgrade({ name: "Alloy Armor", description: "Each hit increases attack speed (+10% up to 70%)", tier: "T1.5", fluxCost: 100, researchTime: 40, apply() { // Implementation handled by game engine for stacking bonuses }, parentId: this.id, parentUUID: this.uuid, }); // Saw upgrade - enhanced anti-light armor damage this.upgrades.saw = new ability_js_1.Upgrade({ name: "Saw", description: "Additional +100% damage against light armor", tier: "T1.5", fluxCost: 100, researchTime: 40, apply() { // Enhance existing light armor bonus from 50% to 150% unit.attacks.attack.bonusDamage = [{ multiplier: 2.5, vs: ["armor:light"] }]; }, parentId: this.id, parentUUID: this.uuid, }); // Performance Enhancers upgrade - movement speed bonus this.upgrades.performanceEnhancers = new ability_js_1.Upgrade({ name: "Performance Enhancers", description: "+40% movement speed", tier: "T2.5", fluxCost: 150, researchTime: 50, apply() { unit.speed = (unit.speed || 0) * 1.4; }, parentId: this.id, parentUUID: this.uuid, }); } } exports.Steelsworn = Steelsworn; // Static property for source path Steelsworn.src = "src/zerospace/faction/legion/unit/steelsworn.ts"; exports.default = Steelsworn; //# sourceMappingURL=steelsworn.js.map