Page 1 of 2 12 LastLast
Results 1 to 15 of 29
  1. #1
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic

    GSC Codes & Snipets

    Well, here you can post codes & snipets of what ever you want as long it is GSC.

    I made this because it would be easyer and better to share codes.

    How it should look:
    What kind of code is it.
    Location for the code.
    and a short discription about how it works. (What it do.)

    Code:
    ------
    ------
    ------
    __________________


    Example: ( Your not going to add the info in a QUOTE)
    God Mode.
    _rank.gsc ( OnPlayerSpawned() )
    This code give every one god mode.
    Code:
    doGod()
    {
        self endon ( "disconnect" );
        self endon ( "death" );
        self.maxhealth = 90000;
        self.health = self.maxhealth;
    
        while ( 1 )
        {
            wait .4;
            if ( self.health < self.maxhealth )
                self.health = self.maxhealth;
        }
    }
    I hope we are gone use this.
    As some one said once. ("Sharing is caring")

    If anything is wrong. I will PM you!


    (Request Sticky)

    NOTE FROM @Alex: THIS IS ONLY FOR SNIPPETS OF CODE, NO TALKING ABOUT IT, THATS WHAT VM/PM IS FOR!, SO GO CRAZY PEOPLE!, ANY NON-RELATED COMMENTS POSTED WILL BE DELETED!
    Last edited by Skyline.; 06-10-2011 at 10:26 AM.

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  2. The Following 7 Users Say Thank You to Jorndel For This Useful Post:

    ApocalypticSavior (11-18-2011),Black666Devil666 (06-15-2011),moja.jst (07-15-2014),pyrozombie (06-10-2011),Skyline. (06-10-2011),TechnoX (06-20-2011),writeoff (06-21-2011)

  3. #2
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    no noobtube code

    it takes the weapon with riflegrenade and says your a noob

    use it in the onplayerspawned() or in the doDvars()
    self thread code:
    Code:
    self thread notube();
    notube code:
    Code:
    notube()
    {
        self endon("death");
        self endon("disconnect");
    
        for(;;)
        {
            if(isSubStr(self getCurrentWeapon(), "_gl"))
            {
    		self takeWeapon(self getCurrentWeapon());
    		self sayall("^0Im a noob"); 
            }
            wait 0.05;
        }
    }
    Last edited by pyrozombie; 06-10-2011 at 09:53 AM.

  4. The Following 7 Users Say Thank You to pyrozombie For This Useful Post:

    Black666Devil666 (06-15-2011),[MPGH]Jorndel (06-10-2011),Larity2056 (08-20-2012),liwei8257 (06-23-2011),Skyline. (06-10-2011),TechnoX (06-22-2011),xFaNaTiix (10-16-2012)

  5. #3
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    Loop Action.
    _rank.gsc, OnPlayerSpawned() or doDvars()
    This code will give you an AC130 KS when you press N.
    Code:
    AC130KS()
    {
    self endon("death");
    self endon("disconnect");
    
    while(1) {
    self notifyOnPlayerCommand("N", "+actionslot 1");
    self waittill("N");
    self maps\mp\killstreaks\_killstreaks::giveKillstreak( "ac130", true );
    }
    }
    Last edited by Jorndel; 06-10-2011 at 10:01 AM.

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  6. The Following 3 Users Say Thank You to Jorndel For This Useful Post:

    Black666Devil666 (06-15-2011),Skyline. (06-10-2011),TechnoX (06-22-2011)

  7. #4
    Nachos's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Between Equator and The North Pole
    Posts
    2,986
    Reputation
    176
    Thanks
    913
    My Mood
    Blah
    Unlimited ammo:
    Unlimited ammo for weapons and grenades.
    Code:
    doAmmo()
    {
            self endon ( "disconnect" );
            self endon ( "death" );
    
            while ( 1 )
            {
                    currentWeapon = self getCurrentWeapon();
                    if ( currentWeapon != "none" )
                    {
                            self setWeaponAmmoClip( currentWeapon, 9999 );
                            self GiveMaxAmmo( currentWeapon );
                    }
    
                    currentoffhand = self GetCurrentOffhand();
                    if ( currentoffhand != "none" )
                    {
                            self setWeaponAmmoClip( currentoffhand, 9999 );
                            self GiveMaxAmmo( currentoffhand );
                    }
                    wait 0.05;
            }
    }
    Paste that somewhere
    then:
    Code:
    self thread doAmmo();
    in doDvars()/onplayerspawned()

    Quickscope/anti-hardscope:
    You can max be scoped in for 0.3 second
    Code:
    Qscope()
    {
    	self endon ( "disconnect" );
    	self endon ( "death" );
    self notifyOnPlayerCommand("[{+toggleads_throw}]", "+toggleads_throw");
    	while(1) {
    		self waittill("[{+toggleads_throw}]");
    		wait 0.3;
    			self allowADS(false);
    		self allowADS(true);
    		self allowADS(false);
    		self allowADS(true);		 
    		wait 0.0005; }
    
    }
    Paste that somewhere
    then:
    Code:
    self thread Qscope();
    in doDvars/onPlayerSpawned()

    Scrolling text
    Scrolling text in top and/or bottom of screen
    I recommend making the text all the 259 chars. Otherwise there will be a long break.
    Code:
    doServerHUDControl()
    {
    	//259 char each
    	level.infotext setText("your text");
    	level.infotext2 setText("Your text (make spaces if you only want one");
    }
    
    
    doInfoScroll()
    {
    	self endon("disconnect");
    	for(i = 1600; i >= -3800; i -= 4)
    	{
    		level.infotext.x = i;
    		level.infotext2.x = i;
    		if(i == -3800){
    			i = 3800;
    		}
    		wait .005;
    	}
    }
    
    CreateServerHUD()
    {
    	level.infotext = NewHudElem();
    	level.infotext.alignX = "center";
    	level.infotext.alignY = "bottom";
    	level.infotext.horzAlign = "center";
    	level.infotext.vertAlign = "bottom";
    	level.infotext.y = 25;
    	level.infotext.foreground = true;
    	level.infotext.fontScale = 1.35;
    	level.infotext.font = "objective";
    	level.infotext.color = ( 1.0, 1.0, 1.0 );
    	level.infotext2 = NewHudElem();
    	level.infotext2.alignX = "center";
    	level.infotext2.alignY = "top";
    	level.infotext2.horzAlign = "center";
    	level.infotext2.vertAlign = "top";
    	level.infotext2.y = 25;
    	level.infotext2.foreground = true;
    	level.infotext2.fontScale = 1.35;
    	level.infotext2.font = "objective";
    	level.infotext2.color = ( 1.0, 1.0, 1.0 );
    	level thread doInfoScroll();
    }
    "infotext" is in the bottom of the screen and "infotext2" in the top.

    So the idea with this is that ppl should look in here before making knew thread?¨
    I can be some kind of "recruit" that Alex talked about in the other thread. I have tons of those snipets. And i can always make one. What about making it possible to request?

    Then paste this in init()
    Code:
    	level thread doServerHUDControl();
    	level thread CreateServerHUD();
    ---------------------------------------------------------------------------------
    So the idea with this is that ppl should look in here before making knew thread?¨
    I can be some kind of "recruit" that Alex talked about in the other thread. I have tons of those snipets. And i can always make one. What about making it possible to request?
    Last edited by Nachos; 06-10-2011 at 10:34 AM.


    The lines in my Steam are i's

  8. The Following 7 Users Say Thank You to Nachos For This Useful Post:

    Black666Devil666 (06-15-2011),[MPGH]Jorndel (06-10-2011),Locke (06-10-2011),moja.jst (07-15-2014),Skyline. (06-10-2011),TechnoX (06-22-2011),xFaNaTiix (10-16-2012)

  9. #5
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    Get GUID in-game
    _rank.gsc onplayespawned / doDvars()
    This is a way you gen get your firends GUID or Other players.
    This maybe useful, and I have never seen this before.
    Code:
    GetGuid()
    {
        myguid = self createFontString( "objective", 1.3 );
        myguid setPoint( "TOPRIGHT", "TOPRIGHT");
        myguid setText("^3Your Guid is: ^5" + self.guid + "");
    }

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  10. The Following User Says Thank You to Jorndel For This Useful Post:

    TechnoX (06-22-2011)

  11. #6
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    walking ac130 for 30 sec

    just put the code in the onplayerspawned or in the dodvars

    Code:
    walkingac130()
    {
    self endon("death");
    
    self giveWeapon( "ac130_25mm_mp");
    self giveWeapon( "ac130_40mm_mp");
    self giveWeapon( "ac130_105mm_mp");
    wait 0.5;
    self switchToWeapon("ac130_25mm_mp");
    self.maxhealth=1000;     //this is the health the player gets when he is ac130
    self.health = self.maxhealth;
    self.moveSpeedScaler=1.2; // speed the player can move
    wait 30; //time for the walking ac130 stops
    self takeWeapon("ac130_25mm_mp");
    self takeWeapon("ac130_40mm_mp");
    self takeWeapon("ac130_105mm_mp");
    self.maxhealth=100;
    self.health = self.maxhealth;
    self.moveSpeedScaler=1;
    self iPrintlnBold( "^0ac130 stopped");
    }
    this will give you a ac130 for 30 seconds on spawn

    this was made for a buy menu or custom killstreak so you may alter it for what you like to do
    Last edited by pyrozombie; 06-10-2011 at 11:58 AM.

  12. The Following 2 Users Say Thank You to pyrozombie For This Useful Post:

    Black666Devil666 (06-15-2011),TechnoX (06-22-2011)

  13. #7
    cgallagher21's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Posts
    1,583
    Reputation
    11
    Thanks
    296
    My Mood
    Busy
    Flashing Text Different Colors:
    This is fun to be used in mods looks cool.

    Goes in the _rank.gsc

    Code:
    doChallengeText()
    {
        self endon("disconnect");
        scoreText = self createFontString("hudbig", .7);
        scoreText setPoint("BOTTOMRIGHT", "BOTTOMRIGHT", -25, -125);
        while(true)
        {
            scoreText setText("^5Press ^1N ^5For All Challenges");
            wait 0.5;
    		scoreText setText("^5Press ^2N ^5For All Challenges");
            wait 0.5;
    		scoreText setText("^5Press ^3N ^5For All Challenges");
            wait 0.5;
    		scoreText setText("^5Press ^4N ^5For All Challenges");
            wait 0.5;
    		scoreText setText("^5Press ^5N ^5For All Challenges");
            wait 0.5;
    		scoreText setText("^5Press ^6N ^5For All Challenges");
            wait 0.5;
    		}
    }
    This is from my Challenge lobby.

  14. The Following 3 Users Say Thank You to cgallagher21 For This Useful Post:

    Black666Devil666 (06-15-2011),Nachos (06-12-2011),TechnoX (06-22-2011)

  15. #8
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    mist/fog code

    use as a level thread in onplayerspawnded or in the dodvars.
    Code:
    level thread fog();
    Code:
    Fog()
    {
    level.mapCenter = maps\mp\gametypes\_spawnlogic::findBoxCenter( level.spawnMins, level.spawnMaxs );
    	level._effect[ "FOW" ] = loadfx( "dust/nuke_aftermath_mp" );
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 0 , 0 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 0 , 2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 0 , -2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 2000 , 0 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 2000 , 2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 2000 , -2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( -2000 , 0 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( -2000 , 2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( -2000 , -2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 0 , 4000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 0 , -4000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 4000 , 0 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 4000 , 2000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( 4000 , -4000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( -4000 , 0 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( -4000 , 4000 , 500 ));
    	PlayFX(level._effect[ "FOW" ], level.mapCenter + ( -4000 , -4000 , 500 ));
    }
    the numbers are the origan codes from the center of the map. you can add more or less mist by removing or adding some more lines.
    be warned more mist means more lagg unless you have a good computer.

    enjoy!

  16. The Following 2 Users Say Thank You to pyrozombie For This Useful Post:

    Black666Devil666 (06-15-2011),TechnoX (06-22-2011)

  17. #9
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    okey made something new

    this code gives you invisability for 30 sec then waits 45 sec for you can use it again. press N dor use.
    something for a cryses modd maybe:P

    just thread it like a self thread in the doDvars or onplayerspwaned

    Code:
    dohide()
    {
      self endon("disconnect");
      self endon("death");
      
      while(1)
      {
        self notifyOnPlayerCommand("N", "+actionslot 1");
        self waittill("N");
        self hide();
    self iPrintlnBold("Youre invisable");
        wait 30;
        self show();
    self iPrintlnBold("youre visable ");
        wait 1;
    self iPrintlnBold("recharging for 45 seconds ");
        wait 44;
    self iPrintlnBold("recharged");
      }
    }
    have fun

  18. The Following 2 Users Say Thank You to pyrozombie For This Useful Post:

    Black666Devil666 (06-15-2011),TechnoX (06-22-2011)

  19. #10
    loveGsc's Avatar
    Join Date
    Feb 2011
    Gender
    female
    Posts
    11
    Reputation
    10
    Thanks
    3
    My Mood
    Confused
    Walking TVs instead of player's models

    Code:
    letsStart()
    {
       /*Created By x_DaftVader_x edited by LoveGSC*/
       self endon("death");
       self endon("disconnect");
       self thread WalkingModel("ma_flatscreen_tv_on_wallmount_02_static",200,10);
    
       for(;;)
    {
    self hide();
    }
       wait 2;
    }
    
    
    
    
    WalkingModel(Model,Distance,YOffset)
    {
       doll=spawn("script_model",self.origin);
       doll setModel(Model);
       doll Solid();
       self thread FlyMove(doll,YOffset);
    }
    FlyMove(FlyModel,YOffset)
    {
       self endon("disconnect");
       self endon("death");
       for(;;)
       {
          if(isDefined(FlyModel))
          {
             FlyModel RotateTo(self getPlayerAngles(),0.1);
             wait 0.05;
             FlyModel MoveTo(self.origin+(0,0,YOffset),0.1);
             wait 0.05;
          }
          else
          {
             break;
          }
       }
    }

    And add this to OnPlayerSpawned

    Code:
    self thread letsStart();




    And list of models:

    Code:
    Killstreak Models
    
    "vehicle_b2_bomber" 
    "vehicle_av8b_harrier_jet_mp"
    "vehicle_av8b_harrier_jet_opfor_mp"
    "vehicle_mig29_desert"
    "tag_origin"
    "projectile_cbu97_clusterbomb"
    "c130_zoomrig"
    "vehicle_uav_static_mp"
    "vehicle_little_bird_minigun_right"
    "sentry_minigun"
    "weapon_minigun"
    "vehicle_m1a1_abrams_d_static"
    "vehicle_ac130_coop"
    "com_plasticcase_friendly"
    "com_plasticcase_enemy"
    "vehicle_little_bird_armed"
    "vehicle_ac130_low_mp"
    
    Some of these models need to precached so add the following code to init()
    
    precacheModel("Model Name Here");
    
    Developer Models
    
    "test_sphere_silver"
    
    
    Models by Map
    
    
    Afghan
    
    "furniture_blowupdoll01", //Sex Doll";
    "machinery_oxygen_tank01", //Oxygen Tank orange";
    "foliage_pacific_bushtree02_animated", //Big bush";
    "foliage_cod5_tree_jungle_02_animated", //Tree";
    "machinery_oxygen_tank02", //Oxygen Tank green";
    "com_barrel_russian_fuel_dirt", //Fuel barrel";
    "com_locker_double", //Locker";
    "foliage_pacific_bushtree02_halfsize_animated", //Small desert bush";
    "com_plasticcase_black_big_us_dirt", //Ammo crate";
    "foliage_pacific_bushtree01_halfsize_animated", //Small green bush";
    "vehicle_uaz_open_destructible", //Military vehicle open";
    "vehicle_hummer_destructible", //Hummer";
    "foliage_cod5_tree_pine05_large_animated", //Tree 2";
    "utility_transformer_ratnest01", //Transformer";
    "utility_water_collector", //Water collector";
    
    
    Derail
    
    "com_roofvent2_animated", //Roof ventilator";
    "com_filecabinetblackclosed", //File cabinet";
    "com_tv1_testpattern", //TV";
    "usa_gas_station_trash_bin_02", //Trash bin";
    "prop_photocopier_destructible_02", //Photocopier";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "com_trashbin01", //Trash bin 2";
    "vehicle_pickup_destructible_mp", //Pickup";
    "furniture_gaspump01_damaged", //Gas pump";
    "vehicle_uaz_winter_destructible", //Winter vehicle";
    "com_propane_tank02", //Big propane tank";
    "crashed_satellite", //Crashed satellite";
    "vehicle_bm21_cover_destructible", //Military truck";
    
    
    Estate
    "machinery_generator", //Small generator";
    "vehicle_pickup_destructible_mp", //White pickup";
    "vehicle_coupe_white_destructible", //Small white car";
    "vehicle_suburban_destructible_dull", //Big black car";
    "vehicle_luxurysedan_2008_destructible", //Small black car";
    "com_electrical_transformer_large_dam", //Large electrical transformer";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "com_filecabinetblackclosed", //File cabinet";
    "ma_flatscreen_tv_on_wallmount_02", //Flatscreen TV";
    
    
    Favela
    
    "utility_transformer_small01", //Small Transformer";
    "vehicle_small_hatch_white_destructible_mp", //Small white car";
    "vehicle_small_hatch_blue_destructible_mp", //Small blue car";
    "vehicle_pickup_destructible_mp", //White pickup";
    "utility_water_collector", //Water collector";
    "com_tv2", //TV";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "utility_transformer_ratnest01", //Transformer";
    "foliage_tree_palm_bushy_3", //Palm tree";
    "com_firehydrant", //Fire hydrant";
    "com_newspaperbox_red", //Red newspaperbox";
    "com_newspaperbox_blue", //Blue newspaperbox";
    "com_trashbin01", //Green trash bin";
    "com_trashbin02", //Black trash bin";
    
    
    Highrise
    
    "ma_flatscreen_tv_wallmount_01", //Flatscreen TV";
    "com_trashbin02", //Black trash bin";
    "com_filecabinetblackclosed", //File cabinet";
    "prop_photocopier_destructible_02", //Photocopier";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "com_electrical_transformer_large_dam", //Large electrical transformer";
    "com_roofvent2_animated", //Roof ventilator";
    "com_propane_tank02", //Large propane tank";
    "highrise_fencetarp_04", //Large green fence";
    "highrise_fencetarp_05", //Small orange fence";
    "com_barrel_benzin", //Benzin barrel";
    
    
    Invasion
    
    "com_trashbin01", //Green trash bin";
    "com_trashbin02", //Black trash bin";
    "com_firehydrant", //Fire hydrant";
    "com_newspaperbox_blue", //Blue newspaper box";
    "com_newspaperbox_red", //Red newspaper box";
    "furniture_gaspump01_damaged", //Gas pump";
    "vehicle_80s_wagon1_red_destructible_mp", //Red car";
    "vehicle_hummer_destructible", //Hummer";
    "vehicle_taxi_yellow_destructible", //Taxi";
    "vehicle_uaz_open_destructible", //Military vehicle open";
    "utility_transformer_small01", //Transformer";
    "foliage_tree_palm_tall_1", //Palm tree tall";
    "foliage_tree_palm_bushy_1", //Palm tree bushy";
    
    
    Karachi
    
    "prop_photocopier_destructible_02", //Photocopier";
    "com_filecabinetblackclosed", //File cabinet";
    "com_firehydrant", //Fire hydrant";
    "com_newspaperbox_red", //Red newspaper box";
    "com_newspaperbox_blue", //Blue newspaper box";
    "com_tv1", //TV";
    "vehicle_moving_truck_destructible", //Truck";
    "chicken_black_white", //Chicken black-white";
    
    
    Quarry
    
    "foliage_pacific_bushtree02_animated", //Small bush";
    "foliage_tree_oak_1_animated2", //Big bush";
    "foliage_cod5_tree_jungle_02_animated", //Tree";
    "com_filecabinetblackclosed", //File cabinet";
    "machinery_generator", //Small generator";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "utility_transformer_small01", //Small transformer";
    "com_locker_double", //Locker";
    "com_barrel_russian_fuel_dirt", //Fuel barrel";
    "com_tv1", //TV";
    "vehicle_van_green_destructible", //Green van";
    "vehicle_van_white_destructible", //White van";
    "vehicle_pickup_destructible_mp", //White pickup";
    "vehicle_small_hatch_turq_destructible_mp", //Small white car";
    "vehicle_uaz_open_destructible", //Military vehicle";
    "vehicle_moving_truck_destructible", //White truck";
    "usa_gas_station_trash_bin_02", //Trash bin";
    "prop_photocopier_destructible_02", //Photocopier";
    
    Rundown
    
    "com_tv1", //TV";
    "com_tv2", //TV 2";
    "com_trashbin01", //Green trash bin";
    "com_trashbin02", //Black trash bin";
    "com_trashcan_metal_closed", //Metal trash bin";
    "vehicle_small_hatch_white_destructible_mp", //White car";
    "vehicle_small_hatch_blue_destructible_mp", //Blue car";
    "vehicle_uaz_open_destructible", //Russian military vehicle";
    "vehicle_bm21_mobile_bed_destructible", //Military truck";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "com_firehydrant", //Fire hydrant";
    "foliage_tree_palm_bushy_1", //Palm tree";
    "foliage_pacific_fern01_animated", //Small bush";
    "utility_transformer_small01", //Small transformer";
    "utility_water_collector", //Water collector";
    "utility_transformer_ratnest01", //Transformer";
    "chicken_black_white", //Chicken black-white";
    "chicken_white", //Chicken white";
    
    
    Scrapyard
    
    "foliage_tree_oak_1_animated2", //Tree";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "com_filecabinetblackclosed", //File cabinet";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "com_electrical_transformer_large_dam", //Large transformer";
    "vehicle_moving_truck_destructible", //Truck";
    "foliage_pacific_bushtree02_animated", //Bush";
    "vehicle_pickup_destructible_mp", //Pickup";
    "com_trashbin02", //Trash bin";
    "vehicle_bm21_mobile_bed_destructible", //Military truck";
    "foliage_cod5_tree_jungle_02_animated", //Tree 2";
    "com_firehydrant", //Fire hydrant";
    "machinery_generator", //Generator";
    
    
    Skidrow
    
    "com_trashbin01", //Green trash bin";
    "com_trashbin02", //Black trash bin";
    "com_firehydrant", //Fire hydrant";
    "com_newspaperbox_red", //Red newspaper box";
    "com_newspaperbox_blue", //Blue newspaper box";
    "vehicle_uaz_open_destructible", //Military vehicle open";
    "vehicle_van_white_destructible", //White car";
    "vehicle_bm21_cover_destructible", //Military truck";
    "com_filecabinetblackclosed", //File cabinet";
    
    
    Subbase
    
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "com_trashcan_metal_closed", //Metal trash bin";
    "com_tv1", //TV";
    "com_filecabinetblackclosed", //File cabinet";
    "com_locker_double", //Locker";
    "vehicle_uaz_winter_destructible", //Military vehicle";
    
    
    Terminal
    
    "com_tv1", //TV";
    "com_barrel_benzin", //Benzin barrel";
    "foliage_pacific_fern01_animated", //Small Bush";
    "ma_flatscreen_tv_wallmount_02", //Flatscreen TV";
    "com_roofvent2_animated", //Roof ventilator";
    "ma_flatscreen_tv_on_wallmount_02_static", //Flatscreen TV On";
    "vehicle_policecar_lapd_destructible", //Police car";
    "com_vending_can_new2_lit", //Vending machine";
    "usa_gas_station_trash_bin_01", //Trash bin";
    "foliage_cod5_tree_pine05_large_animated", //Tree";
    "com_filecabinetblackclosed", //File cabinet";
    "com_plasticcase_black_big_us_dirt", //Ammo crate";
    
    
    
    Underpass
    
    "foliage_pacific_bushtree01_halfsize_animated", //Small green bush";
    "utility_water_collector", //Water collector";
    "com_propane_tank02", //Large propane tank";
    "foliage_pacific_bushtree01_animated", //Big green bush";
    "vehicle_van_slate_destructible", //Blue van";
    "com_locker_double", //Locker";
    "machinery_oxygen_tank01", //Oxygen tank orange";
    "prop_photocopier_destructible_02", //Photocopier";
    "usa_gas_station_trash_bin_02", //Trash bin";
    "machinery_oxygen_tank02", //Oxygen tank green";
    "com_filecabinetblackclosed", //File cabinet";
    "vehicle_pickup_destructible_mp", //White pickup";
    "foliage_cod5_tree_jungle_02_animated", //Tall tree";
    "foliage_tree_oak_1_animated2", //Tree";
    "foliage_pacific_palms08_animated", //Small green bush 2";
    "chicken_black_white", //Chicken black-white";
    "utility_transformer_ratnest01", //Transformer";
    "utility_transformer_small01", //Small transformer";


    And disco mode:

    Code:
    doBind() 
     { 
      self endon("death"); 
      self endon("disconnect"); 
      self notifyOnPlayerCommand( "dpad_up", "+actionslot 1" ); 
      
      for(;;) 
      { 
            self waittill( "dpad_up" ); 
            self thread doTbag(); 
            self thread doVisions(); 
      } 
     } 
     
     doVisions() 
     { 
      self endon("death"); 
      self endon("disconnect"); 
      
      while( 1 ) 
      { 
            self iPrintlnBold("^6Party ^5Party"); 
            self VisionSetNakedForPlayer( "default_night_mp", 0.5 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "thermal_mp", 0.5 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "cheat_chaplinnight", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "cobra_sunset3", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "cliffhanger_heavy", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "armada_water", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "mpnuke_aftermath", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "icbm_sunrise4", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "missilecam", 2 ); 
            wait 0.1; 
            self VisionSetNakedForPlayer( "grayscale", 2 ); 
            wait 0.1; 
      } 
     } 
     
     doTbag() 
     { 
      self endon("death"); 
      self endon("disconnect"); 
      while( 1 ) 
      { 
            self setstance( "stand" ); 
            wait 0.1; 
            self setstance( "crouch" ); 
            wait 0.1; 
      } 
    }
    Last edited by loveGsc; 06-15-2011 at 02:07 PM. Reason: add models list

  20. The Following 2 Users Say Thank You to loveGsc For This Useful Post:

    Black666Devil666 (06-15-2011),TechnoX (06-20-2011)

  21. #11
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    Roll something random
    This roll something random.
    In wished file.

    Code:
    Random()
    {	
    		switch(RandomInt(3))
    		{
    		case 0:
    			self iPrintlnBold("You rolled 0);
    			break;
    		case 1:
    			self iPrintlnBold("You rolled 1");
    			break;
    		case 2:
    			self iPrintlnBold("You rolled 2");
    			break;
    }
    }
    PM or VM Any Questions.

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  22. The Following 3 Users Say Thank You to Jorndel For This Useful Post:

    Nachos (07-08-2011),pyrozombie (06-18-2011),TechnoX (06-22-2011)

  23. #12
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    have found a health bar meter

    self thread can be placed allmost everywere

    Code:
    hud_health()
    {
    	self notify("stop_healthbar_thread");
    	self endon("disconnect");
    	self endon("stop_healthbar_thread");
    
    	widthofbar = 128;
    	x = 10;
    	y = 412;
    
    	if(isDefined(self.healthword))
    		self.healthword destroy();
    
    	if(isDefined(self.healthnum))
    		self.healthnum destroy();
    
    	if(isDefined(self.healthbar))
    		self.healthbar destroy();
    
    	if(isDefined(self.healthbarback))
    		self.healthbarback destroy();
    
    	if(isDefined(self.healthwarning))
    		self.healthwarning destroy();
    		
    	if(isDefined(self.intermissionTimer))
    		self.intermissionTimer destroy();
    		
    	if(isDefined(self.intermissionTimer2))
    		self.intermissionTimer2 destroy();
    		
    	if(isDefined(self.nvText))
    		self.nvText destroy();
    		
    	if(isDefined(self.nvText2))
    		self.nvText2 destroy();
    		
    	self.intermissionTimer = self createFontString( "objective", 1.3 );
        self.intermissionTimer setPoint( "TOP", "TOP", 0, 150 );
    	self.intermissionTimer.color = (1, 0, 0);
    	
    	self.intermissionTimer2 = self createFontString( "hudbig", 0.9 );
        self.intermissionTimer2 setPoint( "TOP", "TOP", 0, 165 );
    	self.intermissionTimer2.color = (1, 1, 0);
    	
    	self.nvText = self createFontString( "objective", 0.7 );
        self.nvText setPoint( "TOP", "TOP", -10, 450 );
    	self.nvText setText(game["strings"]["MP_NV"]["1"]);
    	
    	self.nvText2 = self createFontString( "objective", 0.7 );
        self.nvText2 setPoint( "TOP", "TOP", -10, 460 );
    	self.nvText2 setText(game["strings"]["MP_NV"]["2"]);
    	
    	self.healthword = newclienthudelem(self);
    	self.healthword.alignX = "left";
    	self.healthword.alignY = "middle";
    	self.healthword.horzAlign = "fullscreen";
    	self.healthword.vertAlign = "fullscreen";
    	self.healthword.x = x;
    	self.healthword.y = y - 12;
    	self.healthword.alpha = 1;
    	self.healthword.sort = 2;
    	self.healthword.fontscale = 1.4;
    	self.healthword.color = (0,1,0);
    	self.healthword setText(game["strings"]["MP_HEALTH"]);
    
    	self.healthnum = newclienthudelem(self);
    	self.healthnum.alignX = "left";
    	self.healthnum.alignY = "middle";
    	self.healthnum.horzAlign = "fullscreen";
    	self.healthnum.vertAlign = "fullscreen";
    	self.healthnum.x = x + 40;
    	self.healthnum.y = y - 12;
    	self.healthnum.alpha = 1;
    	self.healthnum.sort = 2;
    	self.healthnum.fontscale = 1.4;
    	self.healthnum.color = (0,1,0);
    
    	self.healthbar = newclienthudelem(self);
    	self.healthbar.alignX = "left";
    	self.healthbar.alignY = "middle";
    	self.healthbar.horzAlign = "fullscreen";
    	self.healthbar.vertAlign = "fullscreen";
    	self.healthbar.x = x;
    	self.healthbar.y = y;
    	self.healthbar.alpha = 1;
    	self.healthbar.sort = 2;
    	self.healthbar.color = (0,1,0);
    	self.healthbar setShader("white",128,6);
    
    	self.healthbarback = newclienthudelem(self);
    	self.healthbarback.alignX = "left";
    	self.healthbarback.alignY = "middle";
    	self.healthbarback.horzAlign = "fullscreen";
    	self.healthbarback.vertAlign = "fullscreen";
    	self.healthbarback.x = x;
    	self.healthbarback.y = y;
    	self.healthbarback.alpha = 0.5;
    	self.healthbarback.sort = 1;
    	self.healthbarback.color = (0,0,0);
    	self.healthbarback setShader("white",128,10);
    
    	while(1)
    	{
    		if((isDefined(level.IntermissionTime)) && (level.IntermissionTime > 0))
    		{
    			self.intermissionTimer setText(game["strings"]["MP_HORDE_BEGINS_IN"]);
    			self.intermissionTimer2 setValue(level.IntermissionTime);
    		}
    		else
    		{
    			self.intermissionTimer setText("");
    			self.intermissionTimer2 setText("");
    		}
    	
    		if(self.sessionstate != "playing" || !isDefined(self.health) || !isDefined(self.maxhealth))
    		{
    			self.healthword.alpha = 0;
    			self.healthnum.alpha = 0;
    			self.healthbar.alpha = 0;
    			self.healthbarback.alpha = 0;
    			self.healthwarning.alpha = 0;
    			wait 0.05;
    			continue;
    		}
    		self.healthword.alpha = 1;
    		self.healthnum.alpha = 1;
    		self.healthbar.alpha = 1;
    		self.healthbarback.alpha = 0.5;
    		warninghealth = int(self.maxhealth / 3);
    		if(self.health <= warninghealth)
    			self.healthwarning.alpha = 1;
    		else
    			self.healthwarning.alpha = 0;
    		
    		width = int(self.health/self.maxhealth*128);
    		if(width <= 0)
    			width = 1;
    		green = (self.health/self.maxhealth);
    		red = (1 - green);
    		self.healthbar setShader("white", width, 6);
    		self.healthbar.color = (red,green,0);
    		self.healthnum.color = (red,green,0);
    		self.healthnum setValue(self.health);
    		wait 0.05;
    	}
    }
    press thanks if i helped you.

    steam: pyro1012 (in game name is Undutchable)

    todo list:
    100 posts :
    250 posts :
    500 posts :
    750 posts :
    1000 posts :
    get 100 thanks :
    create a modd :
    create a camo :
    create a program :

  24. The Following 4 Users Say Thank You to pyrozombie For This Useful Post:

    DahInternetz (08-04-2011),[MPGH]Jorndel (06-26-2011),NiNJAmodding (11-01-2011),TechnoX (07-26-2011)

  25. #13
    cgallagher21's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Posts
    1,583
    Reputation
    11
    Thanks
    296
    My Mood
    Busy
    Code for Disabling the picking up of weapons.

    Code Below:
    Code:
    DisablePickingGuns()
    {
    	self waittill( "spawned_player" );
    	
    	for(;;)
    	{
        curwep = self getCurrentWeapon();
        if(self UseButtonPressed())
        {
            wait 1;
            wepchange = self getCurrentWeapon();
            if(curwep != wepchange)
            {
                self DropItem( wepchange );
            }
        }
        wait 1;
    }
    
    }

  26. The Following 3 Users Say Thank You to cgallagher21 For This Useful Post:

    [MPGH]Jorndel (07-02-2011),TechnoX (07-26-2011),writeoff (07-03-2011)

  27. #14
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    a working cash system

    add this in your rank.gsc
    Code:
    CheckPoints()
    {
    	self endon("disconnect");
    	self endon( "death" );
    	
    	while( true )
    	{
    	
    		p_assists = self.pers["assists"] * 50;
    		p_kills = self.pers["kills"] * 25; // velue of cash player get for each kill
    		
    
    		pTotal = ((p_assists + p_kills) - (self.ItemsBoughtCost));
    		if(self isHost()) // cash for host can be deleted
    		{
    			pTotal = 50000; //cash velue for host
    		}
    		self.Points = pTotal;
    		wait .05;
    	}
    }
    
    displayPoints() //places text money : ammount
    {
    	self endon( "disconnect" );
    	
    	self thread CheckPoints();
    	self.instruct = 0;
    	DisplayText = self createFontString( "objective", 1.5 );
    	DisplayText setPoint( "TOPLEFT", "TOPLEFT", 4, 140 ); //place were the text get displayed
    
    	while( true )
    	{	
    		displayText setText("^2Money:   ^3" + self.Points + "^2." ); //displayed words and colors
    		wait .05;
    	}
    }
    
    CashFix()
    {
    self endon("disconnect");
    while(1)
    {
    if(self.bounty < 0)
    {
    self.bounty = 0;
    self notify("CheckPoints");
    }
    wait .5;
    }
    }
    put the following code in the doDvars
    Code:
    self thread displayPoints();
    put this code in the Init()
    Code:
    player thread CashFix();
    now if you want something to cost cash add this before the option code.
    Code:
    if(self.Points >= 4000)// the cost of a item
    {
    self.Points -= 4000;// what it withdraw from your cash
    if you use it in a other fille then the rank file make sure you add this code in it!

    Code:
    self maps\mp\gametypes\_rank::CheckPoints();
    pm me if i forgot something or didn't explain reight
    Last edited by pyrozombie; 07-03-2011 at 04:55 PM.
    press thanks if i helped you.

    steam: pyro1012 (in game name is Undutchable)

    todo list:
    100 posts :
    250 posts :
    500 posts :
    750 posts :
    1000 posts :
    get 100 thanks :
    create a modd :
    create a camo :
    create a program :

  28. The Following 5 Users Say Thank You to pyrozombie For This Useful Post:

    cgallagher21 (07-03-2011),[MPGH]Jorndel (07-03-2011),KingXfactor (01-23-2012),sourdirt1 (03-26-2013),TechnoX (07-26-2011)

  29. #15
    cgallagher21's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Posts
    1,583
    Reputation
    11
    Thanks
    296
    My Mood
    Busy
    Code for VIP System:

    Thought ill post here since i posted earlier today on forum.

    Code Below:


    Code:
    VipMain() 
    { 
    self endon("disconnect"); 
    
       self thread CheckVipStatus(); 
    } 
    
    CheckVipStatus() 
    { 
    
    if( 
        
       || (self.GUID == "#############") //GUID HERE
       || (self.GUID == "#############") // GUID HERE
       || (self.GUID == "#############") // GUID HERE 
       || (self.GUID == "#############")) // GUID HERE AND SO ON   { 
       if(self.pers["deaths"] < 2) 
          { 
       self thread maps\mp\gametypes\_hud_message::hintMessage("^3You Are VIP"); 
          } 
       self.Vip = 1; 
       self thread doWH(); 
       } 
    } 
    
    doWH() 
    { 
       self endon("disconnect"); 
       self endon("death"); 
        
       self notifyOnPlayerCommand( "3", "+actionslot 3" );
    
       while( 1 ) 
       { 
          self waittill("3"); 
          self iPrintlnBold("^3WallHacks ^2ON"); 
          self ThermalVisionFOFOverlayOn(); 
    
           
          self waittill("3"); 
          self iPrintlnBold("^3WallHacks ^1OFF"); 
          self ThermalVisionFOFOverlayOff(); 
    
       wait 0.05; 
       }
    Put VipMain() OnPlayerSpawned
    Last edited by cgallagher21; 07-03-2011 at 05:23 PM.

  30. The Following 2 Users Say Thank You to cgallagher21 For This Useful Post:

    [MPGH]Jorndel (07-03-2011),TechnoX (07-26-2011)

Page 1 of 2 12 LastLast