[pMedlem] " [pMember] " - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [pMedlem] " [pMember] " (
/showthread.php?tid=169096)
[pMedlem] " [pMember] " -
cruising - 18.08.2010
Hello!
I cant figure out how to makt this codes to give team members Medlem=0 Medlem=1,Medlem=2,Medlem=3 in player file, i have tried over and over again and now asking for help. Its the last thing before the GM will be usefull for playing.
One of this should be in this codes, i guess it must to be in "/makemember" when you then accept the player as a member by make him a member, but i cant get it to work
Код:
PlayerBase[giveplayerid][pMedlem] = 0;
PlayerBase[playerid][pMedlem] = 0;
Код:
if(strcmp(cmd, "/makemember", true) == 0 || strcmp(cmd, "/mm", true) == 0)
{
if(PlayerBase[playerid][pLedare] != 0)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SCM(playerid, COLOR_GREEN, "Use: /makemember [playerid/name]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
if(PlayerBase[giveplayerid][pMedlem] == 0 && PlayerBase[giveplayerid][pLedare] == 0)
{
if(PlayerBase[giveplayerid][pApply] == PlayerBase[playerid][pLedare])
{
PlayerBase[giveplayerid][pMedlem] = PlayerBase[playerid][pLedare];
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendare, sizeof(sendare));
format(text, sizeof(text), "%s Just Invite You To The Requested Faction!", sendare);
SCM(giveplayerid, COLOR_GREEN, text);
format(text, sizeof(text), "You Just Invited %s!", giveplayer);
SCM(playerid, COLOR_GREEN, text);
PlayerBase[giveplayerid][pApply] = 0;
UpdateRank(playerid);
}
else(SCM(playerid, COLOR_RED, "That Player Hasn't Applied Yet!"));
}
else(SCM(playerid, COLOR_RED, "That Player Is Already In A Faction!"));
}
else(SCM(playerid, COLOR_RED, "That Player Aint Connected...CreateObject"));
}
else(SCM(playerid, COLOR_RED, "You Are Not A Leader!"));
return 1;
}
Re: [pMedlem] " [pMember] " -
Claude - 18.08.2010
pawn Код:
PlayerBase[giveplayerid][pApply] = rank;
Re: [pMedlem] " [pMember] " -
cruising - 18.08.2010
Quote:
Originally Posted by Claude
pawn Код:
PlayerBase[giveplayerid][pApply] = rank;
|
No the command has to add "member=(team ID)" in the player file and not rank, or he wont be a member.
And the command must have this
Код:
PlayerBase[giveplayerid][pMedlem] = 0;
PlayerBase[playerid][pMedlem] = 0;
to set the player to a member of a team in the player file
#EDIT finaly! i got it to work...i hope! it was
Код:
PlayerBase[playerid][pMedlem] = 0;
at just right place and then it works