#define HTML_WHO "Who.html" void do_who_html() { FILE *fp; struct descriptor_data *d; struct char_data *tch; int num_can_see=0; fp = fopen( HTML_WHO, "wt" ); if ( !fp ) { log( "Error al abrir archivo Who"); return; } fprintf( fp, "
Jugadores en Azeroth | |
Raza | " ); fprintf( fp, "Jugador | " ); for (d = descriptor_list; d; d = d->next) { if (d->connected) continue; if (d->original) tch = d->original; else if (!(tch = d->character)) continue; if (GET_INVIS_LEV(tch) || IS_AFFECTED(tch, AFF_INVISIBLE) ) continue; num_can_see++; fprintf(fp, "
%2d %s %s | %s %s |
" ); if (num_can_see == 0) fprintf(fp, "Nadie por estas tierras."); else if (num_can_see == 1) fprintf(fp, "Un jugador solito."); else fprintf(fp, "%d personajes visibles.", num_can_see); fprintf( fp, " |