23.08.2016, 21:25
hej i made a system where players can talk to each other in a table
the problem is now that chat doesnt show for players that are in table
even to the hoster
codes
the problem is now that chat doesnt show for players that are in table
even to the hoster
codes
Код:
COMMAND:tt(playerid, params[]) { if(GetPVarInt(playerid,"ontable") == 0) return SendClientMessage(playerid, -1 , "You are not in any table"); new iText[ 128 ]; if(sscanf(params, "s", iText)) return SCP(playerid, "[msg]"); format(iStr, sizeof(iStr),"(( [TABLE] %s: %s ))", RPName(playerid), iText); for(new i, j=GetPlayerPoolSize(); i<j; i++){if(GetPVarInt(i,"ontable") == GetPVarInt(playerid,"ontable")) {SendClientMessage(i, 0x216B98FF, iStr);}} return 1; } COMMAND:jointt(playerid, params[]) { new iPlayer; if(sscanf (params, "d",iPlayer)) return SCP(playerid, "[playerid]"); if(GetPVarInt(iPlayer,"hosting") == 1) { SetPVarInt(playerid, "ontable", GetPVarInt(iPlayer,"ontable")); } return 1; }