I found (with the help of WebDestroya) that it's possible to block events like player_team which will stop the "X joined team X" in chat, and then re-fire this event for other plugins to use:
Code:
new bool:ptFire = true;
public Action:PlayerTeam_Pre(Handle:event, const String:name[], bool:dontBroadcast)
{
if (ptFire)
{
new Handle:hPlayerTeam = CreateEvent("player_team", true);
SetEventInt(hPlayerTeam, "userid", GetEventInt(event, "userid"));
SetEventInt(hPlayerTeam, "team", GetEventInt(event, "team"));
SetEventInt(hPlayerTeam, "oldteam", GetEventInt(event, "oldteam"));
SetEventBool(hPlayerTeam, "disconnect", GetEventBool(event, "disconnect"));
ptFire = false;
FireEvent(hPlayerTeam, true);
ptFire = true;
return Plugin_Handled;
}
return Plugin_Continue;
}
Have fun
__________________