@zerospacegg/iolin
Version:
Pure TypeScript implementation of ZeroSpace game data processing (PKL-free)
100 lines • 3.84 kB
JavaScript
/**
* Predator - Protectorate light reconnaissance vehicle
* Fast attack vehicle with mine-laying capabilities and superior mobility
*/
import { ProtectorateArmyUnit } from "../../../../defaults/protectorate.js";
import { Attack, Spell, Upgrade } from "../../../../engine/ability.js";
class Predator extends ProtectorateArmyUnit {
get infuseCost() {
return 3;
}
constructor() {
super();
this.hexiteCost = 125;
this.fluxCost = 25;
this.buildTime = 20;
this.buildCount = 2;
this.name = "Predator";
this.tier = "T2";
this.supply = 3;
this.uuid = "c8c73071-90af-403f-9929-32efb79242c3";
// Internal game engine data
this.internalId = "Troop_Prot_Predator_C";
this.internalPath = "/Game/Nova/Archetypes_Troops/Troop_Prot_Predator.Default__Troop_Prot_Predator_C";
this.internalTags = ["Attackable.Unit.Troop", "Attackable.ArmorType.Light"];
this.internalSecondaryTags = ["Vehicle"];
// Mutable properties in constructor
this.hp = 150;
this.armor = 0;
this.armorType = "light";
this.speed = 800;
this.turnSpeed = 5000;
this.maxAddOns = 0;
this.description = "Fast vehicle that can lay mines. Attacks ground units.";
// Combat abilities
this.attacks.attack = new Attack({
name: "Attack",
damage: 15,
cooldown: 1.6,
cooldownBetweenShots: 1.6,
armorPenetration: 0,
delay: 0,
range: 500,
targets: ["ground"],
volleys: 2,
bonusDamage: [{ multiplier: 1.5, vs: ["armor:medium"] }],
parentId: this.id,
parentUUID: this.uuid,
});
this.spells.layMine = new Spell({
name: "Lay Mine",
description: "Lay a chaser mine (25hp, cloaked, deals 25 dmg, gives vision on slowed units when an enemy gets close)",
cooldown: 120,
forceAutocast: false,
unlocked: false,
parentId: this.id,
parentUUID: this.uuid,
});
// Upgrades
this.upgrades.bonusShield = new Upgrade({
name: "Bonus Shield",
description: "Gain 100 shields",
tier: "T2.5",
fluxCost: 150,
researchTime: 50,
parentId: this.id,
parentUUID: this.uuid,
});
this.upgrades.chaserMine = new Upgrade({
name: "Chaser Mine",
description: "Unlocks chaser mine ability",
tier: "T2.5",
fluxCost: 100,
researchTime: 40,
apply: () => {
this.spells.layMine.unlocked = true;
},
parentId: this.id,
parentUUID: this.uuid,
});
this.upgrades.piercingBolt = new Upgrade({
name: "Piercing Bolt",
description: "The Predator's cannon will periodically shoot a projectile reducing enemy health by 10%.",
tier: "T3.5",
fluxCost: 150,
researchTime: 60,
parentId: this.id,
parentUUID: this.uuid,
});
// Entity relationships using static ID references
this.createdBy = ["faction/protectorate/building/factory"];
this.upgradedBy = ["faction/protectorate/building/mechanical-research-lab"];
this.unlockedBy = ["faction/protectorate/building/factory"];
// Tags for identification and targeting
this.tags.push("attacker", "spellcaster", "can-be-infused", "can-be-reanimated", "can-be-mind-controlled");
}
}
// Static property for source path
Predator.src = "src/zerospace/faction/protectorate/unit/predator.ts";
export default Predator;
//# sourceMappingURL=predator.js.map