IMG

 
IMG
IMG   IMG
  Welcome to GTAForums! Be sure to check out the Grand Theft Auto V Forum.

You are not registered! (If you are, click here to login) Registering is fast, free and easy and allows you to instantly reply to any topic on GTAForums.
Why wait? Click here to register your own unique username and become part of the ever-growing community!


( Log In | Register | Revalidate Validation E-mail )
Quick Log-In:
  IMG
       
>
Forum Rules GTA Modification Forums

Post mod/code requests in the Mod Requests topic

Post mod releases in the Mod Showroom

Read the Modding Rules BEFORE posting!

GTAGarage.com
free mod hosting from GTANet, simply login with your GTAForums account details

GTAModding.com
GTANet's modding wiki

GTA Modding Chatroom
provided by irc.gtanet.com (Don't have an IRC client? Click here)


  Reply to this topicStart new topicStart Poll

 Police Related Scripts

 
GoldenJoel  
Posted: Monday, Feb 20 2012, 13:01
Quote Post


Hustler
Group Icon
Group: Members
Joined: Dec 29, 2007

XXXXX



Hi guys,

I'm looking for two scripts specifically. One would allow all cops in LC to carry M4s, and the other would be SWAT/Helicopters being called out on 1 Star offenses whether they were by pedestrians or the player.

I'm trying to make LC look like a warzone, and I have all my textures right, but it doesn't make sense for soldiers to fight the civilian riots with only pistols.

Thanks for any help!
PM
  Top
 

 
MonkeyMan_420  
Posted: Thursday, Mar 8 2012, 00:05
Quote Post


Player Hater
Group Icon
Group: BUSTED!
Joined: Mar 7, 2012

XXXXX



sounds cool, any pictures of the textures?

here is a quick solution to enable heli on 1 star, u can just bypass 1 or 2 stars... want a warzone? u will get a warzone

the harder solution is spawning the heli yourself on 1 or 2 stars and re creating all the AI

CODE
using System;
using System.Windows.Forms;
using GTA;

public class PoliceStuff : Script
{
   public PoliceStuff()
   {
       Tick += new EventHandler(PoliceStuff_Tick);
   }
   private void PoliceStuff_Tick(object sender, EventArgs e)
   {
       if (Game.LocalPlayer.WantedLevel == 1 || Game.LocalPlayer.WantedLevel == 2)
       {
           Game.LocalPlayer.WantedLevel = 3;
       }

       Ped[] pedArray = World.GetAllPeds();

       foreach (Ped cop in pedArray)
       {
           if (cop.RelationshipGroup != RelationshipGroup.Cop)
               continue;

           if (cop.Weapons.AssaultRifle_M4.Ammo > 0)
               continue;

           cop.Weapons.RemoveAll();
           cop.Weapons.AssaultRifle_M4.Ammo = 500;
       }
   }
}


just tested and it works, with this no more 1-2 stars and cops armed with M4

This post has been edited by MonkeyMan_420 on Friday, Mar 9 2012, 10:49
PM
  Top
 

 

0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)

0 Members:

Topic Options Reply to this topicStart new topicStart Poll
Search topic for posted by (exact match)



 
IMG IMG