Ways

Insane-Known Member
Messages
140
Points
378
Hello CabCon Community Today I bring you with a Managed Code List of many functions and options hope you enjoy if you see a script that is yours just comment and I will give credits, thank you. -Ways
God Mode
GodMode()
{
if(self.god == false)
{
self iprintln("God Mode: ^2On");
self enableInvulnerability();
self.god=false;
}
else
{
self iprintln("God Mode: ^1Off");
self DisableInvulnerability();
self.god=true;
}

}

Unlimited Ammo
Code:
unlimited_ammo()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]{
    self endon( "disconnect" );
    self endon( "death" );

    for(;;)
    {
        wait 0.1;

        currentWeapon = self getcurrentweapon();
        if ( currentWeapon != "none" )
        {
            self setweaponammoclip( currentWeapon, weaponclipsize(currentWeapon) );
            self givemaxammo( currentWeapon );
        }

        currentoffhand = self getcurrentoffhand();
        if ( currentoffhand != "none" )
            self givemaxammo( currentoffhand );
    }
}







Teleport
Code:
doTeleport()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]{
    self beginLocationSelection( "map_mortar_selector" );
    self.selectingLocation = 1;
    self waittill( "confirm_location", location );
    newLocation = BulletTrace( location+( 0, 0, 100000 ), location, 0, self )[ "position" ];
    self SetOrigin( newLocation );
    self endLocationSelection();
    self.selectingLocation = undefined;
    self iPrintLn("Teleported!");
}







Change Class
Code:
ChangeClass()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]{
    self endon("disconnect");
    self endon("death");

    self maps/mp/gametypes/_globallogic_ui::beginclasschoice();
    for(;;)
    {
        if(self.pers[ "changed_class" ])
            self maps/mp/gametypes/_class::giveloadout( self.team, self.class );
        wait 0.05;
    }
}







Change Speed
Code:
speedx2()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]{
        self iprintln("Speed x2");
        self setmovespeedscale(2); //change number
}

//If you want it faster or something change the number








Fill Killstreaks
Code:
{[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]    maps/mp/gametypes/_globallogic_score::_setplayermomentum(self, 9999);
}







Constant Radar
Code:
doUAV()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]{
    self setclientuivisibilityflag("g_compassShowEnemies", 1);
    self iPrintLn("UAV ^2Enabled");
}







All Perks
Code:
doPerks()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]{
    self clearperks();
    self setperk("specialty_additionalprimaryweapon");
    self setperk("specialty_armorpiercing");
    self setperk("specialty_armorvest");
    self setperk("specialty_bulletaccuracy");
    self setperk("specialty_bulletdamage");
    self setperk("specialty_bulletflinch");
    self setperk("specialty_bulletpenetration");
    self setperk("specialty_deadshot");
    self setperk("specialty_delayexplosive");
    self setperk("specialty_detectexplosive");
    self setperk("specialty_disarmexplosive");
    self setperk("specialty_earnmoremomentum");
    self setperk("specialty_explosivedamage");
    self setperk("specialty_extraammo");
    self setperk("specialty_fallheight");
    self setperk("specialty_fastads");
    self setperk("specialty_fastequipmentuse");
    self setperk("specialty_fastladderclimb");
    self setperk("specialty_fastmantle");
    self setperk("specialty_fastmeleerecovery");
    self setperk("specialty_fastreload");
    self setperk("specialty_fasttoss");
    self setperk("specialty_fastweaponswitch");
    self setperk("specialty_finalstand");
    self setperk("specialty_fireproof");
    self setperk("specialty_flakjacket");
    self setperk("specialty_flashprotection");
    self setperk("specialty_gpsjammer");
    self setperk("specialty_grenadepulldeath");
    self setperk("specialty_healthregen");
    self setperk("specialty_holdbreath");
    self setperk("specialty_immunecounteruav");
    self setperk("specialty_immuneemp");
    self setperk("specialty_immunemms");
    self setperk("specialty_immunenvthermal");
    self setperk("specialty_immunerangefinder");
    self setperk("specialty_killstreak");
    self setperk("specialty_longersprint");
    self setperk("specialty_loudenemies");
    self setperk("specialty_marksman");
    self setperk("specialty_movefaster");
    self setperk("specialty_nomotionsensor");
    self setperk("specialty_noname");
    self setperk("specialty_nottargetedbyairsupport");
    self setperk("specialty_nokillstreakreticle");
    self setperk("specialty_nottargettedbysentry");
    self setperk("specialty_pin_back");
    self setperk("specialty_pistoldeath");
    self setperk("specialty_proximityprotection");
    self setperk("specialty_quickrevive");
    self setperk("specialty_quieter");
    self setperk("specialty_reconnaissance");
    self setperk("specialty_rof");
    self setperk("specialty_scavenger");
    self setperk("specialty_showenemyequipment");
    self setperk("specialty_stunprotection");
    self setperk("specialty_shellshock");
    self setperk("specialty_sprintrecovery");
    self setperk("specialty_showonradar");
    self setperk("specialty_stalker");
    self setperk("specialty_twogrenades");
    self setperk("specialty_twoprimaries");
    self setperk("specialty_unlimitedsprint");
    self iPrintln("All Perks ^2Set");
}







Force Host
Code:
forceHost()[/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT][/B][/LEFT]
[B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B]
[LEFT][B][LEFT]    {
    if(self.fhost == false)
    {
        self.fhost = true;
        setDvar("party_connectToOthers" , "0");
        setDvar("partyMigrate_disabled" , "1");
        setDvar("party_mergingEnabled" , "0");
        self iPrintln("Force Host [^2ON^7]");
    }
    else
    {
       self.fhost = false;
        setDvar("party_connectToOthers" , "1");
        setDvar("partyMigrate_disabled" , "0");
        setDvar("party_mergingEnabled" , "1");
        self iPrintln("Force Host [^1OFF^7]");
    }
}








PHD Flopper
Code:
PHD_Perk()
{
    if(self.PHD==false)
    {
        self.PHD=true;
        self thread phd_flopper();
        self iPrintlnbold("PHD Flopper: On");
    }
    else
    {
        self.PHD=false;
        self notify("phd_done");
        self iPrintlnbold("PHD Flopper: Off");
    }
}
phd_flopper()
{
self endon("phd_done");
self iprintln("PHD Flopper On");
for(;;)
{
  if(isDefined(self.divetoprone) && self.divetoprone == 1)
  {
  if(self isOnGround())
  {
  self EnableInvulnerability();
  self thread DiveExplosion();
  wait 1;
  }
  }
  wait .3;
}
}
DiveExplosion()
{
self endon("phd_done");
self playsound( "exp_barrel" );
playfx(loadfx("maps/mp_maps/fx_mp_exp_rc_bomb"), self.origin);
Earthquake( 0.3, 1, self.origin, 90 );
RadiusDamage(self.origin, 350, 700, 350, self, "MOD_PROJECTILE_SPLASH");
wait .2;
self DisableInvulnerability();
}

//Call it PHD_Perk

Change Your Outfit

Code:
ChangeSwag()
{
     if(self.swg == false)
     {
          self thread Swggy();
          self iprintln("Switch Apperiance Enable");
          self setclientthirdperson(true);
          self.swg = true;
     }
     else
     {
          self iprintln("Switch Apperiance Off");
          self setclientthirdperson(false);
          self notify("stopswg");
          self.swg = false;
     }
}

Swggy()
{
     self endon("death");
     self endon("stopswg");
     self endon("disconnect");
     for(;;)
     {
          self [[game["set_player_model"][self.team]["default"]]]();
          wait 0.01;
          self [[game["set_player_model"][self.team]["mg"]]]();
          wait 0.01;
          self [[game["set_player_model"][self.team]["spread"]]]();
          wait 0.01;
          self [[game["set_player_model"][self.team]["rifle"]]]();
          wait 0.01;
          self [[game["set_player_model"][self.team]["smg"]]]();
     }
     wait 0.01;
} //MAde this myself please give credit if you put this in your menu

Strafe Run
Code:
locationSelector()
{
self endon("disconnect");
self endon("death");

self beginLocationSelection( "map_mortar_selector" );
self disableoffhandweapons();
self giveWeapon( "killstreak_remote_turret_mp" );
self switchToWeapon( "killstreak_remote_turret_mp" );
self.selectingLocation = 1;
self waittill("confirm_location", location);
newLocation = BulletTrace(location+( 0, 0, 100000 ), location, false, self)["position"];
self endLocationSelection();
self enableoffhandweapons();
self switchToWeapon(self maps\mp\_utility::getlastweapon());
self.selectingLocation = undefined;
return newLocation;
}

initStrafeRun()
{
if (!level.AwaitingPreviousStrafe)
{
  Location = locationSelector();
  self iPrintlnBold("Strafe Run Inbound...");
  level.AwaitingPreviousStrafe = true;

  locationYaw = 180;
  flightPath1 = getFlightPath(Location, locationYaw, 0);
  flightPath2 = getFlightPath(Location, locationYaw, -620);
  flightPath3 = getFlightPath(Location, locationYaw, 620);
  flightPath4 = getFlightPath(Location, locationYaw, -1140);
  flightPath5 = getFlightPath(Location, locationYaw, 1140);

  level thread Strafe_Think(self, flightPath1);
  wait 0.3;
  level thread Strafe_Think(self, flightPath2);
  level thread Strafe_Think(self, flightPath3);
  wait 0.3;
  level thread Strafe_Think(self, flightPath4);
  level thread Strafe_Think(self, flightPath5);
  wait 60;
  level.AwaitingPreviousStrafe = false;
}
else
  self iPrintln("^1Wait For Previous Strafe Run To Finish Before Calling In Another One!");
}

Strafe_Think(owner, flightPath)
{
level endon("game_ended");

if (!isDefined(owner))
  return;

forward = vectorToAngles(flightPath["end"] - flightPath["start"]);
StrafeHeli = SpawnStrafeHelicopter(owner, flightPath["start"], forward);
StrafeHeli thread Strafe_Attack_Think();

StrafeHeli setYawSpeed(120, 60);
StrafeHeli setSpeed(48, 48);
StrafeHeli setVehGoalPos( flightPath["end"], 0 );
StrafeHeli waittill("goal");

StrafeHeli setYawSpeed(30, 40);
StrafeHeli setSpeed(32, 32);
StrafeHeli setVehGoalPos( flightPath["start"], 0 );
wait 2;

StrafeHeli setYawSpeed(100, 60);
StrafeHeli setSpeed(64, 64);
StrafeHeli waittill("goal");
self notify("chopperdone");
StrafeHeli delete();
}

Strafe_Attack_Think()
{
self endon("chopperdone");

self setVehWeapon(self.defaultweapon);
for( ;; )
{
  for (i = 0; i < level.players.size; i++)
  {
   if(CanTargetPlayer(level.players[i]))
   {
    self setturrettargetent(level.players[i]);
    self FireWeapon("tag_flash", level.players[i]);
   }
     }
     wait 0.5;
}
}

SpawnStrafeHelicopter(owner, origin, angles)
{
Team = owner.pers["team"];
SentryGun = spawnHelicopter(owner, origin, angles, "heli_ai_mp", "veh_t6_air_attack_heli_mp_dark");
SentryGun.team = Team;
SentryGun.pers["team"] = Team;
SentryGun.owner = owner;
SentryGun.currentstate = "ok";
SentryGun setdamagestage(4);
SentryGun.killCamEnt = SentryGun;
return SentryGun;
}

CanTargetPlayer(player)
{
    CanTarget = true;
    if (!IsAlive(player) || player.sessionstate != "playing")
        return false;
    if (Distance(player.origin, self.origin ) > 5000)
        return false;
    if (!isDefined(player.pers["team"]))
        return false;
    if (level.teamBased && player.pers["team"] == self.team)
        return false;
    if (player == self.owner)
        return false;
    if (player.pers["team"] == "spectator")
        return false;
    if (!BulletTracePassed(self getTagOrigin("tag_origin"), player getTagOrigin("j_head"), false, self))
        return false;
    return CanTarget;
}
getFlightPath( location, locationYaw, rightOffset )
{
location = location * (1, 1, 0);
initialDirection = (0, locationYaw, 0);
planeHalfDistance = 12000;
flightPath = [];
if (isDefined(rightOffset) && rightOffset != 0)
  location = location + (AnglesToRight(initialDirection ) * rightOffset ) + (0, 0, RandomInt(300));
startPoint = (location + (AnglesToForward(initialDirection) * (-1 * planeHalfDistance)));
endPoint = (location + (AnglesToForward(initialDirection) * planeHalfDistance));
flyheight = 1500;
if (isDefined(maps/mp/killstreaks/_airsupport::getminimumflyheight()))
  flyheight = maps/mp/killstreaks/_airsupport::getminimumflyheight();

flightPath["start"] = startPoint + ( 0, 0, flyHeight );
flightPath["end"] = endPoint + ( 0, 0, flyHeight );
return flightPath;
} //Call it initStrafeRun

Kamikaze
Code:
kamikaze()
{
    self endon("disconnect");
    self endon("death");

    Location = locationSelector();

    self iPrintlnBold("^3Kamikaze Bomber Inbound");

    Kamikaze = spawn("script_model", self.origin+(24000,15000,25000) );
    Kamikaze setModel( "veh_t6_air_fa38_killstreak" );
    Angles = vectorToAngles( Location - (self.origin+(8000,5000,10000)));
    Kamikaze.angles = Angles;
    Kamikaze moveto(Location, 3.5);

    Kamikaze playsound( "mpl_lightning_flyover_boom" );

    playFxOnTag( level.chopper_fx[ "damage" ][ "light_smoke" ], Kamikaze, "tag_origin" );
    wait 3.6;
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin);
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(400,0,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(0,400,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(400,400,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(0,0,400));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin-(400,0,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin-(0,400,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin-(400,400,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(0,0,800));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(200,0,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(0,200,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(200,200,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(0,0,200));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin-(200,0,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin-(0,200,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin-(200,200,0));
    playFX(level.chopper_fx["explode"]["large"], Kamikaze.origin+(0,0,200));
    Kamikaze playsound( level.heli_sound[ "crash" ] );
    self RadiusDamage(Kamikaze.origin, 500, 1000, 100, self);

    Kamikaze delete();
    Earthquake( 0.4, 4, Kamikaze.origin, 800 );
}

Shaders
Code:
//Treyarch Loading Symbol
{
    maps\mp\_compass::setupminimap( "lui_loader_no_offset" );
    self iprintln("Minimap Changed");
}
//Xbox Controlller
{
    maps\mp\_compass::setupminimap( "em_bg_ani_cybertron" );
    self iprintln("Minimap Changed");
}
//World League
Minimap8()
{
    maps\mp\_compass::setupminimap( "menu_div_pro_sub03_64" );
    self iprintln("Minimap Changed");
}

Sounds
Code:
tst_test_system //Scary Sound
chr_sprint_gasp //Orgasm
aml_dog_bark //Dog Bark
//more coming
NEW
Light Sabers
Code:
RandomMod()
{
    level.waypointRed=loadFX("misc/fx_equip_tac_insert_light_red");
    level.waypointGreen=loadFX("misc/fx_equip_tac_insert_light_grn");
    level.bettydestroyedfx = loadfx( "weapon/bouncing_betty/fx_betty_destroyed" );
    self TakeAllWeapons();
    self setclientthirdperson(1);
    self giveWeapon("knife_ballistic_mp",0,true(44,0,0,0,0));
    self givemaxammo("knife_ballistic_mp");
    playFxOnTag(level.waypointRed, self, "tag_weapon_left");
    playFxOnTag(level.waypointGreen, self, "tag_weapon_right");
    playFxOnTag(level.waypointRed, self, "tag_weapon_right");
    playFxOnTag(level.waypointGreen, self, "tag_weapon_left");
    self endon("death");
    self endon("sabers");
    self endon("disconnect");
    for(;;)
    {
        self waittill("fireworks");
        playFxOnTag(level.bettydestroyedfx, self, "tag_weapon_right");
        playFxOnTag(level.bettydestroyedfx, self, "tag_weapon_left");
    }
}
givesabers()
{
    if(self.givinsbers==false)
    {
        self RandomMod();
        self.sabers=true;
        self.givinsbers=true;
    }
    else
    {
        self.sabers=false;
        self notify("sabers");
        self.givinsbers=false;
    }
}
NEW
Sky Base
Code:
precacheModel("mp_flag_green");// Place this in Init()



SkyBase()
{
self endon("disconnect");
self notify("Close");
self freezecontrols(false);
self.InAnar = 0;
wait 2;
if(!self.Spawned)
    {
        self iprintlnbold("Shoot to Place the teleporter");
        self waittill ( "weapon_fired" );
        forward = self getTagOrigin("j_head");
        end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
        location = BulletTrace( forward, end, 0, self )[ "position" ];
        self thread CreateTeleporter(location);
        self.Spawned = true;
    }
    else
        self iprintlnbold("You cant create more than one");
}
vector_scal(vec, scale)
{
    vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
    return vec;
}
spawnEntity(class, model, origin, angle)
{
    entity = spawn(class, origin);
    entity.angles = angle;
    entity setModel(model);
    return entity;
}

CreateTeleporter(Location)
{
level.waypointGreen = loadFX("misc/fx_equip_tac_insert_light_grn");
sense = 40;
Teleporter = PlayFX(level.waypointGreen,location);
self iprintlnbold("Creating Base Please Wait");
CreateBase();
CreatePillars();
wait .2;
CreateTurrets();
wait .2;
self thread ackopunch();
wait .2;
TeleporterUP = spawn("script_model", (870, 1740, 620));
TeleporterUP.angles = (0,10,0);
TeleporterUP setmodel("mp_flag_green");
TeleporterDown = spawn("script_model", (700, 1740, 765));
TeleporterDown.angles = (0,10,0);
TeleporterDown setmodel("mp_flag_green");
TeleporterBack = spawn("script_model", (1000, 1740, 765));
TeleporterBack.angles = (0,10,0);
TeleporterBack setmodel("mp_flag_green");

self iprintlnbold("SkyBase Created");
wait 1;
self iprintlnbold("Made by Sheperdebops");
for(;;)
    {
         if( distance( self.origin, location) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Teleport");
             if(self jumpbuttonpressed())
                 {
                 wait .2;
                 self SetOrigin((900, 1740, 635));
                 wait .1;
                 }
             wait .5;
             }
         if( distance( self.origin, TeleporterUp.origin) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Teleport UP");
             if(self jumpbuttonpressed())
                 {
                 self SetOrigin((900, 1740, 785));
                 wait .1;
                 }
             wait .5;
             }
         if( distance( self.origin, TeleporterDown.origin) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Teleport Down");
             if(self jumpbuttonpressed())
                 {
                 self SetOrigin((900, 1740, 635));
                 wait .1;
                 }
             wait .5;
             }
         if( distance( self.origin, TeleporterBack.origin) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Return to Land");
             if(self jumpbuttonpressed())
                 {
                 self SetOrigin(location);
                 wait .1;
                 }
             wait .5;
             }
     wait .1;
     }
}
debugPos()
{
for(;;)
    {
    self iPrintln("Pos: ^1"+self.origin+" ^7Angle: ^1"+self.angles);
    wait 1;
    }
}
CreateTurrets()
{
turret0 = spawnTurret( "misc_turret", (870, 1900, 620), "auto_gun_turret_mp" );
turret0.angles = (0,90,0);
turret0 setModel( "t6_wpn_turret_sentry_gun" );
turret0.weaponinfoname = "auto_gun_turret_mp";

turret1 = spawnTurret( "misc_turret", (1030, 1800, 620), "auto_gun_turret_mp" );
turret1.angles = (0,0,0);
turret1 setModel( "t6_wpn_turret_sentry_gun" );
turret1.weaponinfoname = "auto_gun_turret_mp";

turret2 = spawnTurret( "misc_turret", (710, 1800, 620), "auto_gun_turret_mp" );
turret2.angles = (0,-180,0);
turret2 setModel( "t6_wpn_turret_sentry_gun" );
turret2.weaponinfoname = "auto_gun_turret_mp";

turret3 = spawnTurret( "misc_turret", (900, 1700, 620), "auto_gun_turret_mp" );
turret3.angles = (0,-90,0);
turret3 setModel( "t6_wpn_turret_sentry_gun" );
turret3.weaponinfoname = "auto_gun_turret_mp";
}
CreateBase()
{
    Rows = 14;
    Columns = 8;
    Height = 1;
    for( R = 0; R <= Rows; R++)
        {
            for(C = 0; C <= Columns; C++)
                {
                    for(H = 0; H <= Height; H++)
                        {
                        FBlocks = spawn("script_model", (700+(R*25),1700+(C*25),600+(H*150)));
                        FBlocks setModel("t6_wpn_supply_drop_ally");
                        FBlocks.angles = (0, 0, 0);
                        wait .001;
                        }
                wait .001;
                }
        wait .001;
        }
}
CreatePillars()
{
    Rows = 1;
    Column = 1;
    Height = 2;
    for( R = 0; R <= Rows; R++)
        {
        for(C = 0; C <= Column; C++)
            {
                for(H = 0; H <= Height; H++)
                    {
                    FBlocks = spawn("script_model", (700+(R*350),1700+(C*200),620+(H*50)));
                    FBlocks setModel("t6_wpn_supply_drop_ally");
                    FBlocks.angles = (0, 0, 90);
                    wait .1;
                    }
            wait .1;
            }
        wait .1;
        }
}

ackopunch()
{
level.NGU = spawn( "script_model", (860, 1900, 780) );
level.NGU.angles = (0,90,0);
level.NGU setModel( "t6_wpn_supply_drop_ally" );
for(;;)
{
self.packit destroy();
if(distance(self.origin, level.NGU.origin) <150)
{
self.packit = self createFontString( "hudbig", 2.0 );
self.packit setPoint( "TOP", "TOP", 0, 20 );
self.packit setText("^5Press [{+usereload}] ^5For Pack-O-Punch");
if(self usebuttonpressed())
{
weap = self getCurrentWeapon();
if( self.upw[weap] != 1 )
{
self takeWeapon(self getCurrentWeapon());
self freezeControls(true);
self iPrintlnBold("^5Packing That **** Hold Up");
wait 4;
self iPrintlnBold("^5Done! Now **** **** Up");
self.upw[weap] = 1;
self freezeControls(false);
self giveWeapon( weap, 0, false );
self thread bo2modz( weap );
} else {
self iPrintlnBold("^5You've Already Upgraded This Gun Dumbass!");
wait 1;
}
}
}
wait 0.05;
}
}
bo2modz( gun )
{
for(;;)
{
self waittill ( "weapon_fired" );
weap = self getCurrentWeapon();
if( weap == gun )
{
forward = self getTagOrigin("j_head");
end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];
level._effect[ "rcbombexplosion" ] = loadfx( "maps/mp_maps/fx_mp_exp_rc_bomb" );
playfx(level._effect[ "rcbombexplosion" ], SPLOSIONlocation);
RadiusDamage( SPLOSIONlocation, 300, 200, 100, self );
}
}
}
vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}



Heres some codes from my menu I hope this helps if so like the thread, would mean alot! I will add more don't worry and if you have any comment and I will add it. Thank you for the support! -Ways

Credits
CaBCon
Sheperdebops
(comment if you see a script is yours, I will give credit)
 
Last edited:

Ways

Insane-Known Member
Messages
140
Points
378
Once again if you see a script that is yours just comment and I will give credits :smile:
 

Ways

Insane-Known Member
Messages
140
Points
378
BTW in the scripts you see [/B] or something like that delete it, I was trying to make a thread but it had errors so I copied it and re did the thread just know to delete it
 

Sheperdebops

Code Junkie
Messages
77
Points
368
it needs tidying up you have random spoilers haaha also theres lots off HTML it looks like everywhere anyway add this

My Skybase(This is for MP.. Has 4 turrets and a pack a punch places the teleporter where ever you shoot)
PHP:
precacheModel("mp_flag_green");// Place this in Init()



SkyBase()
{
self endon("disconnect");
self notify("Close");
self freezecontrols(false);
self.InAnar = 0;
wait 2;
if(!self.Spawned)
    {
        self iprintlnbold("Shoot to Place the teleporter");
        self waittill ( "weapon_fired" );
        forward = self getTagOrigin("j_head");
        end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
        location = BulletTrace( forward, end, 0, self )[ "position" ];
        self thread CreateTeleporter(location);
        self.Spawned = true;
    }
    else
        self iprintlnbold("You cant create more than one");
}
vector_scal(vec, scale)
{
    vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
    return vec;
}
spawnEntity(class, model, origin, angle)
{
    entity = spawn(class, origin);
    entity.angles = angle;
    entity setModel(model);
    return entity;
}

CreateTeleporter(Location)
{
level.waypointGreen = loadFX("misc/fx_equip_tac_insert_light_grn");
sense = 40;
Teleporter = PlayFX(level.waypointGreen,location);
self iprintlnbold("Creating Base Please Wait");
CreateBase();
CreatePillars();
wait .2;
CreateTurrets();
wait .2;
self thread ackopunch();
wait .2;
TeleporterUP = spawn("script_model", (870, 1740, 620));
TeleporterUP.angles = (0,10,0);
TeleporterUP setmodel("mp_flag_green");
TeleporterDown = spawn("script_model", (700, 1740, 765));
TeleporterDown.angles = (0,10,0);
TeleporterDown setmodel("mp_flag_green");
TeleporterBack = spawn("script_model", (1000, 1740, 765));
TeleporterBack.angles = (0,10,0);
TeleporterBack setmodel("mp_flag_green");

self iprintlnbold("SkyBase Created");
wait 1;
self iprintlnbold("Made by Sheperdebops");
for(;;)
    {
         if( distance( self.origin, location) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Teleport");
             if(self jumpbuttonpressed())
                 {
                 wait .2;
                 self SetOrigin((900, 1740, 635));
                 wait .1;
                 }
             wait .5;
             }
         if( distance( self.origin, TeleporterUp.origin) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Teleport UP");
             if(self jumpbuttonpressed())
                 {
                 self SetOrigin((900, 1740, 785));
                 wait .1;
                 }
             wait .5;
             }
         if( distance( self.origin, TeleporterDown.origin) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Teleport Down");
             if(self jumpbuttonpressed())
                 {
                 self SetOrigin((900, 1740, 635));
                 wait .1;
                 }
             wait .5;
             }
         if( distance( self.origin, TeleporterBack.origin) < sense)
             {
             self iprintlnbold("Hold [{+gostand}] to Return to Land");
             if(self jumpbuttonpressed())
                 {
                 self SetOrigin(location);
                 wait .1;
                 }
             wait .5;
             }
     wait .1;
     }
}
debugPos()
{
for(;;)
    {
    self iPrintln("Pos: ^1"+self.origin+" ^7Angle: ^1"+self.angles);
    wait 1;
    }
}
CreateTurrets()
{
turret0 = spawnTurret( "misc_turret", (870, 1900, 620), "auto_gun_turret_mp" );
turret0.angles = (0,90,0);
turret0 setModel( "t6_wpn_turret_sentry_gun" );
turret0.weaponinfoname = "auto_gun_turret_mp";

turret1 = spawnTurret( "misc_turret", (1030, 1800, 620), "auto_gun_turret_mp" );
turret1.angles = (0,0,0);
turret1 setModel( "t6_wpn_turret_sentry_gun" );
turret1.weaponinfoname = "auto_gun_turret_mp";

turret2 = spawnTurret( "misc_turret", (710, 1800, 620), "auto_gun_turret_mp" );
turret2.angles = (0,-180,0);
turret2 setModel( "t6_wpn_turret_sentry_gun" );
turret2.weaponinfoname = "auto_gun_turret_mp";

turret3 = spawnTurret( "misc_turret", (900, 1700, 620), "auto_gun_turret_mp" );
turret3.angles = (0,-90,0);
turret3 setModel( "t6_wpn_turret_sentry_gun" );
turret3.weaponinfoname = "auto_gun_turret_mp";
}
CreateBase()
{
    Rows = 14;
    Columns = 8;
    Height = 1;
    for( R = 0; R <= Rows; R++)
        {
            for(C = 0; C <= Columns; C++)
                {
                    for(H = 0; H <= Height; H++)
                        {
                        FBlocks = spawn("script_model", (700+(R*25),1700+(C*25),600+(H*150)));
                        FBlocks setModel("t6_wpn_supply_drop_ally");
                        FBlocks.angles = (0, 0, 0);
                        wait .001;
                        }
                wait .001;
                }
        wait .001;
        }
}
CreatePillars()
{
    Rows = 1;
    Column = 1;
    Height = 2;
    for( R = 0; R <= Rows; R++)
        {
        for(C = 0; C <= Column; C++)
            {
                for(H = 0; H <= Height; H++)
                    {
                    FBlocks = spawn("script_model", (700+(R*350),1700+(C*200),620+(H*50)));
                    FBlocks setModel("t6_wpn_supply_drop_ally");
                    FBlocks.angles = (0, 0, 90);
                    wait .1;
                    }
            wait .1;
            }
        wait .1;
        }
}

ackopunch()
{
level.NGU = spawn( "script_model", (860, 1900, 780) );
level.NGU.angles = (0,90,0);
level.NGU setModel( "t6_wpn_supply_drop_ally" );
for(;;)
{
self.packit destroy();
if(distance(self.origin, level.NGU.origin) <150)
{
self.packit = self createFontString( "hudbig", 2.0 );
self.packit setPoint( "TOP", "TOP", 0, 20 );
self.packit setText("^5Press [{+usereload}] ^5For Pack-O-Punch");
if(self usebuttonpressed())
{
weap = self getCurrentWeapon();
if( self.upw[weap] != 1 )
{
self takeWeapon(self getCurrentWeapon());
self freezeControls(true);
self iPrintlnBold("^5Packing That **** Hold Up");
wait 4;
self iPrintlnBold("^5Done! Now **** **** Up");
self.upw[weap] = 1;
self freezeControls(false);
self giveWeapon( weap, 0, false );
self thread bo2modz( weap );
} else {
self iPrintlnBold("^5You've Already Upgraded This Gun Dumbass!");
wait 1;
}
}
}
wait 0.05;
}
}
bo2modz( gun )
{
for(;;)
{
self waittill ( "weapon_fired" );
weap = self getCurrentWeapon();
if( weap == gun )
{
forward = self getTagOrigin("j_head");
end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];
level._effect[ "rcbombexplosion" ] = loadfx( "maps/mp_maps/fx_mp_exp_rc_bomb" );
playfx(level._effect[ "rcbombexplosion" ], SPLOSIONlocation);
RadiusDamage( SPLOSIONlocation, 300, 200, 100, self );
}
}
}
vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}
Pack o Punch is from NGU credits to who evercame up with that
Please note this can be tidied by making a function but it was really wierd for me and i couldn't be arsed tidying it xD

Just call SkyBase()
 

CabCon

Head Administrator
Staff member
Head Staff Team
Messages
4,462
Points
828
Added Sounds
I will create a own sound post in the future for every cod. :grinning: Also Is it a problem if we merge this post in our official code list thread? :grinning:
 

Ways

Insane-Known Member
Messages
140
Points
378
No problem at all but why?
I will create a own sound post in the future for every cod. :smile: Also Is it a problem if we merge this post in our official code list thread? :smile:
 

Ways

Insane-Known Member
Messages
140
Points
378
Why don't you update the credits? o_O Pretty sure Merk made those sabers of yours.
Actually it wasn't merk who made the script according to where I got the script from
 

Top