SamTurret()
{
self endon ( "disconnect" );
self endon ( "death" );
self beginLocationSelection( "map_artillery_selector", true, ( level.mapSize / 5.625 ) );
self.selectingLocation = true;
self waittill( "confirm_location", location, directionYaw );
NapalmLoc = BulletTrace( location, ( location + ( 0, 0, -100000 ) ), 0, self )[ "position" ];
NapalmLoc += (0, 0, 400);
self endLocationSelection();
self.selectingLocation = undefined;
self thread killstreakNotify(self.name,"SAM TURRET IN COMING");
Plane = spawn("script_model", NapalmLoc+(-15000, 0, 5000) );
Plane setModel( "vehicle_ac130_low_mp" );
Plane.angles = (45, 119.004, 0);
Plane playLoopSound( "veh_ac130_dist_loop" );
Plane moveTo( NapalmLoc + (15000, 0, 2500), 10);
wait 15;
bomb = spawn("script_model", Plane.origin );
bomb setModel( "projectile_hellfire_missile" );
bomb.angles = self.origin;
wait 1.6;
TurretBox= spawn("script_model",bomb.origin-(0,0,0) );
TurretBox setModel("com_plasticcase_beige_big");
TurretBox.angles=bomb.angles;
wait 2;
self playsound("capture_a");
TurretBox moveto(bomb.origin+(0,0,90),2);
wait 1.5;
sky = VectorToAngles( (self.origin+(0,0,500)) - (self.origin ));
self playsound("capture_c");
self rotateto(sky, 2);
wait 5;
for(;
{
self playsound("weap_cobra_missile_fire");
self rotateYaw(360,4);
wait 4;
self rotateYaw(-360,4);
wait 4;
self thread SamFireSetup();
}
}
SamFireSetup()
{
self endon("chopper_down");
self endon("disconnect");
team = owner.pers["team"];
for(;
{
if( (level.teambased) && (isDefined(level.chopper)) && (level.chopper.team !=team))
{
self thread SamFire();
self notify("chopper_down");
}
}
}
SamFire()
{
self iPrintlnBold("Now wait to an helicopter come");
targets = GetTargetList();
targetsInReticle = [];
foreach ( target in targets )
{
if ( !isDefined( target ) )
continue;
if ( bulletTracePassed( self.origin, target.origin, false, self ) )
targetsInReticle[targetsInReticle.size] = target;
}
sortedTargets = SortByDistance( targetsInReticle, self.origin );
self.stingerTarget = sortedTargets[0];
rocket = MagicBullet( "stinger_mp", self.origin, self.stingerTarget.origin, self );
rocket Missile_SetTargetEnt( self.stingerTarget );
rocket Missile_SetFlightmodeDirect();
}
GetTargetList()
{
targets = [];
if ( level.teamBased )
{
if ( IsDefined( level.chopper ) && ( level.chopper.team != self.team || level.chopper.owner == self ) )
targets[targets.size] = level.chopper;
if ( isDefined( level.ac130player ) && level.ac130player.team != self.team )
targets[targets.size] = level.ac130.planemodel;
if ( isDefined( level.harriers) )
{
foreach( harrier in level.harriers )
{
if ( isDefined( harrier ) && ( harrier.team != self.team || ( isDefined( harrier.owner ) && harrier.owner == self ) ) )
targets[targets.size] = harrier;
}
}
if ( level.UAVModels[level.otherTeam[self.team]].size )
{
foreach ( UAV in level.UAVModels[level.otherTeam[self.team]] )
targets[targets.size] = UAV;
}
if ( isDefined( level.littleBird ) )
{
foreach ( bird in level.littleBird )
{
if ( !isDefined( bird ) )
continue;
if ( self.team != bird.owner.team || self == bird.owner )
targets[targets.size] = bird;
}
}
}
else
{
if ( IsDefined( level.chopper ) && ( level.chopper.owner != self ) ) ///check for teams
targets[targets.size] = level.chopper;
if ( isDefined( level.ac130player ) )
targets[targets.size] = level.ac130.planemodel;
if ( isDefined( level.harriers) )
{
foreach( harrier in level.harriers )
{
if ( isDefined( harrier ) )
targets[targets.size] = harrier;
}
}
if ( level.UAVModels.size )
{
foreach ( ownerGuid, UAV in level.UAVModels )
{
if ( isDefined( UAV.owner ) && UAV.owner == self )
continue;
targets[targets.size] = UAV;
}
}
}
return targets;
}
killStreakNotify(user,ks)
{
self endon("disconnect");
foreach(P in level.players)
{
P.ksText setPoint( "RIGHT", "CENTER", 270, -50);
P.ksText setText("^3"+user+"\n^7"+ks);
wait 5;
P.ksText moveOverTime(0.5);
P.ksText setPoint( "CENTER", "CENTER", 600, -50);
}
}
Copyright © 2025, NextGenUpdate.
All Rights Reserved.