Team Logins
#1

Ok well I know how to assign players to teams when they select a skin but I want it so that players have to enter a command to be assigned to a team as I only want in my roleplay server certain people being the army but anyone who selects the army skin is assigned to the army.

So I really want something as follows

Command: /nationalguard123
Result: Sets A player skin and gives them weapons

I apologise if this sorta question has already been posted but all I can think to search for is team logins which shows to many results to cipher my way through lol.

I appreciate any help given.
Reply
#2

pawn Код:
if(!strcmp(cmd,"/nationalguard123",true))
{
  if(!TEAM_NGUARD[playerid])
    return SendClientMessage(playerid,color,"You are not a national guard.");
  SetPlayerSkin(playerid,287);
  GivePlayerWeapon(playerid,24,50);
  GivePlayerWeapon(playerid,29,300);
  GivePlayerWeapon(playerid,31,300);
  SetPlayerArmour(playerid,100);
  SetPlayerHealth(playerid,100);
  return 1;
}
Reply
#3

lol nvm i made the same code as menacex
Reply
#4

C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1351) : warning 217: loose indentation
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1353) : warning 217: loose indentation
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1723) : error 029: invalid expression, assumed zero
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1723 -- 1725) : warning 215: expression has no effect
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1725) : error 001: expected token: ";", but found "if"
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1725) : error 029: invalid expression, assumed zero
C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\JRP.pwn(1725) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#5

Post 1723-1725.
Reply
#6

Ok thanks for that used pretty much the same as what was put and it works so cheers. Just trying to get a team radio now via command had 1 working but it was bugged to hell so trying to get a new one but cant find anything
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)