Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- #define COLOR_ERROR 0xFF0000AA
- #define COLOR_DEATHMESSAGE 0xBB2222AA
- main()
- {
- print("\n----------------------------------");
- print(" minigun maddnes by legodude");
- print("----------------------------------\n");
- }
- new MiniGun[10];
- new Respawned[MAX_PLAYERS];
- forward ResetSpawn(playerid);
- SetupPlayerForClassSelection(playerid)
- {
- SetPlayerVirtualWorld(playerid,1);
- SetPlayerInterior(playerid,playerid);
- SetPlayerPos(playerid,-22.2254,2578.9976,49.1895);
- SetPlayerFacingAngle(playerid,1.4317);
- SetPlayerCameraPos(playerid,-21.9830,2593.8301,55.4564);
- SetPlayerCameraLookAt(playerid,-22.2254,2578.9976,49.1895);
- }
- public OnGameModeInit()
- {
- /*ADDPLAYERCLASSES*/
- AddPlayerClass(0, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(129, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(196, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(199, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(201, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(178, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(238, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(244, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(246, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(87, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(90, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(81, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(23, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(167, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(209, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(155, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(205, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(264, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(134, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(137, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(212, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(230, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(239, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(252, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(77, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(168, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(1, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- AddPlayerClass(2, -22.2254,2578.9976,49.1895,1.4317, 38, 3000, 0, 0, 0, 0);
- // Don't use these lines if it's a filterscript
- SetGameModeText("minigun maddnes");
- CreateObject(8147, 44.897186, 2479.171143, 18.585402, 0.0000, 0.0000, 0.0000);
- CreateObject(8147, -27.853838, 2552.047119, 18.585402, 0.0000, 0.0000, 90.0000);
- CreateObject(8147, -27.469004, 2406.366943, 18.434439, 0.0000, 0.0000, 270.0000);
- CreateObject(8147, -100.330017, 2479.335449, 18.435404, 0.0000, 0.0000, 180.0000);
- CreateObject(2669, -49.867813, 2412.726563, 17.873657, 0.0000, 0.0000, 157.5000);
- CreateObject(2669, -88.005089, 2418.036621, 16.368313, 0.0000, 0.0000, 180.0000);
- CreateObject(2669, -80.170334, 2468.227539, 16.824648, 0.0000, 0.0000, 112.5000);
- CreateObject(2669, -84.865425, 2529.593262, 16.824648, 0.0000, 0.0000, 33.7500);
- CreateObject(2669, -24.934219, 2469.604492, 16.824648, 0.0000, 0.0000, 67.5000);
- CreateObject(2669, -35.067230, 2475.363525, 16.824648, 0.0000, 0.0000, 315.0000);
- CreateObject(2669, -16.942120, 2493.483398, 16.824648, 0.0000, 0.0000, 146.2500);
- CreateObject(2669, -34.050240, 2500.935303, 16.824648, 0.0000, 0.0000, 225.0000);
- CreateObject(2669, 21.234066, 2522.330078, 16.824648, 0.0000, 0.0000, 315.0000);
- CreateObject(2669, 35.616646, 2426.706543, 16.824648, 0.0000, 0.0000, 202.5001);
- CreateObject(3575, -33.394302, 2488.454590, 18.176065, 0.0000, 0.0000, 0.0000);
- CreateObject(3575, -52.436295, 2432.552490, 17.635550, 0.0000, 0.0000, 45.0000);
- CreateObject(3575, -5.527261, 2457.608887, 18.176067, 0.0000, 0.0000, 78.7500);
- CreateObject(3575, 24.982796, 2456.449707, 18.176065, 0.0000, 0.0000, 123.7499);
- CreateObject(3575, 5.904660, 2430.411133, 18.176065, 0.0000, 0.0000, 168.7499);
- CreateObject(3575, 5.858524, 2497.646240, 18.176065, 0.0000, 0.0000, 202.5000);
- CreateObject(3575, 2.523205, 2479.314697, 18.176065, 0.0000, 0.0000, 247.4999);
- CreateObject(3575, 25.350515, 2501.763916, 18.183874, 0.0000, 0.0000, 292.5000);
- CreateObject(3575, -0.895657, 2516.311035, 18.176065, 0.0000, 0.0000, 0.0001);
- CreateObject(3575, -43.464104, 2527.581787, 18.176065, 0.0000, 0.0000, 45.0000);
- CreateObject(3575, -16.163395, 2505.837646, 18.176065, 0.0000, 0.0000, 78.7501);
- CreateObject(3575, -20.636154, 2535.135010, 18.176065, 0.0000, 0.0000, 112.5000);
- CreateObject(3575, -74.209961, 2495.662842, 18.176065, 0.0000, 0.0000, 146.2501);
- CreateObject(3575, -69.387939, 2452.993408, 17.418032, 0.0000, 0.0000, 180.0001);
- CreateObject(7025, -34.727539, 2454.368164, 18.777340, 0.0000, 0.0000, 0.0000);
- CreateObject(7025, -20.372036, 2433.678467, 18.734993, 0.0000, 0.0000, 33.7500);
- CreateObject(7025, 22.961739, 2474.405762, 18.912155, 0.0000, 0.0000, 67.5000);
- CreateObject(7025, 34.211952, 2538.566895, 18.919861, 0.0000, 0.0000, 56.2500);
- CreateObject(7025, 5.163776, 2538.741699, 18.912155, 0.0000, 0.0000, 11.2500);
- CreateObject(7025, -50.218170, 2510.759033, 18.912155, 0.0000, 0.0000, 33.7500);
- CreateObject(7025, -52.741600, 2479.706543, 18.912155, 0.0000, 0.0000, 67.5000);
- CreateObject(3575, -75.641037, 2420.260254, 17.160713, 0.0000, 0.0000, 202.5001);
- CreateObject(3575, -87.805939, 2439.459229, 17.128534, 0.0000, 0.0000, 213.7501);
- CreateObject(3575, -52.838921, 2462.770752, 17.995157, 0.0000, 0.0000, 225.0001);
- CreateObject(3575, -17.271572, 2478.717041, 18.176065, 0.0000, 0.0000, 225.0001);
- CreateObject(3575, -3.899902, 2446.489746, 18.168312, 0.0000, 0.0000, 270.0001);
- CreateObject(3575, -32.568817, 2511.026611, 18.176067, 0.0000, 0.0000, 281.2501);
- CreateObject(3575, -71.213806, 2537.424316, 18.176065, 0.0000, 0.0000, 303.7501);
- CreateObject(7025, -72.968605, 2513.899170, 18.919964, 0.0000, 0.0000, 45.0000);
- CreateObject(7025, -51.610977, 2498.451904, 18.912155, 0.0000, 0.0000, 11.2500);
- CreateObject(7025, -85.836792, 2479.822754, 18.912157, 0.0000, 0.0000, 11.2500);
- CreateObject(7025, -35.021217, 2421.130127, 19.109848, 0.0000, 0.0000, 337.5000);
- CreateObject(7025, -7.170467, 2422.442383, 18.898041, 0.0000, 0.0000, 326.2500);
- CreateObject(7025, 24.780033, 2429.223389, 18.912155, 0.0000, 0.0000, 292.5000);
- CreateObject(7025, -35.254478, 2441.222412, 18.623093, 0.0000, 0.0000, 348.7500);
- CreateObject(7025, -8.789692, 2492.427490, 18.912155, 0.0000, 0.0000, 247.5000);
- CreateObject(3575, 15.312395, 2510.631592, 18.176065, 0.0000, 0.0000, 292.5000);
- CreateObject(14553, 75.982727, 2502.419434, 15.969280, 22.3454, 357.4217, 97.7349);//vliegtuig
- CreateObject(2780, 63.701988, 2494.566162, 15.484375, 0.0000, 0.0000, 0.0000);//smokemachines
- CreateObject(2780, 79.460953, 2497.642822, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 75.917831, 2496.808350, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 73.102303, 2510.412598, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 84.717972, 2512.329102, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 97.649323, 2510.941162, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 111.872345, 2509.893066, 15.510204, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 100.208839, 2508.476563, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 103.969795, 2509.019287, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 108.672318, 2502.731934, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 93.549515, 2498.805176, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 83.382881, 2497.754639, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 75.981537, 2499.653076, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 72.947968, 2496.647949, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 67.225632, 2497.041016, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 54.162510, 2500.242188, 15.484375, 0.0000, 0.0000, 0.0000);
- CreateObject(2780, 55.870213, 2496.486816, 15.484375, 0.0000, 0.0000, 0.0000);//tot hier
- CreateObject(7025, -59.270348, 2528.258301, 18.912155, 0.0000, 0.0000, 78.7500);
- MiniGun[1] = CreatePickup(362, 22, -49.2231,2413.7119,18.1405, -1);
- MiniGun[2] = CreatePickup(362, 22, -88.1400,2418.7083,16.1507, -1);
- MiniGun[3] = CreatePickup(362, 22, -80.2826,2468.0244,16.6070, -1);
- MiniGun[4] = CreatePickup(362, 22, -35.4149,2474.6997,16.6070, -1);
- MiniGun[5] = CreatePickup(362, 22, -24.4378,2469.4041,16.6070, -1);
- MiniGun[6] = CreatePickup(362, 22, -32.3504,2499.9739,16.6070, -1);
- MiniGun[7] = CreatePickup(362, 22, -85.0998,2529.8872,16.6070, -1);
- MiniGun[8] = CreatePickup(362, 22, 22.0355,2522.2053,16.6070, -1);
- MiniGun[9] = CreatePickup(362, 22, 35.6325,2426.7192,16.6070, -1);
- return 1;
- }
- public OnPlayerConnect(playerid)
- {
- SetupPlayerForClassSelection(playerid);
- return 1;
- }
- public OnPlayerRequestSpawn(playerid)
- {
- SetupPlayerForClassSelection(playerid);
- return 1;
- }
- public OnGameModeExit()
- {
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- SendDeathMessage(killerid,playerid,reason);
- new name[MAX_PLAYER_NAME],kname[MAX_PLAYER_NAME], string[128];
- GetPlayerName(killerid, kname, sizeof(kname));
- GetPlayerName(playerid, name, sizeof(name));
- if(killerid==INVALID_PLAYER_ID)
- {
- format(string, sizeof(string), "%s did suicide. his score will be reduced by 1",name);
- SendClientMessageToAll(COLOR_DEATHMESSAGE, string);
- if(playerid != INVALID_PLAYER_ID) SetPlayerScore(playerid, GetPlayerScore(killerid) - 1);
- }
- else if(playerid!=killerid)
- {
- format(string, sizeof(string), "%s has killed %s, %s will be awarded 1 score",kname, name, kname);
- SendClientMessageToAll(COLOR_DEATHMESSAGE, string);
- if(killerid != INVALID_PLAYER_ID){ SetPlayerScore(killerid, GetPlayerScore(killerid) + 1);}
- }
- return 1;
- }
- public OnPlayerSpawn(playerid)
- {
- SetPlayerArmour(playerid, 100.0);
- {
- switch(random(6))
- {
- case 0:
- {
- SetPlayerPos(playerid,-89.6592,2440.7383,15.4210);
- }
- case 1:
- {
- SetPlayerPos(playerid,22.6497,2502.9558,16.4922);
- }
- case 2:
- {
- SetPlayerPos(playerid,32.0872,2540.2114,16.4921);
- }
- case 3:
- {
- SetPlayerPos(playerid,-60.4238,2528.0222,16.4844);
- }
- case 4:
- {
- SetPlayerPos(playerid,-85.6545,2477.9131,16.4844);
- }
- case 5:
- {
- SetPlayerPos(playerid,-7.7515,2422.1787,16.4627);
- }
- }
- }
- return 1;
- }
- public OnPlayerCommandText(playerid, cmdtext[])
- {
- if (strcmp("/respawn", cmdtext, true, 10) == 0)
- {
- if(Respawned[playerid]==0)
- {
- Respawned[playerid] = 1;
- SetTimerEx("ResetSpawn",15000,false,"u",playerid);
- SetPlayerArmour(playerid, 100.0);
- SetPlayerHealth(playerid, 100.0);
- SetPlayerAmmo(playerid,7,3000);
- switch(random(6))
- {
- case 0:
- {
- SetPlayerPos(playerid,-89.6592,2440.7383,15.4210);
- }
- case 1:
- {
- SetPlayerPos(playerid,22.6497,2502.9558,16.4922);
- }
- case 2:
- {
- SetPlayerPos(playerid,32.0872,2540.2114,16.4921);
- }
- case 3:
- {
- SetPlayerPos(playerid,-60.4238,2528.0222,16.4844);
- }
- case 4:
- {
- SetPlayerPos(playerid,-85.6545,2477.9131,16.4844);
- }
- case 5:
- {
- SetPlayerPos(playerid,-7.7515,2422.1787,16.4627);
- }
- }
- }
- else
- {
- SendClientMessage(playerid,COLOR_ERROR,"you have respawned already, wait a few seconds before doing it again");
- }
- }
- return 1;
- }
- public OnPlayerPickUpPickup(playerid, pickupid)
- {
- if(pickupid == MiniGun[1]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[2]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[3]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[4]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[5]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[6]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[7]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[8]) GivePlayerWeapon(playerid,38,500);
- if(pickupid == MiniGun[9]) GivePlayerWeapon(playerid,38,500);
- return 1;
- }
- public ResetSpawn(playerid)
- {
- Respawned[playerid] = 0;
- return 1;
- }
Add Comment
Please, Sign In to add comment