This wiki is archived and useful information is being migrated to the main bzflag.org website
bz_getReports
From BZFlagWiki
bz_APIStringList* bz_getReports ()
Retrieves reports made by other players in the same format as the /viewreports command does
Returns:
A bz_APIStringList data type containing all the reports available on the server.
Example[edit]
Shows all reports to any administrators that join the game as if they typed /viewreports.
case bz_ePlayerJoinEvent: { if (bz_getAdmin(((bz_PlayerJoinPartEventData_V1*)eventData)->playerID)) { for (int i=0;i<bz_getReports()->size();i++) { bz_sendTextMessagef(BZ_SERVER, ((bz_PlayerJoinPartEventData_V1*)eventData)->playerID,"%s",bz_getReports()->get(i).c_str()); } } }break;