Skip to content
Snippets Groups Projects
Select Git revision
  • a00dfcf4205f88cd6149daf73fec4831a7d7c2e5
  • next default protected
  • movie
  • movie-netcode-fixes
  • next-test
  • master protected
  • softcode-info
  • acs
  • clipmidtex
  • custom-map-names
  • nogravity-trampolines
  • 2214-pre4
  • 2214-pre3
  • just-in-case
  • fix-opengl-parameter-crash
  • 2214-pre2
  • 2214-pre1
  • delfile2
  • cleanupmusic
  • gametype-refactor-1
  • extra-textures
  • SRB2_release_2.2.15
  • SRB2_release_2.2.13
  • SRB2_release_2.2.12
  • SRB2_release_2.2.11
  • SRB2_release_2.2.10
  • SRB2_release_2.2.9
  • SRB2_release_2.2.8
  • SRB2_release_2.2.7
  • SRB2_release_2.2.6
  • SRB2_release_2.2.5
  • SRB2_release_2.2.4
  • SRB2_release_2.2.3
  • SRB2_release_2.2.2
  • SRB2_release_2.2.1
  • SRB2_release_2.2.0
  • SRB2_release_2.1.25
  • SRB2_release_2.1.24
  • SRB2_release_2.1.23
  • SRB2_release_2.1.22
  • SRB2_release_2.1.21
41 results

g_game.c

Blame
  • stats.h 2.00 KiB
    // Emacs style mode select   -*- C++ -*-
    //-----------------------------------------------------------------------------
    //
    // Copyright (C) 2000 by DooM Legacy Team.
    //
    // This program is free software; you can redistribute it and/or
    // modify it under the terms of the GNU General Public License
    // as published by the Free Software Foundation; either version 2
    // of the License, or (at your option) any later version.
    //
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    // GNU General Public License for more details.
    //
    //-----------------------------------------------------------------------------
    
    #ifndef _STATS_H_
    #define _STATS_H_
    #ifndef _IPCS_H_
    #error "You forget to include ipcs.h"
    #endif
    #include <time.h>
    
    #define NUMLASTSERVERS 6
    #define SERVERMOTDTEXT "No Clans, advertising websites, Chat, Hangout, Hacked, or Role Playing Servers Allowed"
    
    
    // ================================ DEFINITIONS ===============================
    
    class CServerStats
    {
    	time_t uptime; // master server uptime
    	char motd[2048]; // increase that if not enough
    	msg_server_t last_server[NUMLASTSERVERS]; // keep last 6 named registered servers
    	time_t last_time[NUMLASTSERVERS]; // keep date/time of registration of those servers
    	char version[32]; // master server version
    
    public:
    	int num_connections;
    	int num_http_con;
    	int num_text_con;
    	int num_RSS92_con;
    	int num_RSS10_con;
    	int num_servers;
    	int num_add;
    	int num_removal;
    	int num_retrieval;
    	int num_autoremoval;
    	int num_badconnection;
    
    	CServerStats();
    	~CServerStats();
    	const char *getUptime();
    	int getHours();
    	int getDays();
    	const char *getMotd();
    	const char *getLastServers();
    	const char *getVersion();
    	void putMotd(char *);
    	void putLastServer(msg_server_t *);
    };
    
    // ================================== PROTOS ==================================
    
    // ================================== EXTERNS =================================
    
    #endif