package EscaperKillers import public EscaperSensor import ChannelAbilityPreset public constant COLL_SIZE_SK = 72. public constant COLL_SIZE_BK = 92. public constant COLL_SIZE_SRK = 68. public constant COLL_SIZE_BRK = 88. public constant COLL_SIZE_TANK = 80. public constant COLL_SIZE_GLAIVE = 54. public constant COLL_SIZE_AIR_Z = 78. public constant COLL_SIZE_AIR_XY = 52. public constant COLL_SIZE_FIRE = 8. public constant AIR_HEIGHT = 200. public constant SMALL_RANDOM_KILLER_ID = 'srkr' public constant BIG_RANDOM_KILLER_ID = 'brkr' public constant GLAIVE_KILLER_ID = 'glve' public constant TANK_KILLER_ID = 'tank' public constant FIRE_KILLER_ID = 'fire' public constant AIR_KILLER_ID = 'airk' public class SmallKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.toVec3(), owner, getRegionData(pos).getTypeSet().smallKillerId, facing, COLL_SIZE_SK, COLL_SIZE_SK + 4) construct(vec2 pos, player owner) super(pos.toVec3(), owner, getRegionData(pos).getTypeSet().smallKillerId, COLL_SIZE_SK, COLL_SIZE_SK + 4) construct(unit existing) super(existing, COLL_SIZE_SK, COLL_SIZE_SK + 16) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, SMALLKILL_INDEX.toString())) return json public class SmallRandomKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.toVec3(), owner, SMALL_RANDOM_KILLER_ID, facing, COLL_SIZE_SRK, COLL_SIZE_SRK) setupRandKiller() construct(vec2 pos, player owner) super(pos.toVec3(), owner, SMALL_RANDOM_KILLER_ID, COLL_SIZE_SRK, COLL_SIZE_SRK) setupRandKiller() construct(unit existing) super(existing, COLL_SIZE_SRK, COLL_SIZE_SRK) setupRandKiller() function setupRandKiller() actor.removeAbility(AbilityIds.wander) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, SMALLRANDKILL_INDEX.toString())) return json public class BigKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.toVec3(), owner, getRegionData(pos).getTypeSet().bigKillerId, facing, COLL_SIZE_BK, COLL_SIZE_BK * 0.75) construct(vec2 pos, player owner) super(pos.toVec3(), owner, getRegionData(pos).getTypeSet().bigKillerId, COLL_SIZE_BK, COLL_SIZE_BK * 0.75) construct(unit existing) super(existing, COLL_SIZE_BK, COLL_SIZE_BK) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, BIGKILL_INDEX.toString())) return json public class BigRandomKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.toVec3(), owner, BIG_RANDOM_KILLER_ID, facing, COLL_SIZE_BRK, COLL_SIZE_BRK) setupRandKiller() construct(vec2 pos, player owner) super(pos.toVec3(), owner, BIG_RANDOM_KILLER_ID, COLL_SIZE_BRK, COLL_SIZE_BRK) setupRandKiller() construct(unit existing) super(existing, COLL_SIZE_BRK, COLL_SIZE_BRK) setupRandKiller() function setupRandKiller() actor.removeAbility(AbilityIds.wander) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, BIGRANDKILL_INDEX.toString())) return json public class TankKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.toVec3(), owner, TANK_KILLER_ID, facing, COLL_SIZE_TANK, COLL_SIZE_TANK) construct(vec2 pos, player owner) super(pos.toVec3(), owner, TANK_KILLER_ID, COLL_SIZE_TANK, COLL_SIZE_TANK) construct(unit existing) super(existing, COLL_SIZE_TANK, COLL_SIZE_TANK) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, TANKKILL_INDEX.toString())) return json public class GlaiveKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.toVec3(), owner, GLAIVE_KILLER_ID, facing, COLL_SIZE_GLAIVE, COLL_SIZE_GLAIVE) construct(vec2 pos, player owner) super(pos.toVec3(), owner, GLAIVE_KILLER_ID, COLL_SIZE_GLAIVE, COLL_SIZE_GLAIVE) construct(unit existing) super(existing, COLL_SIZE_GLAIVE, COLL_SIZE_GLAIVE) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, GLAIVEKILL_INDEX.toString())) return json public class AirKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.withZ(200), owner, AIR_KILLER_ID, facing, COLL_SIZE_AIR_XY, COLL_SIZE_AIR_Z) construct(vec2 pos, player owner) super(pos.toVec3(), owner, AIR_KILLER_ID, COLL_SIZE_AIR_XY, COLL_SIZE_AIR_Z) construct(unit existing) super(existing, COLL_SIZE_AIR_XY, COLL_SIZE_AIR_Z) override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, AIRKILL_INDEX.toString())) return json public class FireKiller extends EscaperSensorSetup construct(vec2 pos, player owner, angle facing) super(pos.withZ(256), owner, FIRE_KILLER_ID, facing, COLL_SIZE_FIRE, 64) actor.issueImmediateOrder("immolation") setup.removeAbility('A08I') construct(vec2 pos, player owner) super(pos.toVec3(), owner, FIRE_KILLER_ID, COLL_SIZE_FIRE, COLL_SIZE_FIRE) actor.issueImmediateOrder("immolation") setup.removeAbility('A08I') construct(unit existing) super(existing, COLL_SIZE_FIRE, COLL_SIZE_FIRE) actor.issueImmediateOrder("immolation") setup.removeAbility('A08I') override function serialize() returns Json let json = super.serialize() json ..addProperty(new Property(KEY_TYPE, FIREKILL_INDEX.toString())) return json @objectgen function genKillers() new UnitDefinition(SMALL_RANDOM_KILLER_ID, 'ugho') ..setAttacksEnabled(0) ..setTargetedAs("air") ..setAnimationBlendTimeseconds(0) ..setAnimationCastBackswing(0) ..setScalingValue(2) ..setIconGameInterface("ReplaceableTextures\\CommandButtons\\BTNCritterChicken.blp") ..setModelFile("units\\critters\\EasterChicken\\EasterChicken.mdl") ..setSelectionScale(1) ..setUnitSoundSet("") ..setCollisionSize(0) ..setSpeedBase(180) ..setMovementType(MovementType.Fly) ..setNormalAbilities(commaList('Awan', 'A01H', 'A01E', REMOVE_OBJECT_ID, GHOST_VIS_ID, INVULNERABILITY_ID)) ..setHotkey("S") ..setName("|cff0894E6Small Random Escaper Killer") ..setTooltipBasic("|cffFFCC00Train |cff0894E6Small Random Escaper Killer [S]") ..setTooltipExtended("Spawns a Small Randomwalking Escaperkiller at|cffFFCC00 Rallypoint|n|n|cffD64219Kills Escapers") ..setUpgradesUsed("") ..setCanFlee(false) ..setHitPointsMaximumBase(100000000) ..setSightRadiusDay(0) ..setSightRadiusNight(0) ..setGoldCost(0) ..setFoodCost(0) ..setHideMinimapDisplay(true) new UnitDefinition(BIG_RANDOM_KILLER_ID, 'ugho') ..setAttacksEnabled(0) ..setTargetedAs("air") ..setAnimationBlendTimeseconds(0) ..setAnimationCastBackswing(0) ..setAnimationRunSpeed(100) ..setAnimationWalkSpeed(100) ..setScalingValue(4) ..setIconGameInterface("ReplaceableTextures\\CommandButtons\\BTNCritterRabbit.blp") ..setModelFile("units\\critters\\EasterRabbit\\EasterRabbit.mdl") ..setSelectionScale(1.5) ..setUnitSoundSet("") ..setCollisionSize(0) ..setSpeedBase(180) ..setMovementType(MovementType.Fly) ..setNormalAbilities(commaList('Awan', 'A01H', 'A01E', REMOVE_OBJECT_ID, GHOST_VIS_ID, INVULNERABILITY_ID)) ..setHotkey("D") ..setName("|cff0894E6Big Random Escaper Killer") ..setTooltipBasic("|cffFFCC00Train |cff0894E6Big Random Escaper Killer [D]") ..setTooltipExtended("Spawns a Big Randomwalking Escaperkiller at|cffFFCC00 Rallypoint|n|n|cffD64219Kills Escapers") ..setUpgradesUsed("") ..setCanFlee(false) ..setHitPointsMaximumBase(100000000) ..setSightRadiusDay(0) ..setSightRadiusNight(0) ..setGoldCost(0) ..setFoodCost(0) ..setHideMinimapDisplay(true) new UnitDefinition(GLAIVE_KILLER_ID, 'ugho') ..setAttacksEnabled(0) ..setTargetedAs("air") ..setAnimationCastBackswing(0) ..setScalingValue(1.3) ..setIconGameInterface("ReplaceableTextures\\CommandButtons\\BTNHowlOfTerror.blp") ..setButtonPositionX(3) ..setButtonPositionY(2) ..setModelFile("Abilities\\Weapons\\SentinelMissile\\SentinelMissile.mdl") ..setSelectionScale(0.7) ..setUnitSoundSet("") ..setCollisionSize(1) ..setSpeedBase(180) ..setMovementHeight(20) ..setMovementHeightMinimum(20) ..setNormalAbilities(commaList('A01H', 'A01E', REMOVE_OBJECT_ID, GHOST_VIS_ID, INVULNERABILITY_ID)) ..setHotkey("C") ..setName("Glaive") ..setTooltipBasic("Train Glaive [C]") ..setTooltipExtended("Spawns a Glaive at|cffFFCC00 Rallypoint|n|n|cffD64219Kills Escapers") ..setUpgradesUsed("") ..setCanFlee(false) ..setHitPointsMaximumBase(100000000) ..setSightRadiusDay(0) ..setSightRadiusNight(0) ..setGoldCost(0) ..setFoodCost(0) ..setHideMinimapDisplay(true) new UnitDefinition(TANK_KILLER_ID, 'hmtt') ..setAttacksEnabled(0) ..setTargetedAs("air") ..setAnimationBlendTimeseconds(0) ..setAnimationCastBackswing(0) ..setAnimationCastPoint(0) ..setDeathTimeseconds(0.1) ..setSelectionScale(1.5) ..setUnitSoundSet("") ..setCollisionSize(1) ..setSpeedBase(180) ..setTurnRate(3) ..setMovementType(MovementType.Hover) ..setNormalAbilities(commaList('A01H', 'A01E', REMOVE_OBJECT_ID, GHOST_VIS_ID, INVULNERABILITY_ID)) ..setHotkey("R") ..setName("|cff0894E6Tank") ..setTooltipBasic("|cffFFCC00Train |cff0894E6Tank [R]") ..setTooltipExtended("Spawns a Tank at|cffFFCC00 Rallypoint|n|n|cffD64219Kills Escapers") ..setUpgradesUsed("") ..setRequirements("") ..setHitPointsMaximumBase(100000000) ..setSightRadiusDay(0) ..setSightRadiusNight(0) ..setGoldCost(0) ..setFoodCost(0) ..setHideMinimapDisplay(true) new UnitDefinition(FIRE_KILLER_ID, 'ugho') ..setAttacksEnabled(0) ..setTargetedAs("air") ..setAnimationCastBackswing(0) ..setScalingValue(0.9) ..setIconGameInterface("ReplaceableTextures\\CommandButtons\\BTNLavaSpawn.blp") ..setButtonPositionX(3) ..setButtonPositionY(2) ..setModelFile("Units\\Creeps\\LavaSpawn\\LavaSpawn.mdl") ..setSelectionScale(0.7) ..setUnitSoundSet("") ..setCollisionSize(1) ..setSpeedBase(180) ..setMovementHeight(20) ..setMovementHeightMinimum(20) ..setNormalAbilities(commaList('A08I', 'A01H', 'A01E', REMOVE_OBJECT_ID, GHOST_VIS_ID, INVULNERABILITY_ID)) ..setHotkey("C") ..setName("Fire Killer") ..setTooltipBasic("Train Fire Killer [C]") ..setTooltipExtended("Spawns a Firekiller that does damage over time.") ..setUpgradesUsed("") ..setCanFlee(false) ..setHitPointsMaximumBase(100000000) ..setSightRadiusDay(0) ..setSightRadiusNight(0) ..setGoldCost(0) ..setFoodCost(0) ..setHideMinimapDisplay(true) new UnitDefinition(AIR_KILLER_ID, 'ugho') ..setAttacksEnabled(0) ..setTargetedAs("air") ..setAnimationBlendTimeseconds(0) ..setAnimationCastBackswing(0) ..setScalingValue(0.8) ..setIconGameInterface("ReplaceableTextures\\CommandButtons\\BTNNetherDragon.blp") ..setButtonPositionX(3) ..setButtonPositionY(2) ..setModelFile("units\\creeps\\NetherDragon\\NetherDragon.mdl") ..setTintingColorGreen(50) ..setTintingColorBlue(50) ..setSelectionScale(0.8) ..setUnitSoundSet("") ..setCollisionSize(0) ..setSpeedBase(180) ..setMovementType(MovementType.Fly) ..setMovementHeight(200) ..setMovementHeightMinimum(200) ..setNormalAbilities(commaList('A01H', 'A01E', REMOVE_OBJECT_ID, GHOST_VIS_ID, INVULNERABILITY_ID)) ..setHotkey("S") ..setName("Flying Killer") ..setTooltipBasic("Train flying Escaper Killer [S]") ..setTooltipExtended("Spawns a flying Escaperkiller at|cffFFCC00 Rallypoint|n|n|cffD64219Kills Escapers in air") ..setUpgradesUsed("") ..setCanFlee(false) ..setHitPointsMaximumBase(100000000) ..setSightRadiusDay(0) ..setSightRadiusNight(0) ..setGoldCost(0) ..setFoodCost(0) ..setHideMinimapDisplay(true)