SA-MP Forums Archive
SetPlayerTeam problem - 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: SetPlayerTeam problem (/showthread.php?tid=88520)



SetPlayerTeam problem - Khelif - 27.07.2009

I have been doing little experiment with SetPlayerTeam function. when I enter interior 4, it should set me in team 189, but insted it sets me in team 255. same happens when I leave interior 4. please help
Код:
public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid) {

  if(newinteriorid == 4) {
    new str[64];
    SetPlayerTeam(playerid, 189);
    format(str, sizeof(str), "Current team: %i", GetPlayerTeam(playerid));
    SendClientMessage(playerid,WHITE,str);
    return 1;
  }
  if(newinteriorid == 0) {
    new str[64];
    SetPlayerTeam(playerid, playerid);
    format(str, sizeof(str), "Current team: %i", GetPlayerTeam(playerid));
    SendClientMessage(playerid,WHITE,str);
    return 1;
  }
  return ;
}



Re: SetPlayerTeam problem - Criss_Angel - 27.07.2009

on the second one you did SetPlayerTeam(Playerid,platyerid); Maybe thats why.


Re: SetPlayerTeam problem - Khelif - 27.07.2009

It cannot be because of what you said. please more opinions...



Re: SetPlayerTeam problem - yezizhu - 27.07.2009

Complete bug list