Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Drawing;
- using System.Windows.Forms;
- using GTA;
- using GTA.Math;
- using GTA.Native;
- using NativeUI;
- using System.Linq;
- public class MenuExample : Script
- {
- private MenuPool _menuPool; private string addon_name = "";private bool isAddons = false; private int limiteGuardac = 7; private Player player = Game.Player; List<Ped> peds = new List<Ped>(); float bla = 0.00f; int blas = 10; private bool dSpeed = false; private Ped playerPed = Game.Player.Character; private Ped ped; double cnt = 0; bool marker = true; bool mSet = false; double cntMax = 1000000000; double cnt_d = 1000000000 / 22; double cnt_d2 = 1000000000 / 24; List<string> names = new List<string>(); float x = 1f, y = 1f, z = 1f; PedHash hash; bool UsingGamepad = Function.Call<bool>(Hash._GET_LAST_INPUT_METHOD); bool superJump = false, isAuto = false, bodyguardOn = false; int driveTipe = 6, indax; float autoSpeed = 25; string carnome; Vector3 v1 = new Vector3(25.8693f, 540.4783f, 175f); private bool checkbox = false; Vector3 v2 = new Vector3(29.0000f, 538.6783f, 175f); Vector3 v3 = new Vector3(47.8523f, -1912.992f, 20.8000f);
- private Model characterModel;
- void spawnPed(PedHash hashi,bool isAddon,string addonName)
- {
- if (isAddon == true)
- {
- peds.Add(World.CreatePed(addonName, playerPed.GetOffsetInWorldCoords(new Vector3(0, 5, 0))));
- }
- else
- {
- peds.Add(World.CreatePed(hashi, playerPed.GetOffsetInWorldCoords(new Vector3(0, 5, 0))));
- }
- int player_group = Function.Call<int>(Hash.GET_PLAYER_GROUP, player.Handle);
- Function.Call(Hash.SET_PED_AS_GROUP_LEADER, playerPed, player_group);
- Wait(100);
- var pedx = peds.Last();
- Function.Call(Hash.SET_PED_AS_GROUP_MEMBER, pedx.Handle, player_group);
- pedx.RelationshipGroup = playerPed.RelationshipGroup;
- pedx.AddBlip();
- pedx.CanBeTargetted = true;
- pedx.Weapons.Give(WeaponHash.AssaultRifle, 99999, true, true);
- pedx.Weapons.Give(WeaponHash.APPistol, 99999, true, true);
- pedx.Accuracy = 100;
- pedx.IsInvincible = true;
- //pedx.Task.FightAgainstHatedTargets(50000);
- pedx.AlwaysKeepTask = false;
- pedx.StaysInVehicleWhenJacked = false;
- pedx.StaysInVehicleWhenJacked = false;
- pedx.CanBeDraggedOutOfVehicle = false;
- pedx.Armor = 100;
- pedx.IsPersistent = true;
- Function.Call(Hash.SET_PED_INFINITE_AMMO, pedx, true, "" + WeaponHash.AssaultRifle);
- Function.Call(Hash.SET_PED_INFINITE_AMMO, pedx, true, "" + WeaponHash.APPistol);
- Function.Call(Hash.SET_PED_INFINITE_AMMO_CLIP, pedx, true);
- pedx.CurrentBlip.Color = BlipColor.Blue;
- pedx.CurrentBlip.Name = "Meu Tropa " + peds.IndexOf(peds.Last());
- bodyguardOn = true;
- Wait(50);
- }
- void spawnCar(string Carname)
- {
- try
- {
- if (playerPed.IsInVehicle())
- {
- float speed = playerPed.CurrentVehicle.Speed; Game.Player.Character.CurrentVehicle.Delete(); Vehicle vehBanshee = World.CreateVehicle(Carname, playerPed.Position, playerPed.Heading + 10); playerPed.Task.WarpIntoVehicle(vehBanshee, VehicleSeat.Driver); if (vehBanshee.IsAlive)
- {
- carnome = vehBanshee.DisplayName; vehBanshee.EngineRunning = true; vehBanshee.NumberPlate = "MaC 2745"; if (bodyguardOn == true) { ped.Task.WarpIntoVehicle(vehBanshee, VehicleSeat.Any); }
- vehBanshee.Speed = speed; vehBanshee.CanWheelsBreak = false; vehBanshee.CanTiresBurst = false; vehBanshee.IsBulletProof = true; vehBanshee.IsPersistent = true; vehBanshee.IsStolen = false; vehBanshee.PlaceOnGround(); vehBanshee.ToggleMod(VehicleToggleMod.Turbo, true); vehBanshee.ToggleMod(VehicleToggleMod.TireSmoke, true); vehBanshee.ToggleMod(VehicleToggleMod.XenonHeadlights, true); vehBanshee.InstallModKit(); vehBanshee.SetMod(VehicleMod.Engine, 3, true); vehBanshee.SetMod(VehicleMod.Suspension, 3, true); vehBanshee.SetMod(VehicleMod.Transmission, 2, true); vehBanshee.SetMod(VehicleMod.Brakes, 2, true); vehBanshee.SetMod(VehicleMod.Armor, 4, true); vehBanshee.Repair(); vehBanshee.Wash(); UI.Notify("~g~Código Activado: \n~w~O seu veículo " + carnome + " foi entregue!");
- }
- }
- else
- {
- Vehicle vehBanshee = World.CreateVehicle(Carname, playerPed.Position, playerPed.Heading + 10); playerPed.Task.WarpIntoVehicle(vehBanshee, VehicleSeat.Driver); if (vehBanshee.IsAlive)
- {
- vehBanshee.NumberPlate = "MaC 2745"; vehBanshee.EngineRunning = true; carnome = vehBanshee.DisplayName; if (bodyguardOn == true) { ped.Task.WarpIntoVehicle(vehBanshee, VehicleSeat.Any); }
- vehBanshee.CanWheelsBreak = false; vehBanshee.CanTiresBurst = false; vehBanshee.IsBulletProof = true; vehBanshee.IsPersistent = true; vehBanshee.IsStolen = false; vehBanshee.PlaceOnGround(); vehBanshee.ToggleMod(VehicleToggleMod.Turbo, true); vehBanshee.ToggleMod(VehicleToggleMod.TireSmoke, true); vehBanshee.ToggleMod(VehicleToggleMod.XenonHeadlights, true); vehBanshee.InstallModKit(); vehBanshee.SetMod(VehicleMod.Engine, 3, true); vehBanshee.SetMod(VehicleMod.Suspension, 3, true); vehBanshee.SetMod(VehicleMod.Transmission, 2, true); vehBanshee.SetMod(VehicleMod.Brakes, 2, true); vehBanshee.SetMod(VehicleMod.Armor, 4, true); vehBanshee.Repair(); vehBanshee.Wash(); UI.Notify("~g~Código Activado: \n~w~O seu veículo " + carnome + " foi entregue!");
- }
- }
- }
- catch
- { UI.Notify("~r~ERROR: \n~w~Não foi possivel ler as HASH's de Veiculos!"); }
- }
- // This is where Menu1 is created
- public void Menu1(UIMenu menu)
- {
- var newbutton1 = new UIMenuItem("Banshee", "Spawn vehicle next to you."); var newbutton2 = new UIMenuItem("Futo", "Spawn vehicle next to you."); var newbutton3 = new UIMenuItem("Honda Civic 8Th", "Spawn vehicle next to you."); var newbutton4 = new UIMenuItem("Mitsubishi Eclipse", "Spawn vehicle next to you."); var newbutton5 = new UIMenuItem("Teleport to Waypoint", "Teleport to Waypoint location."); var newbutton6 = new UIMenuItem("Golf GTI MK4", "Spawn vehicle next to you."); var newbutton7 = new UIMenuItem("Auto-Drive to Waypoint", "Auto-drive to waypoint location."); var newbutton8 = new UIMenuItem("Kit'ar Carro MAX", "(Sem visuais / Só Motor,Turbo, Suspensão, Travões, Blindagem...)"); var newbutton9 = new UIMenuItem("Feltzer", "Spawn vehicle next to you."); var newbutton10 = new UIMenuItem("Manchez (Mota)", "Spawn vehicle next to you."); var newbutton11 = new UIMenuItem("Mazda Mx5 StanceCamber", "Spawn vehicle next to you."); var newbutton12 = new UIMenuItem("Pedir Guarda-Costas", "Faça aparecer um guarda-costas para si.(Máximo = 1)"); var newbutton13 = new UIMenuItem("Apagar Guarda-Costas", "Elimine o seu guarda-costas atual."); var newbutton14 = new UIMenuItem("BMW (Sentinel)", "Spawn vehicle next to you."); var newbutton15 = new UIMenuItem("Honda Type-R (Praire)", "Spawn vehicle next to you."); var newbutton16 = new UIMenuItem("Honda Civic SI'99", "w/ Tunning Mods"); var newbutton17 = new UIMenuItem("4x4 Street Blazer (Mota)", "w/ Tunning Mods"); var newbutton18 = new UIMenuItem("x80 PROTO", "w/ Tunning Mods"); var newbutton19 = new UIMenuItem("Subaru Impreza WRX", "w/ Tunning Mods"); var newbutton20 = new UIMenuItem("Honda S2000", "w/ Tunning Mods"); var newbutton21 = new UIMenuItem("Toyota Supra", "w/ Tunning Mods"); var newbutton22 = new UIMenuItem("Peugeot 206", "w/ Tunning Mods"); var newbutton23 = new UIMenuItem("Futo 2", "w/ Tunning Mods"); var newbutton24 = new UIMenuItem("BMW M3 E36", "w/ Tunning Mods"); var newbutton25 = new UIMenuItem("BMW E36 RB", "w/ Tunning Mods"); var newbutton26 = new UIMenuItem("Mercedes C63 AMG S", "w/ Tunning Mods"); var newbutton27 = new UIMenuItem("Golf V GTI", "w/ Tunning Mods"); var newbutton28 = new UIMenuItem("Nova 1996", "w/ Tunning Mods"); var newbutton29 = new UIMenuItem("Missões", "Clique em 'Installed Missions' e escolha uma missão.");
- List<dynamic> listas = new List<dynamic> {
- "Super-Homem",
- "Eminem",
- "Michael Scofield",
- "2Pac",
- "Hitman Agente 47",
- "Will Smith MIB",
- "John Wick",
- "Mai Shiranui",
- "James Bond 007",
- "Gang(Families) Female",
- "Gang(Families) Male 1",
- "Gang(Families) Male 2",
- "Gang(Families) Old Male",
- "Gang(Prisioner) Male",
- "Policia Female",
- "Barman Male",
- "Puta Female",
- "DrugDealer Male",
- "Exército Male",
- "Exército Male 2",
- "Agente FBI Male",
- "Puta Topless Female",
- "Macaco Assassino"
- };
- List<dynamic> modoDrive = new List<dynamic>
- {
- "Evitar Transito",
- "Normal",
- "Agressivo"
- };
- List<dynamic> limiteGuardas = new List<dynamic>
- {
- "1",
- "2",
- "3",
- "4",
- "5",
- "6",
- "7",
- "8",
- "Ilimitado (100)"
- };
- var lista = new UIMenuListItem("Escolher:", listas, 0);
- var listaDrive = new UIMenuListItem("AutoDrive:", modoDrive, 0);
- var sub1 = _menuPool.AddSubMenu(menu, "Spawn Carros");
- menu.AddItem(newbutton8);
- var sub2 = _menuPool.AddSubMenu(menu, "Player");
- var sub4 = _menuPool.AddSubMenu(menu, "Guarda-Costas");
- menu.AddItem(newbutton29);
- List<dynamic> listofweapons = new List<dynamic>();
- WeaponHash[] allweaponhashes = (WeaponHash[])Enum.GetValues(typeof(WeaponHash));
- for (int i = 0; i < allweaponhashes.Length; i++)
- {
- listofweapons.Add(allweaponhashes[i]);
- }
- UIMenuListItem list = new UIMenuListItem("Armas:", listofweapons, 9);
- //Submenu Carros
- sub1.AddItem(newbutton16); sub1.AddItem(newbutton4); sub1.AddItem(newbutton14); sub1.AddItem(newbutton1); sub1.AddItem(newbutton2); sub1.AddItem(newbutton3); sub1.AddItem(newbutton6); sub1.AddItem(newbutton9); sub1.AddItem(newbutton10); sub1.AddItem(newbutton17); sub1.AddItem(newbutton11); sub1.AddItem(newbutton18); sub1.AddItem(newbutton15); sub1.AddItem(newbutton19); sub1.AddItem(newbutton20); sub1.AddItem(newbutton21); sub1.AddItem(newbutton22); sub1.AddItem(newbutton23); sub1.AddItem(newbutton24); sub1.AddItem(newbutton25); sub1.AddItem(newbutton26); sub1.AddItem(newbutton27); sub1.AddItem(newbutton28);
- sub1.OnItemSelect += (sender, item, index) => {
- try
- {
- String it = item.ToString();
- String nb4 = newbutton4.ToString();
- if (item == newbutton4) { spawnCar("" + VehicleHash.Ninef2); }
- if (item == newbutton1) { spawnCar("" + VehicleHash.Banshee); }
- if (item == newbutton2) { spawnCar("FUTO"); }
- if (item == newbutton3) { spawnCar("CIVIC8TH"); }
- if (item == newbutton6) { spawnCar("SULTANRS"); }
- if (item == newbutton9) { spawnCar("" + VehicleHash.Feltzer2); }
- if (item == newbutton10) { spawnCar("Manchez"); }
- if (item == newbutton11) { spawnCar("mx5stance"); }
- if (item == newbutton14) { spawnCar("sentinel"); }
- if (item == newbutton15) { spawnCar("praire"); }
- if (item == newbutton16) { spawnCar("civic"); }
- if (item == newbutton17) { spawnCar("blazer4"); }
- if (item == newbutton18) { spawnCar("prototipo"); }
- if (item == newbutton19) { spawnCar("subwrx"); }
- if (item == newbutton20) { spawnCar("ap2"); }
- if (item == newbutton21) { spawnCar("supra2"); }
- if (item == newbutton22) { spawnCar("206"); }
- if (item == newbutton23) { spawnCar("futo2"); }
- if (item == newbutton24) { spawnCar("rmodm3e36"); }
- if (item == newbutton25) { spawnCar("e36rb"); }
- if (item == newbutton26) { spawnCar("c63w205"); }
- if (item == newbutton27) { spawnCar("golfgti"); }
- if (item == newbutton28) { spawnCar("nova"); }
- }
- catch
- {
- UI.Notify("~r~ERROR: \n~w~ HASH do veiculo nao Existe!");
- }
- };
- //Submenu Player
- sub2.AddItem(newbutton5);
- sub2.AddItem(listaDrive);
- sub2.OnItemSelect += (sender, item, index) => {
- if (item == listaDrive)
- {
- int listaIndex = listaDrive.Index; if (listaIndex == 0)
- { driveTipe = 6; }
- if (listaIndex == 1)
- { driveTipe = 786603; }
- if (listaIndex == 2)
- { driveTipe = 1074528293; }
- if (playerPed.IsInVehicle() && isAuto == false && Game.IsWaypointActive == true)
- { playerPed.Task.DriveTo(playerPed.CurrentVehicle, World.GetWaypointPosition(), 500, autoSpeed, driveTipe); isAuto = true; }
- else
- { isAuto = false; UI.Notify("~r~ERROR: \n~w~Não está num veiculo ou nao tem um waypoint definido!"); }
- }
- if (item == newbutton5)
- { playerPed.PositionNoOffset = World.GetWaypointPosition(); Wait(500); }
- };
- menu.OnItemSelect += (sender, item, index) =>
- {
- if(item==newbutton29)
- {
- try
- {
- SendKeys.SendWait("H");
- menu.Visible = !menu.Visible;
- }
- catch { UI.Notify("ERRO! H"); }
- }
- };
- var chk = new UIMenuCheckboxItem("SuperJump", checkbox, "Activate Super Jump!");
- sub2.AddItem(chk);
- var chk2 = new UIMenuCheckboxItem("SuperRun", checkbox, "Activate Super Run!");
- sub2.AddItem(chk2);
- //menu guarda-costas
- sub4.AddItem(lista);
- sub4.AddItem(newbutton13);
- sub4.OnItemSelect += (sender, item, index) => {
- if (item == lista) // If statement
- {
- if (peds.Count < limiteGuardac)
- {
- try
- {
- int listIndex = lista.Index; switch (listIndex)
- {
- case 0:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "superman";
- break;
- case 1:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "eminem";
- break;
- case 2:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "prisoner";
- break;
- case 3:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "2pac";
- break;
- case 4:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "chauve";
- break;
- case 5:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "WillSmith";
- break;
- case 6:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "wick";
- break;
- case 7:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "MaiCasual";
- break;
- case 8:
- hash = 0;
- indax = 0;
- isAddons = true;
- addon_name = "James Bond DC";
- break;
- case 9:
- hash = PedHash.Families01GFY;
- indax = 0;
- isAddons = false;
- break;
- case 10:
- hash = PedHash.Famca01GMY;
- indax = 0;
- isAddons = false;
- break;
- case 11:
- hash = PedHash.Famdnf01GMY;
- indax = 0;
- isAddons = false;
- break;
- case 12:
- hash = PedHash.AfriAmer01AMM;
- indax = 0;
- isAddons = false;
- break;
- case 13:
- hash = PedHash.PrisMuscl01SMY;
- indax = 0;
- isAddons = false;
- break;
- case 14:
- hash = PedHash.Cop01SFY;
- indax = 0;
- isAddons = false;
- break;
- case 15:
- hash = PedHash.Barman01SMY;
- indax = 0;
- isAddons = false;
- break;
- case 16:
- hash = PedHash.Juggalo01AFY;
- isAddons = false;
- indax = 0;
- break;
- case 17:
- hash = PedHash.Dealer01SMY;
- indax = 0;
- isAddons = false;
- break;
- case 18:
- hash = PedHash.Marine01SMY;
- indax = 0;
- isAddons = false;
- break;
- case 19:
- hash = PedHash.Marine03SMY;
- indax = 0;
- isAddons = false;
- break;
- case 20:
- hash = PedHash.FbiSuit01;
- indax = 0;
- isAddons = false;
- break;
- case 21:
- hash = PedHash.Topless01AFY;
- indax = 0;
- isAddons = false;
- break;
- case 22:
- hash = PedHash.Pogo01;
- indax = 0;
- isAddons = false;
- break;
- }
- spawnPed(hash,isAddons,addon_name);
- }
- catch
- { UI.Notify("~r~ERROR: \n~w~Não foi possivel ler as HASH's dos Peds!"); }
- }
- else
- {
- UI.Notify("~r~ERROR: \n~w~Atingiu o limite de Guarda-Costas!");
- }
- }
- if (item == newbutton13 && bodyguardOn == true) // If statement
- {
- try
- {
- peds.Last().Delete(); peds.Remove(peds.Last());
- if (!peds.Any()){bodyguardOn = false; }
- }
- catch { UI.Notify("~r~ERROR: \n~w~Não foi possivel Eliminar o seu Guarda-Costas!"); }
- }
- };
- //Main Menu Clickable Items
- menu.AddItem(list);
- menu.OnItemSelect += (sender, item, index) => {
- if (item == newbutton8)
- {
- try
- {
- Vehicle car = playerPed.CurrentVehicle; car.NumberPlate = "MaC 2745"; car.CanWheelsBreak = false; car.CanTiresBurst = false; car.IsBulletProof = true; car.IsPersistent = true; car.IsStolen = false; car.ToggleMod(VehicleToggleMod.Turbo, true); car.ToggleMod(VehicleToggleMod.TireSmoke, true); car.ToggleMod(VehicleToggleMod.XenonHeadlights, true); car.InstallModKit(); car.SetMod(VehicleMod.Engine, 3, true); car.SetMod(VehicleMod.Suspension, 3, true); car.SetMod(VehicleMod.Transmission, 2, true); car.SetMod(VehicleMod.Brakes, 2, true); car.SetMod(VehicleMod.Armor, 4, true); car.Repair(); car.Wash();
- UI.Notify("~g~Código Activado: \n~w~Carro Kitado e Reparado!");
- }
- catch { UI.Notify("~r~ERROR: \n~w~Não foi possivel Kitar o seu carro!"); }
- // Wait(200);
- }
- if (item == list)
- {
- int listIndex = list.Index;
- WeaponHash currentHash = allweaponhashes[listIndex];
- playerPed.Weapons.Give(currentHash, 9999, true, true);
- }
- };
- sub2.OnCheckboxChange += (sender, item, checked_) => {
- if (item == chk) // If statement
- {
- if (checked_ == true)
- {
- superJump = true;
- UI.Notify("~g~Código Activado: \n~w~Super Jump");
- }
- else if (checked_ == false)
- {
- superJump = false;
- UI.Notify("~r~Código Desactivado: \n~w~Super Jump");
- }
- }
- if (item == chk2) // If statement
- {
- if (checked_ == true)
- {
- player.SetRunSpeedMultThisFrame(1.49f);
- UI.Notify("~g~Código Activado: \n~w~Super Run");
- }
- else if (checked_ == false)
- {
- dSpeed = false;
- bla++;
- player.SetRunSpeedMultThisFrame(bla);
- bla--;
- player.SetRunSpeedMultThisFrame(bla);
- UI.ShowSubtitle("PlayerMaxSpeed: " + bla);
- UI.Notify("~r~Código Desactivado: \n~w~Super Run");
- }
- }
- };
- }
- void toolTip(string text)
- {
- Function.Call(Hash._SET_TEXT_COMPONENT_FORMAT, "STRING");
- Function.Call(Hash._ADD_TEXT_COMPONENT_STRING, text);
- Function.Call(Hash._0x238FFE5C7B0498A6, 0, 0, 1, -1);
- }
- public MenuExample()
- {
- _menuPool = new MenuPool();
- var mainMenu = new UIMenu("~g~NinjaRoot's Menu", "~b~Escolha Uma Opção...");
- Menu1(mainMenu);
- _menuPool.Add(mainMenu);
- _menuPool.RefreshIndex();
- Tick += (o, e) =>
- {
- _menuPool.ProcessMenus(); if (playerPed.IsGettingIntoAVehicle) { toolTip("Pressione ~INPUT_SPECIAL_ABILITY_SECONDARY~ para usar o Nitro."); }
- if (cnt >= cntMax) { cnt = 0; }
- if (cnt <= cnt_d) { marker = false; } else { marker = true; }
- if (playerPed.IsAlive && playerPed.IsVisible && playerPed.Health <= 100 && playerPed.Health >= 25)
- { cnt += cnt_d2; if (marker == false) { playerPed.Health = playerPed.Health + 1; } }
- if (superJump) { player.SetSuperJumpThisFrame(); }
- if (playerPed.IsInVehicle() == false) { isAuto = false; autoSpeed = 20; }
- if (Game.CurrentInputMode == InputMode.GamePad)
- {
- if ((Game.IsControlPressed(2, GTA.Control.Aim)) && Game.IsControlPressed(2, GTA.Control.FrontendRs))
- {
- Vector3 camPos = Function.Call<Vector3>(Hash.GET_GAMEPLAY_CAM_COORD);
- Vector3 camRot = Function.Call<Vector3>(Hash.GET_GAMEPLAY_CAM_ROT);
- float retz = camRot.Z * 0.0174532924F;
- float retx = camRot.X * 0.0174532924F;
- float absx = (float)Math.Abs(Math.Cos(retx));
- Vector3 camStuff = new Vector3((float)Math.Sin(retz) * absx * -1, (float)Math.Cos(retz) * absx, (float)Math.Sin(retx));
- RaycastResult ray = World.Raycast(camPos, camPos + camStuff * 1000, IntersectOptions.Everything);
- World.AddOwnedExplosion(playerPed,ray.HitCoords, ExplosionType.PlaneRocket, 0.5f, 0f);
- }
- if (Game.IsControlPressed(2, GTA.Control.FrontendRb) && Game.IsControlPressed(2, GTA.Control.FrontendRdown))
- { mainMenu.Visible = !mainMenu.Visible; Wait(200); }
- if (Game.IsControlPressed(2, GTA.Control.FrontendY) && isAuto == true )
- {
- playerPed.Task.ClearAllImmediately();
- isAuto = false; UI.Notify("~r~ERROR: \n~w~Viagem cancelada por saída de veiculo, perdeu ~g~10$"); playerPed.Money = playerPed.Money - 10; Wait(200);
- }
- if (bodyguardOn == true && (Game.IsControlPressed(2, GTA.Control.Aim)) && (Game.IsControlPressed(2, GTA.Control.FrontendAccept)))
- {
- UI.Notify("~g~BodyGuard Task: ~w~Atacar o Alvo!");
- try
- {
- Entity target = player.GetTargetedEntity();
- foreach (Ped pedx in peds)
- {
- pedx.Task.ClearAll();
- Function.Call(Hash.TASK_SHOOT_AT_ENTITY, pedx, target, 5000, FiringPattern.FullAuto.GetHashCode());
- Wait(1);
- }
- }
- catch
- { UI.Notify("~r~ERROR: \n~w~Não foi possivel Executar o ataque de mira"); }
- Wait(4800);
- }
- if (mainMenu.Visible == false)
- {
- if (Game.IsControlPressed(2, GTA.Control.FrontendLt) && Game.IsControlPressed(2, GTA.Control.PhoneRight))
- { UI.Notify("~g~Código Activado: \n~w~Remover Policia"); player.WantedLevel = 0; Wait(200); }
- if (Game.IsControlPressed(2, GTA.Control.PhoneRight) && playerPed.IsInVehicle() == true)
- { UI.Notify("~g~Código Activado: \n~w~Veiculo Arranjado"); playerPed.CurrentVehicle.Repair(); playerPed.CurrentVehicle.Wash(); Wait(200); }
- }
- }
- };
- KeyDown += (o, e) =>
- {
- if (e.KeyCode == Keys.Z && !_menuPool.IsAnyMenuOpen())
- {
- mainMenu.Visible = !mainMenu.Visible; Wait(200);
- }
- };
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement