More tweekable.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1569 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2005-11-14 01:32:21 +00:00
parent 6b8551e8b9
commit 35192beb47
9 changed files with 24 additions and 22 deletions

View File

@ -901,7 +901,7 @@ void CL_Disconnect (void)
Cvar_ApplyLatches(CVAR_SERVEROVERRIDE);
if (VID_SetWindowCaption)
VID_SetWindowCaption("FTE QuakeWorld: disconnected");
VID_SetWindowCaption(FULLENGINENAME": disconnected");
// stop sounds (especially looping!)
S_StopAllSounds (true);

View File

@ -869,7 +869,7 @@ qboolean Sys_InitTerminal (void)
if (!AllocConsole())
return false;
SetConsoleCtrlHandler (HandlerRoutine, TRUE);
SetConsoleTitle ("FTE dedicated server");
SetConsoleTitle (FULLENGINENAME, " dedicated server");
hinput = GetStdHandle (STD_INPUT_HANDLE);
houtput = GetStdHandle (STD_OUTPUT_HANDLE);

View File

@ -241,10 +241,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
//#define VERSION 2.56
#define DISTRIBUTION "FTE"
#define DISTRIBUTIONLONG "Forethought Entertainment"
#define ENGINEWEBSITE "http://fteqw.sourceforge.net/"
#ifndef DISTRIBUTION
#define DISTRIBUTION "FTE"
#define DISTRIBUTIONLONG "Forethought Entertainment"
#define FULLENGINENAME "FTE QuakeWorld"
#define ENGINEWEBSITE "http://fteqw.sourceforge.net/"
#endif
#ifndef PLATFORM
#if defined(_WIN32)

View File

@ -353,7 +353,7 @@ qboolean VID_SetWindowedMode (rendererstate_t *info)
dibwindow = CreateWindowEx (
ExWindowStyle,
WINDOW_CLASS_NAME,
"FTE QuakeWorld",
FULLENGINENAME,
WindowStyle,
rect.left, rect.top,
wwidth,
@ -478,7 +478,7 @@ qboolean VID_SetFullDIBMode (rendererstate_t *info)
dibwindow = CreateWindowEx (
ExWindowStyle,
WINDOW_CLASS_NAME,
"FTE QuakeWorld",
FULLENGINENAME,
WindowStyle,
rect.left, rect.top,
wwidth,

View File

@ -521,7 +521,7 @@ qboolean HTTP_CL_Get(char *url, char *localfile, void (*NotifyFunction)(char *lo
}
ExpandBuffer(con, 2048);
sprintf(con->buffer, "GET %s HTTP/1.1\r\n" "Host: %s\r\n" "Connection: close\r\n" "User-Agent: FTE\r\n" "\r\n", uri, server);
sprintf(con->buffer, "GET %s HTTP/1.1\r\n" "Host: %s\r\n" "Connection: close\r\n" "User-Agent: "FULLENGINENAME"\r\n" "\r\n", uri, server);
con->bufferused = strlen(con->buffer);
con->contentlength = -1;
con->NotifyFunction = NotifyFunction;

View File

@ -351,7 +351,7 @@ cont:
if (HTTPmarkup == 3 && !hostspecified) //1.1 requires the host to be specified... we ca,just ignore it as we're not routing or imitating two servers. (for complience we need to encourage the client to send - does nothing for compatability or anything, just compliance to spec. not always the same thing)
{
msg = "HTTP/1.1 400 Bad Request\r\n" "Content-Type: text/plain\r\n" "Content-Length: 69\r\n" "Server: FTE/0\r\n" "\r\n" "400 Bad Request\r\nYour client failed to provide the host header line";
msg = "HTTP/1.1 400 Bad Request\r\n" "Content-Type: text/plain\r\n" "Content-Length: 69\r\n" "Server: "FULLENGINENAME"/0\r\n" "\r\n" "400 Bad Request\r\nYour client failed to provide the host header line";
ammount = strlen(msg);
ExpandOutBuffer(cl, ammount, true);
@ -368,9 +368,9 @@ cont:
if (!cl->file)
{
if (HTTPmarkup >= 3)
msg = "HTTP/1.1 404 Not Found\r\n" "Content-Type: text/plain\r\n" "Content-Length: 15\r\n" "Server: FTE/0\r\n" "\r\n" "404 Bad address";
msg = "HTTP/1.1 404 Not Found\r\n" "Content-Type: text/plain\r\n" "Content-Length: 15\r\n" "Server: "FULLENGINENAME"/0\r\n" "\r\n" "404 Bad address";
else if (HTTPmarkup == 2)
msg = "HTTP/1.0 404 Not Found\r\n" "Content-Type: text/plain\r\n" "Content-Length: 15\r\n" "Server: FTE/0\r\n" "\r\n" "404 Bad address";
msg = "HTTP/1.0 404 Not Found\r\n" "Content-Type: text/plain\r\n" "Content-Length: 15\r\n" "Server: "FULLENGINENAME"/0\r\n" "\r\n" "404 Bad address";
else if (HTTPmarkup)
msg = "HTTP/0.9 404 Not Found\r\n" "\r\n" "404 Bad address";
else
@ -385,9 +385,9 @@ cont:
else
{
if (HTTPmarkup>=3)
sprintf(resource, "HTTP/1.1 200 OK\r\n" "Content-Type: %s\r\n" "Content-Length: %i\r\n" "Server: FTE/0\r\n" "\r\n", strstr(resource, ".htm")?"text/html":"text/plain", cl->file->length);
sprintf(resource, "HTTP/1.1 200 OK\r\n" "Content-Type: %s\r\n" "Content-Length: %i\r\n" "Server: "FULLENGINENAME"/0\r\n" "\r\n", strstr(resource, ".htm")?"text/html":"text/plain", cl->file->length);
else if (HTTPmarkup==2)
sprintf(resource, "HTTP/1.0 200 OK\r\n" "Content-Type: %s\r\n" "Content-Length: %i\r\n" "Server: FTE/0\r\n" "\r\n", strstr(resource, ".htm")?"text/html":"text/plain", cl->file->length);
sprintf(resource, "HTTP/1.0 200 OK\r\n" "Content-Type: %s\r\n" "Content-Length: %i\r\n" "Server: "FULLENGINENAME"/0\r\n" "\r\n", strstr(resource, ".htm")?"text/html":"text/plain", cl->file->length);
else if (HTTPmarkup)
sprintf(resource, "HTTP/0.9 200 OK\r\n\r\n");
else

View File

@ -1058,7 +1058,7 @@ void SVC_GetChallenge (void)
if (sv_listen.value >= 2)
{
//dp can respond to this (and fte won't get confused because the challenge will be wrong)
buf = va("challenge FTE%i", svs.challenges[i].challenge);
buf = va("challenge DISTRIBUTION%i", svs.challenges[i].challenge);
Netchan_OutOfBand(NS_SERVER, net_from, strlen(buf)+1, buf);
}
}
@ -1294,7 +1294,7 @@ client_t *SVC_DirectConnect(void)
protocol = SCP_DARKPLACES6;
s = Info_ValueForKey(userinfo[0], "challenge");
if (!strncmp(s, "FTE", 3))
if (!strncmp(s, DISTRIBUTION, strlen(DISTRIBUTION)))
challenge = atoi(s+3);
else
challenge = atoi(s);

View File

@ -29,7 +29,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#ifndef MINIMAL
//#define USESERVICE
#endif
#define SERVICENAME "FTEQWSV"
#define SERVICENAME DISTRIBUTION"SV"
@ -1100,15 +1100,15 @@ void CreateSampleService(qboolean create)
else
{
HKEY hk;
RegOpenKey(HKEY_LOCAL_MACHINE, "SOFTWARE\\FTE", &hk);
if (!hk)RegCreateKey(HKEY_LOCAL_MACHINE, "SOFTWARE\\FTE", &hk);
RegOpenKey(HKEY_LOCAL_MACHINE, "SOFTWARE\\"DISTRIBUTION, &hk);
if (!hk)RegCreateKey(HKEY_LOCAL_MACHINE, "SOFTWARE\\"DISTRIBUTION, &hk);
RegSetValueEx(hk, "servicepath", 0, REG_SZ, path, strlen(path));
RegCloseKey(hk);
schService = CreateService(
schSCManager, // SCManager database
SERVICENAME, // name of service
"FTE QuakeWorld Server", // service name to display
FULLENGINENAME" Server", // service name to display
SERVICE_ALL_ACCESS, // desired access
SERVICE_WIN32_OWN_PROCESS|SERVICE_INTERACTIVE_PROCESS, // service type
SERVICE_AUTO_START, // start type

View File

@ -506,8 +506,8 @@ LONG WINAPI MainWndProc (
/*
** VID_CreateWindow
*/
#define WINDOW_CLASS_NAME "FTE QuakeWorld"
#define WINDOW_TITLE_NAME "FTE QuakeWorld"
#define WINDOW_CLASS_NAME FULLENGINENAME
#define WINDOW_TITLE_NAME FULLENGINENAME
void VID_CreateWindow( int width, int height, qboolean fullscreen)