Post: [RELEASE] Reaper
02-17-2012, 01:36 AM #1
Blackstorm
Veni. Vidi. Vici.
(adsbygoogle = window.adsbygoogle || []).push({}); Well, here it is. No point in not releasing it. Smile

make sure you have these at the top of your GSC!
    
#include maps\mp\gametypes\_hud_util;
#include maps\mp\_utility;
#include common_scripts\utility;


Add this to init()
    
precacheShader("ac130_overlay_105mm");
level.fx[0]=loadfx("fire/fire_smoke_trail_m");
level.fx[1]=loadfx("fire/tank_fire_engine");
level.fx[2]=loadfx("smoke/smoke_trail_black_heli");
level.chopper_fx["explode"]["medium"] = loadfx("explosions/aerial_explosion");


put this in OnPlayerSpawned() :
    
self thread monitorButtons();


Add this anywhere:
    
giveReaper()
{
self endon( "disconnect" );
self endon( "death" );
if( !isDefined( level.reaperInUse ) )
level.reaperInUse = 0;
self thread monitorDeath();
self.inReaper = 0;
self.showHUD = 0;
self thread reaperHUD();
cW = [];
curWeapon = 0;
for( ;; )
{
self waittillmatch( "buttonPress", "Right" );
if( !self.isShooting )
{
if( !level.reaperInUse * !self.inReaper || level.reaperInUse * self.inReaper)
{
self.inReaper = !self.inReaper;
level.reaperInUse = !level.reaperInUse;
if( self.inReaper * level.reaperInUse )
{
cW[0] = self GetWeaponsListPrimaries();
cW[1] = self getWeaponsListOffhands();
curWeapon = self getCurrentWeapon();
self takeAllWeapons();
self giveWeapon( "killstreak_ac130_mp" );
self switchToWeapon( "killstreak_ac130_mp" );
wait 1.5;
self VisionSetNakedForPlayer( "black_bw" );
wait .25;
self.showHUD = 1;
self PlayerLinkWeaponviewToDelta( level.ac130, "tag_player", 1.0, 35, 35, 35, 35 );
wait .15;
self ThermalVisionFOFOverlayOn();
self ThermalVisionOn();
self VisionSetThermalForPlayer( getDvar( "mapname" ) );
self thread monitorFire();
}
else if( !level.reaperInUse * !self.inReaper )
{
self thermalVisionOff();
self notify( "closed" );
self visionSetNakedForPlayer( "black_bw" );
self.showHUD = 0;
self unlink();self setClientDvar( "cg_fovmin", 1 );
wait .25;
self visionSetNakedForPlayer( getDvar( "mapname" ));
self thermalvisionFOFOverlayOff();
self takeWeapon( "killstreak_ac130_mp" );
for( i = 0; i < cW[0].size; i++ )
self giveWeapon( cW[0][i] );
for( i = 0; i < cW[1].size; i++ )
self giveWeapon( cW[1][i] );
wait .25;
self switchToWeapon( curWeapon );
}
}
}
else
self iPrintlnBold( "^7ERROR: Can't close laptop while missile is being fired" );
}
}


monitorFire()
{
self endon( "disconnect" );
self endon( "closed" );
zoom = 60;
self.isShooting = 0;
for( ; isAlive( self ) * self.inReaper; )
{
self setClientDvar( "cg_fovmin", zoom );
self waittill( "buttonPress", button );
if( button == "RS" )
{
if( zoom == 60 )
zoom = 10;
else
zoom = 60;
}
else if( button == "RT" )
{
self.isShooting = 1;
earthquake( 0.2, 1, self getEye(), 1000 );
self playLocalSound( "ac130_105mm_fire" );
missile = spawn( "script_model", self getEye() - ( 0, 0, 30 ) );
missile setModel( "projectile_cbu97_clusterbomb" );
missile playLoopSound("veh_b2_dist_loop");
missile missileControl( self );
missile playSound("harrier_jet_crash");
missile delete();
self.isShooting = 0;
}
}
}


missileControl( shooter )
{
turnSpeed = .05;
rollAngle = 0;
vecParts = 0;
v = 0;
vec = 0;
for ( ;; )
{
for( i = 0; i < level.fx.size; i++ )
playFX( level.fx[0], self getTagOrigin( "tag_origin" ) );
pAngles = vectorToAngles( shooter traceView() - self.origin );
self.angles = pAngles;
flyLocation = self.origin + anglesToForward( pAngles ) * 100;
self moveTo( flyLocation, .05 );
if( distance( shooter traceView(), self.origin ) < 70 )
{
origins = "200 0 0|0 200 0|200 200 0|0 0 200|100 0 0|0 100 0|100 100 0|0 0 100";
playFX( level.chopper_fx["explode"]["medium"], shooter traceView() );
vecParts = strTok( origins, "|" );
for ( i = 0; i < vecParts.size; i++ )
{
v = strTok( vecParts[i], " " );
vec = ( int( v[0] ), int( v[1] ), int( v[2] ) );
playFX( level.chopper_fx["explode"]["medium"], shooter traceView() - vec );
playFX( level.chopper_fx["explode"]["medium"], shooter traceView() + vec );
}
earthquake( 3, 1.5, shooter traceView(), 800 );
RadiusDamage( shooter traceView(), 500, 350, 50, shooter );
break;
}
wait .05;
}
}


reaperHUD()
{
self endon( "disconnect" );
reapHUD = newClientHudElem( self );
reapHUD.x = 0;
reapHUD.y = 0;
reapHUD.alignX = "center";
reapHUD.alignY = "middle";
reapHUD.horzAlign = "center";
reapHUD.vertAlign = "middle";
reapHUD.foreground = true;
reapHUD.alpha = 1;
reapHUD setShader( "ac130_overlay_105mm", 640, 480 );
for( ; isAlive( self ) ; )
{
reapHUD.alpha = self.showHUD;
wait .05;
}
reapHUD destroy();
}


monitorDeath()
{
self waittill( "death" );
self unlink();
if( self.inReaper )
{
level.reaperInUse = 0;
self.inReaper = 0;
}
}


TraceView()
{
return BulletTrace(self getEye(), anglesToForward(self getPlayerAngles()) * 1000000, 1, self)["position"];
}


monitorButtons()
{
self endon( "disconnect" );
self endon( "death" );
ent = spawnStruct();
buttons = strTok( "Right|+actionslot 4;RS|+melee;RT|+attack", ";" );
for( i = 0; i < buttons.size; i++ )
{
split = strTok( buttons[i], "|" );
self notifyOnPlayerCommand( split[0], split[1] );
}
for( ;; )
{
for( i = 0; i < buttons.size; i++ )
{
button = strTok( buttons[i], "|" );
self thread waittill_string( button[0], ent );
}
ent waittill( "returned", btn );
ent notify( "die" );
self notify( "buttonPress", btn );
}
}


then to give someone a reaper just call it like this:
    
self thread giveReaper();


how much easier could this be?

Press knife (melee) to zoom in and out, and attack (shoot) to fire, and press right to enter/exit the reaper.

ENJOOOOY =D

Credits:

TheUnkn0wn - Effects
247Yamato - For a sound effect
Lost4468 - His scripts helped me understand stuff :p
(adsbygoogle = window.adsbygoogle || []).push({});

The following 9 users say thank you to Blackstorm for this useful post:

aerosoul94, Amanda, BlazingDope, KCxFTW, KingcreekS, Klots, User23434, mattyjkilledme, Rainbow Gravity

The following user groaned Blackstorm for this awful post:

Cmd-X
02-17-2012, 06:22 PM #11
iTruceFret
[move]From now on, call me DRAGON.[/move]
Originally posted by 247Yamato View Post
I knew you werent going to thank me.


I don't know why, but I thanked you. :happycry:

The following user thanked iTruceFret for this useful post:

247Yamato
02-17-2012, 06:45 PM #12
Default Avatar
Newelly
Guest
Originally posted by 247Yamato View Post
I knew you werent going to thank me.


Blackstorm has memory laps meaning he probably forgot Cool Man (aka Tustin)...

Im sure he'll add you to his credit list :fa:

:love:

The following 2 users say thank you to Newelly for this useful post:

247Yamato, Blackstorm
02-17-2012, 09:10 PM #13
Originally posted by 247Yamato View Post
I knew you werent going to thank me.


Ahh

I'll add both of you to my credits.

I didnt know you helped him Winky Winky
02-17-2012, 11:20 PM #14
Blackstorm
Veni. Vidi. Vici.
Originally posted by 247Yamato View Post
I knew you werent going to thank me.


oops sorry, forgot.

edit:

lol... A groan is quite harsh for forgetting to add you for ONE sound effect. :p
02-17-2012, 11:22 PM #15
Originally posted by Blackstorm View Post
oops sorry, forgot.

Put it in a patch for me and I'll record now but I'm too lazy to do it myself :p
02-17-2012, 11:26 PM #16
Blackstorm
Veni. Vidi. Vici.
Originally posted by xRazbaz View Post
Put it in a patch for me and I'll record now but I'm too lazy to do it myself :p


i'm too lazy to do it too :p

i'll ask someone later xD
02-17-2012, 11:29 PM #17
Originally posted by Blackstorm View Post
i'm too lazy to do it too :p

i'll ask someone later xD

Ok then, you ask someone to put it in a patch then they give to you who give it 2 me 2 record
But wat if they're too lazy 0.o
02-17-2012, 11:35 PM #18
Blackstorm
Veni. Vidi. Vici.
Originally posted by xRazbaz View Post
Ok then, you ask someone to put it in a patch then they give to you who give it 2 me 2 record
But wat if they're too lazy 0.o


it's an endless chain :O

---------- Post added at 04:35 PM ---------- Previous post was at 04:34 PM ----------

Originally posted by Newelly View Post
Blackstorm has memory laps meaning he probably forgot Cool Man (aka Tustin)...

Im sure he'll add you to his credit list :fa:

:love:



Exactly :wub:

The following user thanked Blackstorm for this useful post:

02-17-2012, 11:52 PM #19
Cmd-X
It's been awhile.
Originally posted by SatanicHispanic View Post
You bitch! Haha :p

:wub:

I'll release mine later tonight


Yours will be better, because you add one thing to your codes that Blackstorm doesn't... Love.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo