Glitches, Cheats, Reviews, Discussions for the Latest and Hottest Video Games

Welcome to our forums Guest. We hope you have a nice stay Smile || New Better AllRoundTech.com

    Code: Gun Game

    Share
    avatar
    iPROFamily
    Administrator
     Administrator

    Posts : 309
    Points : 21267
    Reputation : 53
    Join date : 2011-03-22
    Location : iPROFamily World

    Code: Gun Game

    Post by iPROFamily on Thu Apr 21, 2011 7:01 pm

    Before i start i want to say thank you to XKevin356.

    Call this from your menu: doGungame

    Heres the code

    Code:
    doGungame()
    {
       self iPrintlnBold("^5No Cheating!");
       for ( t=0; t < level.players.size; t++ )
       {
          players = level.players[t];
          players notify ("gungame_start");
          players thread hintMessage("^5Gun Game Is Starting...");
          players thread initGuns();
          players thread doGun();
          setDvar( "cg_objectiveText", "Get a kill to change weapon and get 20 kills and become victorius");
          setDvar("player_sustainAmmo", 0);
          setDvar("g_gametype", "dm");
          setDvar("scr_player_maxhealth", 30);
          setDvar( "scr_game_perks", "0" );
          setDvar("player_meleerange", 0);
          setDvar("jump_height", 69);
          setDvar("g_gravity", 400);
          setDvar("g_speed", 220);
          setDvar("scr_dm_scorelimit", ((self.gunList.size - 1) * self.upgscore) + (self.finalkills * 5));
           setDvar("scr_dm_timelimit", 0);
           setDvar("scr_game_hardpoints", 0);
          setDvar("lobby_status", 1);
          players clearPerks();
          players suicide();
       }
    }
    initGuns()

       self.inverse = false;
       self.upgscore = 5;
        self.finalkills = 1;
        self.gunList = [];
       self.gunList[0] = createGun("colt_mp", true);
       self.gunList[1] = createGun("nambu_mp", true);
       self.gunList[2] = createGun("walther_mp", true);
       self.gunList[3] = createGun("gewehr43_mp", false);
       self.gunList[4] = createGun("m1carbine_mp", false);
       self.gunList[5] = createGun("stg44_mp", false);
       self.gunList[6] = createGun("shotgun_mp", true);
       self.gunList[7] = createGun("doublebarreledshotgun_mp", true);
       self.gunList[8] = createGun("springfield_mp", false);
       self.gunList[9] = createGun("kar98k_mp", false);
       self.gunList[10] = createGun("ptrs41_mp", false);
       self.gunList[11] = createGun("mp40_mp", false);
       self.gunList[12] = createGun("ppsh_mp", false);
       self.gunList[13] = createGun("type100smg_mp", false);
       self.gunList[14] = createGun("thompson_mp", false);
       self.gunList[15] = createGun("bazooka_mp", false);
       self.gunList[16] = createGun("dp28_mp", false);
       self.gunList[17] = createGun("bar_mp", false);
       self.gunList[18] = createGun("mg42_mp", false);
       self.gunList[19] = createGun("fg42_mp", false);
       self.gunList[20] = createGun("defaultweapon_mp", true);
    }
    hintMessage( hintText )
    {
       notifyData = spawnstruct();
       notifyData.notifyText = hintText;
       notifyData.glowColor = (1, 1, 0);
       self thread maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
    }
    createGun(gunName, laserSight)
    {
        gun = spawnstruct();
        gun.name = gunName;
        gun.laser = laserSight;
        return gun;
    }

    doGun()
    {
        self endon("disconnect");
        if(self.inverse) self.curgun = self.gunList.size - 1;
        else self.curgun = 0;
        curscore = 0;
        done = false;
        while(true){
            if(self.inverse && self.curgun <= 0) done = true;
            if(!self.inverse && self.curgun >= (self.gunList.size - 1)) done = true;
            if(!done){
               if(self.inverse && (self.score - curscore >= self.upgscore)){ 
                self.curgun--;
               self thread hintMessage("^1Weapon Downgraded!");
               curscore = self.score;
               }else if((self.score - curscore >= self.upgscore)){
                 self.curgun++;
                 self thread hintMessage("^5Weapon Upgraded - Level "+self.curgun);
                 curscore = self.score;
                 }
           }
           while(self getCurrentWeapon() != self.gunList[self.curgun].name){
           if(self.gunList[self.curgun].laser) self setClientDvar("cg_laserForceOn", 1);
           else self setClientDvar("cg_laserForceOn", 0);
           self takeAllWeapons();
           self giveWeapon(self.gunList[self.curgun].name);
           self switchToWeapon(self.gunList[self.curgun].name);
           wait .2;
           }
           self giveMaxAmmo(self.gunList[self.curgun].name);
           wait .2;
       }
    }
    This takes effect on everyone in the lobby!
    avatar
    skeptajme
    Moderators
    Moderators

    Posts : 37
    Points : 906
    Reputation : 0
    Join date : 2011-04-20
    Age : 24
    Location : UK''London

    Re: Code: Gun Game

    Post by skeptajme on Fri Apr 22, 2011 1:10 pm

    i want to hack so bad could u tell mw how plz thnx????


    ____________________________________________________________________________________________________________________________________________________
    [You must be registered and logged in to see this image.]
    [You must be registered and logged in to see this link.]


      Current date/time is Tue Oct 17, 2017 11:39 pm