Setdisabled Weapons -
gtapolicemods - 07.11.2009
I want to make it so when the Police Enter The Police Building It Doesn't take there weapons away, but when anybody else that is not in the Team_LSPD it does take away all there weapons.
Also How would i define the setdisabledweapons in the script
Re: Setdisabled Weapons -
retart441 - 07.11.2009
Are the teams already Defined?
Re: Setdisabled Weapons -
gtapolicemods - 07.11.2009
yes all the teams are defined. Sorry I meant how to define the setdisabledweapons
Re: Setdisabled Weapons -
retart441 - 07.11.2009
Are you using a /enter for the PD or the yellow arrows?
Re: Setdisabled Weapons -
gtapolicemods - 07.11.2009
no i am using checkpoints
Код:
new supervisor[256];
supervisor=dini_Get("/ERP05/Supervisors.txt","EOC");
SetPlayerVirtualWorld(playerid,2);
SetPlayerInterior(playerid,10);
SetPlayerPos(playerid,246.2444,113.7436,1003.2188);
SetPlayerFacingAngle(playerid,359.0837);
SetCameraBehindPlayer(playerid);
SendClientMessage(playerid,COLOR_YELLOW,"(INFO) Welcome to the Los Santos Police Department headquarters.");
SendClientMessage(playerid,COLOR_GREY,"LSPD East Operations Command.");
//SendClientMessage(playerid,COLOR_GREY,"Current supervisor: None");
format(erpstring, sizeof(erpstring), "Current supervisor: %s",supervisor);
SendClientMessage(playerid, COLOR_GREY, erpstring);
Re: Setdisabled Weapons -
retart441 - 07.11.2009
Just put an if statement, one for police members and one for not police members. Do the exact same thing, but on the one for not police put, ResetPlayerWeapons(playerid);
Re: Setdisabled Weapons -
gtapolicemods - 07.11.2009
sorry could you do an example
Re: Setdisabled Weapons -
retart441 - 07.11.2009
Код:
if(gTeam[playerid] == TEAM_LSPD)
{
Your enter code as it is.
}
else
{
Your enter code as is.
ResetPlayerWeapons(playerid);
Hope this helped.
Re: Setdisabled Weapons -
BP13 - 07.11.2009
1st (lets call this one team cops) So at the top of your script put:
pawn Код:
new bool: COPS[MAX_PLAYERS];
And lets call the other team robbers
pawn Код:
new bool: ROBBERS[MAX_PLAYERS];
When they join the cop team add this to the code:
and when they join robbers:
pawn Код:
ROBBERS[playerid] = true;
now that that stuff is added add this for when they enter the checkpoint:
pawn Код:
if(ROBBERS[playerid] == true)
{
ResetPlayerWeapons(playerid);
}
if(COPS[playerid] == true)
{
new string [128];
new pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, sizeof(pName));
format(string, sizeof(string), "Welcome back to the PD officer %s", pName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
}
That will probably work. Post back and see how it does.
Re: Setdisabled Weapons -
gtapolicemods - 07.11.2009
Thanks I got it problem solved