zedtest2 #2

Merged
dkanus merged 6 commits from :zedtest2 into master 2022-01-20 16:47:12 +03:00
Showing only changes of commit 57e2d81e12 - Show all commits

View File

@ -1,46 +1,12 @@
class MeanZombieHusk extends NiceZombieHusk; class MeanZombieHusk extends NiceZombieHusk;
#exec OBJ LOAD FILE=NicePackT.utx #exec OBJ LOAD FILE=NicePackT.utx
var int consecutiveShots, totalShots, maxNormalShots; var int consecutiveShots, totalShots, maxNormalShots;
function DoStun(optional Pawn instigatedBy, optional Vector hitLocation, optional Vector momentum, optional class<NiceWeaponDamageType> damageType, optional float headshotLevel, optional KFPlayerReplicationInfo KFPRI){ function DoStun(optional Pawn instigatedBy, optional Vector hitLocation, optional Vector momentum, optional class<NiceWeaponDamageType> damageType, optional float headshotLevel, optional KFPlayerReplicationInfo KFPRI){
super.DoStun(instigatedBy, hitLocation, momentum, damageType, headshotLevel, KFPRI); super.DoStun(instigatedBy, hitLocation, momentum, damageType, headshotLevel, KFPRI);
totalShots = maxNormalShots; totalShots = maxNormalShots;
} }
function SpawnTwoShots() {
local vector X,Y,Z, FireStart;
local rotator FireRotation;
local KFMonsterController KFMonstControl;
if(Controller != none && KFDoorMover(Controller.Target) != none){
Controller.Target.TakeDamage(22, Self, Location, vect(0,0,0), Class'DamTypeVomit');
return;
}
GetAxes(Rotation,X,Y,Z);
FireStart = GetBoneCoords('Barrel').Origin;
if (!SavedFireProperties.bInitialized){
SavedFireProperties.AmmoClass = Class'SkaarjAmmo';
SavedFireProperties.ProjectileClass = HuskFireProjClass;
SavedFireProperties.WarnTargetPct = 1;
SavedFireProperties.MaxRange = 65535;
SavedFireProperties.bTossed = False;
SavedFireProperties.bTrySplash = true;
SavedFireProperties.bLeadTarget = True;
SavedFireProperties.bInstantHit = False;
SavedFireProperties.bInitialized = True;
}
// Turn off extra collision before spawning vomit, otherwise spawn fails
ToggleAuxCollision(false);
if(Controller != none)
FireRotation = Controller.AdjustAim(SavedFireProperties, FireStart, 600);
foreach DynamicActors(class'KFMonsterController', KFMonstControl){
if(KFMonstControl != controller){
if(PointDistToLine(KFMonstControl.Pawn.Location, vector(FireRotation), FireStart) < 75){
KFMonstControl.GetOutOfTheWayOfShot(vector(FireRotation),FireStart);
}
}
}
Spawn(HuskFireProjClass, Self,, FireStart, FireRotation);
// Turn extra collision back on
ToggleAuxCollision(true);
}
function RangedAttack(Actor A) { function RangedAttack(Actor A) {
local int LastFireTime; local int LastFireTime;
if ( bShotAnim ) if ( bShotAnim )