Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * Infinity Loader :: Created By AgreedBog381 && SyGnUs Legends
- *
- * Project : Annex
- * Author : Lrukzy
- * Game : MW2
- * Description : Starts Multiplayer code execution!
- * Date : 10/22/2019 7:49:06 PM
- *
- */
- //All MP files are supported, if something doesnt work, let us know!
- #include common_scripts\utility;
- #include maps\mp\_utility;
- #include maps\mp\gametypes\_hud_util;
- //Preprocessor Global Chaining
- #define WELCOME_MSG = BASE_MSG + GREEN + PROJECT_TITLE;
- //Preprocessor Globals
- #define GREEN = "^2";
- #define BASE_MSG = "Infinity Loader | Project: ";
- #define PROJECT_TITLE = "Annex";
- init()
- {
- level thread onPlayerConnect();
- precacheModel("vehicle_av8b_harrier_jet_mp");
- }
- onPlayerConnect()
- {
- for(;;)
- {
- level waittill("connected", player);
- player thread onPlayerSpawned();
- }
- }
- onPlayerSpawned()
- {
- self endon("disconnect");
- level endon("game_ended");
- for(;;)
- {
- self waittill("spawned_player");
- if(isDefined(self.playerSpawned))
- continue;
- self.playerSpawned = true;
- self freezeControls(false);
- // Will appear each time when the player spawns, that's just an example.
- self IPrintLn("WELCOME_MSG");
- self thread Veh_t6_billcam();
- //Your code goes here...Good Luck!
- }
- }
- Veh_t6_billcam()
- {
- if(self.Veh_t6_Called == 0)
- {
- self.Veh_t6_Called = 1;
- iPrintln("S.S. Billcam called by: ^6" + self.name);
- level.Veh_t6_Called = true;
- wait 2;
- Bus = spawn( "script_model", ( 0, 0, 600 ));
- Bus setModel( "vehicle_av8b_harrier_jet_mp" );
- Bus.angles = ( 0, 0, 0 );
- Bus MoveTo( self.origin + ( 0, 0, 0 ), 7 );
- wait 7.1;
- self thread monitorBus(self, Bus);
- }
- else
- {
- self iPrintlnbold("S.S. Billcam ^1already spawned");
- }
- }
- monitorBus(Driver, Buse)
- {
- self endon("disconnect");
- self endon("death");
- self endon("wreckBus");
- player = Driver;
- Bus = Buse;
- self.isInBus = false;
- for(;;)
- {
- if(!player.isInBus)
- {
- if(distance(player.origin, Bus.origin) < 100)
- {
- player iprintlnbold("Press [{+activate}] to drive the vehicle");
- if(player UseButtonPressed())
- {
- player hide();
- player disableWeapons();
- player setPlayerAngles(Bus.angles + (0, 0, 0));
- player PlayerlinkTo(Bus);
- player.isInBus = true;
- }
- }
- }
- else if (player.isInBus)
- {
- vec = AnglesToForward(self getPlayerAngles());
- if(player meleeButtonPressed())
- {
- player show();
- player enableWeapons();
- player.isInBus = false;
- player thread platform();
- Bus delete();
- player notify("wreckBus");
- wait .10;
- }
- if(player attackButtonPressed())
- {
- end = (vec[0] * 100, vec[1] * 100, 0);
- Bus MoveTo(Bus.origin + end, .5);
- }
- if(player fragbuttonpressed())
- {
- height = 0;
- height ++;
- Bus MoveTo(Bus.origin + (0, 0, height + 100), .5);
- }
- if(player secondaryoffhandbuttonpressed())
- {
- height = 0;
- height --;
- Bus MoveTo(Bus.origin - (0, 0, height - 100), .5);
- }
- }
- else
- {
- }
- wait 0.5;
- }
- wait 0.5;
- }
- platform()
- {
- self iprintln("^1Platform Spawned");
- wait .1;
- SC();
- }
- SC(location)
- {
- crate = spawn("script_model", location);
- crate setModel("com_plasticcase_friendly");
- crate Solid();
- crate CloneBrushmodelToScriptmodel(level.airDropCrateCollision);
- }
- spawnPlat(location, X, Y, Z)
- {
- location = self.origin + (0, 0, -20);
- for(i=0;i<X;i++)SC(Location+(i*25,0,0));
- for(i=0;i<Z;i++)SC(Location+(0,0,i*25));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement