Thread: Mystery box

Results 1 to 6 of 6
  1. #1
    xbeatsszzx's Avatar
    Join Date
    Feb 2010
    Gender
    male
    Location
    Behind a dumpster jerking off. xD jks
    Posts
    2,520
    Reputation
    13
    Thanks
    1,494
    My Mood
    Asleep

    Mystery box

    YouTube - Black Ops Mystery Box

    Code:
    #include common_scripts\utility;
    
    #include maps\mp\_airsupport;
    #include maps\mp\_utility;
    
    #include maps\mp\gametypes\_hud_util;
    
    
    
    main()
    
    {
    }
    
    init()
    {
            thread onPlayerConnect();
            thread onPlayerConnected();
            level thread spawnBox();
    }
    
    onPlayerConnect()
    {       
            for(;;)
            {
                    level waittill( "connecting", player );
    
                    player thread onPlayerSpawned();
                    player thread onJoinedSpectators();
                    player thread doVars();
            }
    }
    
    onPlayerConnected()
    {       
            for(;;)
            {
                    level waittill( "connected", player );
    
                    player thread checkDistance();
            }
    }
    
    onPlayerSpawned()
    {
            for(;;)
            {
                    self waittill( "spawned_player" );
            
                    self thread welcomeLoop();
            }
    }
    
    onJoinedSpectators()
    {
            self endon( "disconnect" );
            
            for(;;)
            {
                    self waittill( "joined_spectators" );
            }
    }
    
    welcomeLoop()
    {
            self endon( "death" );
            
            while( 1 )
            {
                    self iPrintlnBold( "WELCOME TO THE LOBBY" );
                    wait 2;
                    self iPrintlnBold( "GO TO THE MYSTERY BOX!!!!" );
                    wait 2;
            }
    }
    
    spawnBox()
    {
            level.mBox = spawn( "script_model", ( 695.165, 343.891, -35.8556 ) );
            level.mBox setModel( "mp_supplydrop_ally" );
            level.mBox.angles = ( 0, 285, 0 );
            level.mGun = spawn( "script_model", level.mBox.origin );
            level.mGun setModel( GetWeaponModel( "claymore_mp" ) );
            level.mGun.angles = level.mBox.angles + ( 0, 90, 0 );
            level.mGun hide();
    }
    
    doVars()
    {
            setDvar( "scr_laststand_keep_weapons", 1 );
            setDvar( "scr_player_respawndelay", 5 );
            setDvar( "g_allow_teamchange", 0 );
            setDvar( "ui_allow_teamchange", 0 );
            self setClientDvar( "bg_fallDamageMinHeight", "9999" ); 
            self setClientDvar( "bg_fallDamageMaxHeight", "9999" );
            self setClientDvar( "ui_allow_teamchange", 0 );
            level.using = 0;
            self.usingg = 0;
    
            level.guns[0] = "aug_mp";
            level.guns[1] = "m16_mp";
            level.guns[2] = "spas_mp";
            level.guns[3] = "famas_mp";
            level.guns[4] = "rpk_mp";
            level.guns[5] = "rpg_mp";
            level.guns[6] = "m72_law_mp";
            level.guns[7] = "commando_mp";
            level.guns[8] = "python_mp";
            level.guns[9] = "ak74u_mp";
            level.guns[10] = "l96a1_mp";
            level.guns[11] = "fnfal_mp";
            level.guns[12] = "cz75_mp";
            level.guns[13] = "spectre_mp";
            level.guns[14] = "hk21_mp";
            level.guns[15] = "crossbow_explosive_mp";
            level.guns[16] = "knife_ballistic_mp";
            level.guns[17] = "m60_mp";
            level.guns[18] = "stoner63_mp";
    }
    
    checkDistance()
    {       
            while( 1 )
            {
                    wait .01;
            
                    if( distance( self.origin, level.mBox.origin ) < 75 && level.using == 0 )
                    {
                            self setLowerMessage( "Press [{+activate}] for Mystery Box" );
                            randWeap = randomInt( level.guns.size );
                            
                            for(;;)
                            {
                                    if( self useButtonPressed() == true && level.using == 0 && distance( self.origin, level.mBox.origin ) < 75 )
                                    {
                                            level.using = 1;
                                            self clearLowerMessage( 1.0 );
                                            level.mGun show();
                                            level.mGun moveTo( level.mBox.origin + ( 0, 0, 30 ), 1 );
                                            wait .2;
                                            for( i = 0; i < 14; i++ )
                                            {
                                                    rander = randomInt( level.guns.size );
                                                    level.mGun setModel( GetWeaponModel( level.guns[rander] ) );
                                                    wait( 0.025 * i );
                                            }
                                            level.mGun setModel( GetWeaponModel( level.guns[randWeap] ) );
                                            wait .5;
                                            for( i = 0; i < 0.5; i += 0.01 )
                                            {
                                                    self setLowerMessage( "Press [{+activate}] to Buy the Gun" );
            
                                                    if( self useButtonPressed() == true && distance( self.origin, level.mBox.origin ) < 75 )
                                                    {
                                                            self clearLowerMessage( 1.0 );
                                                            if( self GetWeaponsListPrimaries().size > 1 ) self takeWeapon( self getCurrentWeapon() );
                                                            self giveWeapon( level.guns[randWeap] );
                                                            self switchToWeapon( level.guns[randWeap] );
                                                            self giveMaxAmmo( level.guns[randWeap] );
                                                            i = 0.5;
                                                    }
                                                    else if( distance( self.origin, level.mBox.origin ) > 75 )
                                                    {
                                                            self clearLowerMessage( 1.0 );
                                                    }
                                                    wait 0.01;
                                            }
                                            self clearLowerMessage( 1.0 );
                                            level.mGun moveTo( level.mBox.origin, 1 );
                                            wait 1;
                                            level.mGun hide();
                                            level.using = 0;
                                            break;
                                    }
                                    else if( distance( self.origin, level.mBox.origin ) > 75 )
                                    {
                                            self clearLowerMessage( 1.0 );
                                            break;
                                    }
                                    wait 0.01;
                            }
                    }
                    else
                    {
                            self clearLowerMessage( 1.0 );
                    }
            }
            wait 0.01;
    }
    Credits:
    TLPWNZER

    //made for Wii, should work with the pc too. perhaps some little minor changes are needed
    I Am on this site for the mods for mw2 ONLY. Not hacks.

  2. #2
    cgallagher21's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Posts
    1,583
    Reputation
    11
    Thanks
    296
    My Mood
    Busy
    Looks good,.. For the wii lol

  3. #3
    d0h's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    trashbin
    Posts
    298
    Reputation
    24
    Thanks
    142
    My Mood
    Doh
    doesnt matter if its for ps3, eggsbox, wii or pc...code is 99% the same

  4. #4
    SneakyPete's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Location
    In a New World
    Posts
    531
    Reputation
    22
    Thanks
    25
    My Mood
    Happy
    lol wii hate the graphics

    Waiting between worlds that divide through a choice undefined
    A break in the line where all paths intertwine
    And no roads lead or progress behind
    And all signs read: "Know The Way. Decide"



  5. #5
    Jasperdepasper's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Location
    C:\MPGH<3\Jasperdepasper™
    Posts
    234
    Reputation
    17
    Thanks
    150
    My Mood
    Fine
    LOL i got this one for WII If you wanna play modded lobbys on wii pm me
    Jasperdepasper™
    MPGH<3


    Code:
          _                              _                                      
         |M|                            | |                                     
         |P| __ _ ___ _ __   ___ _ __ __| | ___ _ __   __ _ ___ _ __   ___ _ __ 
     _   |G|/ _` / __| '_ \ / _ \ '__/ _` |/ _ \ '_ \ / _` / __| '_ \ / _ \ '__|
    |☺|__|H| (_| \__ \ |_) |  __/ | | (_| |  __/ |_) | (_| \__ \ |_) |  __/ |   
     \MPGH/ \__,_|___/ .__/ \___|_|  \__,_|\___| .__/ \__,_|___/ .__/ \___|_|©  
                     | |                       | |             | |              
                     |_|                       |_|             |_|
    Code:
     __  __ _____   _____ _    _ 
    |Ja\/sp|erdep\ /asper|!|  |!|
    |M\☺☺/M|M|__)☺|L|  __|M|__|M|
    |P|\/|P|P LOL/|O| |!L|P ☺☺ P|
    |G|  |G|G|    |L|__|O|G|  |G|
    |H|  |H|H|     \MPGHL|H|  |H

  6. #6
    Pandemic's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Seattle
    Posts
    3,595
    Reputation
    143
    Thanks
    275
    My Mood
    Angelic
    winning
    duh.

  7. The Following User Says Thank You to Pandemic For This Useful Post:

    willrulz188 (04-17-2011)