Overhaul to console structure, a bit
This commit is contained in:
+17
-17
@@ -116,7 +116,7 @@ void CL_Disconnect(void) {
|
||||
if (cls.demorecording)
|
||||
CL_Stop_f();
|
||||
|
||||
Con_DPrintf("Sending clc_disconnect\n");
|
||||
console::debug("Sending clc_disconnect\n");
|
||||
SZ_Clear(&cls.message);
|
||||
MSG_WriteByte(&cls.message, clc_disconnect);
|
||||
NET_SendUnreliableMessage(cls.netcon, &cls.message);
|
||||
@@ -160,7 +160,7 @@ void CL_EstablishConnection(const char *host) {
|
||||
cls.netcon = NET_Connect(host);
|
||||
if (!cls.netcon)
|
||||
Host_Error("CL_Connect: connect failed");
|
||||
Con_DPrintf("CL_EstablishConnection: connected to %s\n", host);
|
||||
console::debug("CL_EstablishConnection: connected to %s\n", host);
|
||||
|
||||
cls.demonum = -1; // not in the demo loop now
|
||||
cls.state = ca_connected;
|
||||
@@ -178,7 +178,7 @@ An svc_signonnum has been received, perform a client side setup
|
||||
void CL_SignonReply(void) {
|
||||
char str[8192];
|
||||
|
||||
Con_DPrintf("CL_SignonReply: %i\n", cls.signon);
|
||||
console::debug("CL_SignonReply: %i\n", cls.signon);
|
||||
|
||||
switch (cls.signon) {
|
||||
case 1:
|
||||
@@ -227,7 +227,7 @@ void CL_NextDemo(void) {
|
||||
if (!cls.demos[cls.demonum][0] || cls.demonum == MAX_DEMOS) {
|
||||
cls.demonum = 0;
|
||||
if (!cls.demos[cls.demonum][0]) {
|
||||
Con_Printf("No demos listed with startdemos\n");
|
||||
console::info("No demos listed with startdemos\n");
|
||||
cls.demonum = -1;
|
||||
CL_Disconnect();
|
||||
return;
|
||||
@@ -254,12 +254,12 @@ void CL_PrintEntities_f(void) {
|
||||
return;
|
||||
|
||||
for (i = 0, ent = cl_entities; i < cl.num_entities; i++, ent++) {
|
||||
Con_Printf("%3i:", i);
|
||||
console::info("%3i:", i);
|
||||
if (!ent->model) {
|
||||
Con_Printf("EMPTY\n");
|
||||
console::info("EMPTY\n");
|
||||
continue;
|
||||
}
|
||||
Con_Printf("%s:%2i (%5.1f,%5.1f,%5.1f) [%5.1f %5.1f %5.1f]\n"
|
||||
console::info("%s:%2i (%5.1f,%5.1f,%5.1f) [%5.1f %5.1f %5.1f]\n"
|
||||
, ent->model->name, ent->frame, ent->origin[0], ent->origin[1], ent->origin[2], ent->angles[0],
|
||||
ent->angles[1], ent->angles[2]);
|
||||
}
|
||||
@@ -597,7 +597,7 @@ int CL_ReadFromServer(void) {
|
||||
} while (ret && cls.state == ca_connected);
|
||||
|
||||
if (cl_shownet.value)
|
||||
Con_Printf("\n");
|
||||
console::info("\n");
|
||||
|
||||
CL_RelinkEntities();
|
||||
CL_UpdateTEnts();
|
||||
@@ -606,13 +606,13 @@ int CL_ReadFromServer(void) {
|
||||
|
||||
//visedicts
|
||||
if (cl_numvisedicts > 256 && dev_peakstats.visedicts <= 256)
|
||||
Con_DWarning("%i visedicts exceeds standard limit of 256 (max = %d).\n", cl_numvisedicts, MAX_VISEDICTS);
|
||||
console::dev_warn("%i visedicts exceeds standard limit of 256 (max = %d).\n", cl_numvisedicts, MAX_VISEDICTS);
|
||||
dev_stats.visedicts = cl_numvisedicts;
|
||||
dev_peakstats.visedicts = std::max(cl_numvisedicts, dev_peakstats.visedicts);
|
||||
|
||||
//temp entities
|
||||
if (num_temp_entities > 64 && dev_peakstats.tempents <= 64)
|
||||
Con_DWarning("%i tempentities exceeds standard limit of 64 (max = %d).\n", num_temp_entities,
|
||||
console::dev_warn("%i tempentities exceeds standard limit of 64 (max = %d).\n", num_temp_entities,
|
||||
MAX_TEMP_ENTITIES);
|
||||
dev_stats.tempents = num_temp_entities;
|
||||
dev_peakstats.tempents = std::max(num_temp_entities, dev_peakstats.tempents);
|
||||
@@ -622,7 +622,7 @@ int CL_ReadFromServer(void) {
|
||||
if (b->model && b->endtime >= cl.time)
|
||||
num_beams++;
|
||||
if (num_beams > 24 && dev_peakstats.beams <= 24)
|
||||
Con_DWarning("%i beams exceeded standard limit of 24 (max = %d).\n", num_beams, MAX_BEAMS);
|
||||
console::dev_warn("%i beams exceeded standard limit of 24 (max = %d).\n", num_beams, MAX_BEAMS);
|
||||
dev_stats.beams = num_beams;
|
||||
dev_peakstats.beams = std::max(num_beams, dev_peakstats.beams);
|
||||
|
||||
@@ -631,7 +631,7 @@ int CL_ReadFromServer(void) {
|
||||
if (l->die >= cl.time && l->radius)
|
||||
num_dlights++;
|
||||
if (num_dlights > 32 && dev_peakstats.dlights <= 32)
|
||||
Con_DWarning("%i dlights exceeded standard limit of 32 (max = %d).\n", num_dlights, MAX_DLIGHTS);
|
||||
console::dev_warn("%i dlights exceeded standard limit of 32 (max = %d).\n", num_dlights, MAX_DLIGHTS);
|
||||
dev_stats.dlights = num_dlights;
|
||||
dev_peakstats.dlights = std::max(num_dlights, dev_peakstats.dlights);
|
||||
|
||||
@@ -675,7 +675,7 @@ void CL_SendCmd(void) {
|
||||
return; // no message at all
|
||||
|
||||
if (!NET_CanSendMessage(cls.netcon)) {
|
||||
Con_DPrintf("CL_SendCmd: can't send\n");
|
||||
console::debug("CL_SendCmd: can't send\n");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -702,9 +702,9 @@ void CL_Tracepos_f(void) {
|
||||
TraceLine(r_refdef.vieworg, v, w);
|
||||
|
||||
if (VectorLength(w) == 0)
|
||||
Con_Printf("Tracepos: trace didn't hit anything\n");
|
||||
console::info("Tracepos: trace didn't hit anything\n");
|
||||
else
|
||||
Con_Printf("Tracepos: (%i %i %i)\n", (int) w[0], (int) w[1], (int) w[2]);
|
||||
console::info("Tracepos: (%i %i %i)\n", (int) w[0], (int) w[1], (int) w[2]);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -719,7 +719,7 @@ void CL_Viewpos_f(void) {
|
||||
return;
|
||||
#if 0
|
||||
//camera position
|
||||
Con_Printf("Viewpos: (%i %i %i) %i %i %i\n",
|
||||
console::info("Viewpos: (%i %i %i) %i %i %i\n",
|
||||
(int) r_refdef.vieworg[0],
|
||||
(int) r_refdef.vieworg[1],
|
||||
(int) r_refdef.vieworg[2],
|
||||
@@ -728,7 +728,7 @@ void CL_Viewpos_f(void) {
|
||||
(int) r_refdef.viewangles[ROLL]);
|
||||
#else
|
||||
//player position
|
||||
Con_Printf("Viewpos: (%i %i %i) %i %i %i\n",
|
||||
console::info("Viewpos: (%i %i %i) %i %i %i\n",
|
||||
(int) cl_entities[cl.viewentity].origin[0],
|
||||
(int) cl_entities[cl.viewentity].origin[1],
|
||||
(int) cl_entities[cl.viewentity].origin[2],
|
||||
|
||||
Reference in New Issue
Block a user