From b8e628cc39821101cad13b3de782c5241efe2775 Mon Sep 17 00:00:00 2001 From: Spoike Date: Sat, 8 Jan 2022 10:01:29 +0000 Subject: [PATCH] Minor code cleanups. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@6159 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/client/cl_input.c | 23 ----------------------- engine/client/pr_csqc.c | 2 +- engine/gl/gl_model.h | 2 +- plugins/avplug/avaudio.c | 13 +++++++++++-- 4 files changed, 13 insertions(+), 27 deletions(-) diff --git a/engine/client/cl_input.c b/engine/client/cl_input.c index a658fe38..25d05990 100644 --- a/engine/client/cl_input.c +++ b/engine/client/cl_input.c @@ -1322,29 +1322,6 @@ void CL_UpdatePrydonCursor(usercmd_t *from, int pnum) from->cursor_screen[1] = 1; } - /* - if (cl.cmd.cursor_screen[0] < -1) - { - cl.viewangles[YAW] -= m_yaw.value * (cl.cmd.cursor_screen[0] - -1) * vid.realwidth * sensitivity.value * cl.viewzoom; - cl.cmd.cursor_screen[0] = -1; - } - if (cl.cmd.cursor_screen[0] > 1) - { - cl.viewangles[YAW] -= m_yaw.value * (cl.cmd.cursor_screen[0] - 1) * vid.realwidth * sensitivity.value * cl.viewzoom; - cl.cmd.cursor_screen[0] = 1; - } - if (cl.cmd.cursor_screen[1] < -1) - { - cl.viewangles[PITCH] += m_pitch.value * (cl.cmd.cursor_screen[1] - -1) * vid.realheight * sensitivity.value * cl.viewzoom; - cl.cmd.cursor_screen[1] = -1; - } - if (cl.cmd.cursor_screen[1] > 1) - { - cl.viewangles[PITCH] += m_pitch.value * (cl.cmd.cursor_screen[1] - 1) * vid.realheight * sensitivity.value * cl.viewzoom; - cl.cmd.cursor_screen[1] = 1; - } - */ - VectorClear(from->cursor_start); temp[0] = (from->cursor_screen[0]+1)/2; temp[1] = (-from->cursor_screen[1]+1)/2; diff --git a/engine/client/pr_csqc.c b/engine/client/pr_csqc.c index b1b7ad2a..dd82aaef 100644 --- a/engine/client/pr_csqc.c +++ b/engine/client/pr_csqc.c @@ -7056,7 +7056,7 @@ static struct { {"skel_delete", PF_skel_delete, 275},//void(float skel) skel_delete = #275; // (FTE_CSQC_SKELETONOBJECTS) {"frameforname", PF_frameforname, 276},//float(float modidx, string framename) frameforname = #276 (FTE_CSQC_SKELETONOBJECTS) {"frameduration", PF_frameduration, 277},//float(float modidx, float framenum) frameduration = #277 (FTE_CSQC_SKELETONOBJECTS) - {"frameforaction", PF_frameforaction, 0},//float(float modidx, string actionid) frameforaction = #0 + {"frameforaction", PF_frameforaction, 0},//float(float modidx, int actionid) frameforaction = #0 {"processmodelevents", PF_processmodelevents, 0}, {"getnextmodelevent", PF_getnextmodelevent, 0}, {"getmodeleventidx", PF_getmodeleventidx, 0}, diff --git a/engine/gl/gl_model.h b/engine/gl/gl_model.h index ada415b5..97413868 100644 --- a/engine/gl/gl_model.h +++ b/engine/gl/gl_model.h @@ -909,7 +909,7 @@ typedef enum {sb_none, sb_quake64, sb_long1, sb_long2} subbsp_t; // used to deno #define MFH2_SPIT (1u<<11) // Black transparent trail with negative light #define MFH2_TRANSPARENT (1u<<12) // Transparent sprite #define MFH2_SPELL (1u<<13) // Vertical spray of particles -#define MFH2_HOLEY (1u<<14) // Solid model with color 0 +#define MFH2_HOLEY (1u<<14) // Solid model with color 0 cut out #define MFH2_SPECIAL_TRANS (1u<<15) // Translucency through the particle table #define MFH2_FACE_VIEW (1u<<16) // Poly Model always faces you #define MFH2_VORP_MISSILE (1u<<17) // leave a trail at top and bottom of model diff --git a/plugins/avplug/avaudio.c b/plugins/avplug/avaudio.c index c352231e..be36a401 100644 --- a/plugins/avplug/avaudio.c +++ b/plugins/avplug/avaudio.c @@ -525,9 +525,18 @@ static void AVLogCallback(void *avcl, int level, const char *fmt, va_list vl) { //needs to be reenterant #ifdef _DEBUG char string[1024]; + if (level >= AV_LOG_INFO) + return; //don't care if its just going to be spam. Q_vsnprintf (string, sizeof(string), fmt, vl); - if (pdeveloper && pdeveloper->ival) - Con_Printf("%s", string); + if (level >= AV_LOG_WARNING) + { + if (pdeveloper && pdeveloper->ival) + Con_Printf("ffmpeg: %s", string); + } + else if (level >= AV_LOG_ERROR) + Con_Printf(CON_WARNING"ffmpeg: %s", string); + else + Con_Printf(CON_ERROR"ffmpeg: %s", string); #endif }