diff --git a/.gitmodules b/.gitmodules index 9d44d6b..e69de29 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +0,0 @@ -[submodule "utils/vgui"] - path = utils/vgui - url = https://github.com/FWGS/vgui-dev diff --git a/cl_dll/cdll_int.cpp b/cl_dll/cdll_int.cpp index bd13fe5..762f6be 100644 --- a/cl_dll/cdll_int.cpp +++ b/cl_dll/cdll_int.cpp @@ -21,7 +21,7 @@ #include "hud.h" #include "cl_util.h" #include "netadr.h" -#include "vgui_schememanager.h" +#include "vgui_SchemeManager.h" #include "pm_shared.h" #include "pm_defs.h" diff --git a/cl_dll/death.cpp b/cl_dll/death.cpp index 441d70f..29cb3b2 100644 --- a/cl_dll/death.cpp +++ b/cl_dll/death.cpp @@ -174,7 +174,9 @@ int CHudDeathNotice :: MsgFunc_DeathMsg( const char *pszName, int iSize, void *p gHUD.m_Spectator.DeathMessage(victim); - for ( int i = 0; i < MAX_DEATHNOTICES; i++ ) + int i; + + for ( i = 0; i < MAX_DEATHNOTICES; i++ ) { if ( rgDeathNoticeList[i].iId == 0 ) break; diff --git a/cl_dll/demo.cpp b/cl_dll/demo.cpp index 9694609..7d6114c 100644 --- a/cl_dll/demo.cpp +++ b/cl_dll/demo.cpp @@ -18,7 +18,7 @@ #include "demo_api.h" #include -#define DLLEXPORT __declspec( dllexport ) +//#define DLLEXPORT __declspec( dllexport ) int g_demosniper = 0; int g_demosniperdamage = 0; diff --git a/cl_dll/enginecallback.h b/cl_dll/enginecallback.h index 2d05c79..b56efc7 100644 --- a/cl_dll/enginecallback.h +++ b/cl_dll/enginecallback.h @@ -20,7 +20,8 @@ extern cl_enginefunc_t gEngfuncs; extern render_api_t gRenderfuncs; #define GET_CLIENT_TIME (*gEngfuncs.GetClientTime) -#define GET_CLIENT_OLDTIME (*gEngfuncs.GetClientOldTime) +//#define GET_CLIENT_OLDTIME (*gEngfuncs.GetClientOldTime) +#define GET_CLIENT_OLDTIME (*gEngfuncs.pfnGetClientOldTime) #define CVAR_REGISTER (*gEngfuncs.pfnRegisterVariable) #define CVAR_GET_FLOAT (*gEngfuncs.pfnGetCvarFloat) #define CVAR_GET_STRING (*gEngfuncs.pfnGetCvarString) diff --git a/cl_dll/health.cpp b/cl_dll/health.cpp index 04ea41a..e46a669 100644 --- a/cl_dll/health.cpp +++ b/cl_dll/health.cpp @@ -400,7 +400,7 @@ int CHudHealth::DrawPain(float flTime) int CHudHealth::DrawDamage(float flTime) { - int r, g, b, a; + int r, g, b, a, i; DAMAGE_IMAGE *pdmg; if (!m_bitsDamage) @@ -413,7 +413,7 @@ int CHudHealth::DrawDamage(float flTime) ScaleColors(r, g, b, a); // Draw all the items - for (int i = 0; i < NUM_DMG_TYPES; i++) + for (i = 0; i < NUM_DMG_TYPES; i++) { if (m_bitsDamage & giDmgFlags[i]) { diff --git a/cl_dll/in_camera.cpp b/cl_dll/in_camera.cpp index 453f82a..2478d71 100644 --- a/cl_dll/in_camera.cpp +++ b/cl_dll/in_camera.cpp @@ -4,6 +4,8 @@ // // $NoKeywords: $ //============================================================================= +#if 0 +// TODO: import hlsdk-xash3d input #include "hud.h" #include "cl_util.h" @@ -618,4 +620,6 @@ int DLLEXPORT CL_IsThirdPerson( void ) void DLLEXPORT CL_CameraOffset( float *ofs ) { VectorCopy( cam_ofs, ofs ); -} \ No newline at end of file +} + +#endif diff --git a/cl_dll/in_defs.h b/cl_dll/in_defs.h index e74fdc1..c453a9e 100644 --- a/cl_dll/in_defs.h +++ b/cl_dll/in_defs.h @@ -16,7 +16,7 @@ // fall over #define ROLL 2 -#define DLLEXPORT __declspec( dllexport ) +#include void V_StartPitchDrift( void ); void V_StopPitchDrift( void ); diff --git a/cl_dll/input.cpp b/cl_dll/input.cpp index 6e41d17..b48f70c 100644 --- a/cl_dll/input.cpp +++ b/cl_dll/input.cpp @@ -22,7 +22,7 @@ #include "in_defs.h" #include #include - +#include #include "vgui_TeamFortressViewport.h" diff --git a/cl_dll/inputw32.cpp b/cl_dll/inputw32.cpp index 743f33f..b42dcbb 100644 --- a/cl_dll/inputw32.cpp +++ b/cl_dll/inputw32.cpp @@ -7,6 +7,8 @@ // in_win.c -- windows 95 mouse and joystick code // 02/21/97 JCB Added extended DirectInput code to support external controllers. +/// TODO: import hlsdk-xash3d input interface +#if 0 #include "hud.h" #include "cl_util.h" @@ -960,4 +962,6 @@ void IN_Init (void) IN_StartupMouse (); IN_StartupJoystick (); -} \ No newline at end of file +} + +#endif \ No newline at end of file diff --git a/cl_dll/menu.cpp b/cl_dll/menu.cpp index 06dac92..d3c5fac 100644 --- a/cl_dll/menu.cpp +++ b/cl_dll/menu.cpp @@ -84,7 +84,8 @@ int CHudMenu :: Draw( float flTime ) // count the number of newlines int nlc = 0; - for ( int i = 0; i < MAX_MENU_STRING && g_szMenuString[i] != '\0'; i++ ) + int i; + for ( i = 0; i < MAX_MENU_STRING && g_szMenuString[i] != '\0'; i++ ) { if ( g_szMenuString[i] == '\n' ) nlc++; diff --git a/cl_dll/render/gl_aurora.cpp b/cl_dll/render/gl_aurora.cpp index 2892db9..e3a45b7 100644 --- a/cl_dll/render/gl_aurora.cpp +++ b/cl_dll/render/gl_aurora.cpp @@ -1049,7 +1049,7 @@ bool CParticleSystem :: UpdateParticle( CParticle *part, float frametime ) return true; } -void CParticleSystem :: DrawParticle( CParticle *part, vec3_t &right, vec3_t &up ) +void CParticleSystem :: DrawParticle( CParticle *part, const vec3_t &right, const vec3_t &up ) { float fSize = part->m_fSize; @@ -1083,10 +1083,11 @@ void CParticleSystem :: DrawParticle( CParticle *part, vec3_t &right, vec3_t &up { if( pDraw->pType->m_iDrawCond == CONTENTS_SPOTLIGHT ) { + int i; if( !m_fHasProjectionLighting ) continue; // fast reject - for( int i = 0; i < MAX_DLIGHTS; i++ ) + for( i = 0; i < MAX_DLIGHTS; i++ ) { CDynLight *pl = &tr.dlights[i]; diff --git a/cl_dll/render/gl_aurora.h b/cl_dll/render/gl_aurora.h index 521be51..214ff52 100644 --- a/cl_dll/render/gl_aurora.h +++ b/cl_dll/render/gl_aurora.h @@ -152,7 +152,7 @@ public: // MUST CHECK WHETHER THIS RESULT IS NULL! // returns false if the particle has died bool UpdateParticle( CParticle *part, float frametime ); - void DrawParticle( CParticle *part, Vector &right, Vector &up ); + void DrawParticle( CParticle *part, const Vector &right, const Vector &up ); // Utility functions that have to be public bool ParticleIsVisible( CParticle* part ); diff --git a/cl_dll/render/gl_export.h b/cl_dll/render/gl_export.h index fc482a2..aed36d4 100644 --- a/cl_dll/render/gl_export.h +++ b/cl_dll/render/gl_export.h @@ -16,8 +16,9 @@ GNU General Public License for more details. #ifndef GL_EXPORT_H #define GL_EXPORT_H -#include - +// not needed since we have GL_GetProcAddress in RenderAPI +//#include +#include #ifndef APIENTRY #define APIENTRY #endif @@ -1350,7 +1351,7 @@ EXTERN void ( APIENTRY *pglGetFinalCombinerInputParameterfvNV )( GLenum, GLenum, EXTERN void ( APIENTRY *pglGetFinalCombinerInputParameterivNV )( GLenum, GLenum, GLint * ); EXTERN void ( APIENTRY *pglGenerateMipmap )( GLenum target ); EXTERN void ( APIENTRY *pglDrawBuffersARB)( GLsizei n, const GLenum *bufs ); -EXTERN PROC ( WINAPI *pwglGetProcAddress)( const char * ); +//EXTERN PROC ( WINAPI *pwglGetProcAddress)( const char * ); EXTERN void ( APIENTRY *pglBindVertexArray )( GLuint array ); EXTERN void ( APIENTRY *pglDeleteVertexArrays )( GLsizei n, const GLuint *arrays ); diff --git a/cl_dll/render/gl_movie.cpp b/cl_dll/render/gl_movie.cpp index 91e413a..56ba093 100644 --- a/cl_dll/render/gl_movie.cpp +++ b/cl_dll/render/gl_movie.cpp @@ -39,8 +39,9 @@ int R_PrecacheCinematic( const char *cinname ) if( Q_stricmp( UTIL_FileExtension( cinname ), "avi" )) return -1; + int i; // first check for co-existing - for( int i = 0; i < MAX_MOVIES; i++ ) + for( i = 0; i < MAX_MOVIES; i++ ) { if( !Q_stricmp( tr.cinematics[i].name, cinname )) { @@ -104,7 +105,8 @@ void R_InitCinematics( void ) void R_FreeCinematics( void ) { - for( int i = 0; i < MAX_MOVIES; i++ ) + int i; + for( i = 0; i < MAX_MOVIES; i++ ) { if( tr.cinematics[i].state ) { diff --git a/cl_dll/render/gl_rmain.cpp b/cl_dll/render/gl_rmain.cpp index 1479c7b..fe8a09b 100644 --- a/cl_dll/render/gl_rmain.cpp +++ b/cl_dll/render/gl_rmain.cpp @@ -87,7 +87,8 @@ void R_BuildViewPassHierarchy( void ) if( glState.stack_position > 0 ) num_faces = R_GetPrevInstance()->frame.num_subview_faces; - for( unsigned int i = 0; i < glState.stack_position; i++ ) + unsigned int i; + for( i = 0; i < glState.stack_position; i++ ) empty[i] = ' '; empty[i] = '\0'; diff --git a/cl_dll/render/gl_rpart.cpp b/cl_dll/render/gl_rpart.cpp index d23d884..458d9ee 100644 --- a/cl_dll/render/gl_rpart.cpp +++ b/cl_dll/render/gl_rpart.cpp @@ -509,7 +509,8 @@ bool CQuakePartSystem :: ParseRandomVector( char *&pfile, RandomRange out[3] ) { char token[256]; - for( int i = 0; i < 3 && pfile != NULL; i++ ) + int i; + for( i = 0; i < 3 && pfile != NULL; i++ ) { pfile = COM_ParseLine( pfile, token ); out[i] = RandomRange( token ); @@ -904,7 +905,8 @@ void CQuakePartSystem :: ExplosionParticles( const Vector &pos ) flags = (FPART_STRETCH|FPART_BOUNCE|FPART_FRICTION); - for( int i = 0; i < 384; i++ ) + int i; + for( i = 0; i < 384; i++ ) { src.m_vecOrigin.x = pos.x + RANDOM_LONG( -16, 16 ); src.m_vecOrigin.y = pos.y + RANDOM_LONG( -16, 16 ); @@ -1128,7 +1130,8 @@ void CQuakePartSystem :: BulletParticles( const Vector &org, const Vector &dir ) // sparks int flags = (FPART_STRETCH|FPART_BOUNCE|FPART_FRICTION|FPART_ADDITIVE); - for( int i = 0; i < count; i++ ) + int i; + for( i = 0; i < count; i++ ) { src.m_vecOrigin.x = org[0] + dir[0] * 2 + RANDOM_FLOAT( -1, 1 ); src.m_vecOrigin.y = org[1] + dir[1] * 2 + RANDOM_FLOAT( -1, 1 ); diff --git a/cl_dll/render/gl_shader.cpp b/cl_dll/render/gl_shader.cpp index be301ce..1678d9b 100644 --- a/cl_dll/render/gl_shader.cpp +++ b/cl_dll/render/gl_shader.cpp @@ -1146,8 +1146,9 @@ word GL_FindUberShader( const char *glname, const char *options ) return (word)(prog - glsl_programs); } + int i; // find free spot - for( int i = 1; i < num_glsl_programs; i++ ) + for( i = 1; i < num_glsl_programs; i++ ) if( !glsl_programs[i].name[0] ) break; @@ -1188,8 +1189,9 @@ word GL_FindShader( const char *glname, const char *vpname, const char *fpname, return (word)(prog - glsl_programs); } + int i; // find free spot - for( int i = 1; i < num_glsl_programs; i++ ) + for( i = 1; i < num_glsl_programs; i++ ) if( !glsl_programs[i].name[0] ) break; diff --git a/cl_dll/render/gl_shadows.cpp b/cl_dll/render/gl_shadows.cpp index d936cf8..783a49f 100644 --- a/cl_dll/render/gl_shadows.cpp +++ b/cl_dll/render/gl_shadows.cpp @@ -144,7 +144,9 @@ static int R_ComputeCropBounds( const matrix4x4 &lightViewProjection, Vector bou frustum.DisablePlane( FRUSTUM_NEAR ); frustum.DisablePlane( FRUSTUM_FAR ); - for( int i = 0; i < prevRI->frame.solid_faces.Count(); i++ ) + int i; + + for( i = 0; i < prevRI->frame.solid_faces.Count(); i++ ) { CSolidEntry *entry = &prevRI->frame.solid_faces[i]; diff --git a/cl_dll/render/gl_sprite.cpp b/cl_dll/render/gl_sprite.cpp index d0ac587..c7cd874 100644 --- a/cl_dll/render/gl_sprite.cpp +++ b/cl_dll/render/gl_sprite.cpp @@ -95,7 +95,8 @@ mspriteframe_t *CSpriteModelRenderer :: GetSpriteFrame( int frame, float yaw ) // are positive, so we don't have to worry about division by zero float targettime = m_clTime - ((int)( m_clTime / fullinterval )) * fullinterval; - for( int i = 0; i < (numframes - 1); i++ ) + int i; + for( i = 0; i < (numframes - 1); i++ ) { if( pintervals[i] > targettime ) break; diff --git a/cl_dll/render/gl_studio_draw.cpp b/cl_dll/render/gl_studio_draw.cpp index 170210b..be43a59 100644 --- a/cl_dll/render/gl_studio_draw.cpp +++ b/cl_dll/render/gl_studio_draw.cpp @@ -1363,7 +1363,9 @@ void CStudioModelRenderer :: StudioMergeBones( matrix3x4 &transform, matrix3x4 b for( int i = 0; i < m_pStudioHeader->numbones; i++ ) { - for( int j = 0; j < m_pParentHeader->numbones; j++ ) + int j; + + for( j = 0; j < m_pParentHeader->numbones; j++ ) { if( !Q_stricmp( pchildbones[i].name, pparentbones[j].name )) { @@ -1697,7 +1699,7 @@ void CStudioModelRenderer :: StudioStaticLight( cl_entity_t *ent, mstudiolight_t m_pModelInstance->light_update = false; // init state if was not in frustum - if( abs( m_pModelInstance->cached_frame - tr.realframecount ) > 2 ) + if( Q_abs( m_pModelInstance->cached_frame - tr.realframecount ) > 2 ) m_pModelInstance->oldlight = m_pModelInstance->newlight; } @@ -2849,7 +2851,9 @@ void CStudioModelRenderer :: RenderDeferredStudioList( void ) RI->currentmodel = NULL; m_pCurrentMaterial = NULL; - for( int i = 0; i < RI->frame.solid_meshes.Count(); i++ ) + int i; + + for( i = 0; i < RI->frame.solid_meshes.Count(); i++ ) { CSolidEntry *entry = &RI->frame.solid_meshes[i]; @@ -3731,7 +3735,9 @@ void CStudioModelRenderer :: RenderSolidStudioList( void ) RI->currentmodel = NULL; m_pCurrentMaterial = NULL; - for( int i = 0; i < RI->frame.solid_meshes.Count(); i++ ) + int i; + + for( i = 0; i < RI->frame.solid_meshes.Count(); i++ ) { CSolidEntry *entry = &RI->frame.solid_meshes[i]; diff --git a/cl_dll/render/gl_studio_init.cpp b/cl_dll/render/gl_studio_init.cpp index eb14ba5..7923e6e 100644 --- a/cl_dll/render/gl_studio_init.cpp +++ b/cl_dll/render/gl_studio_init.cpp @@ -1541,8 +1541,9 @@ void CStudioModelRenderer :: SetupSubmodelVerts( const mstudiomodel_t *pSubModel // search for submodel offset int offset = (byte *)pSubModel - (byte *)m_pStudioHeader; + int j; - for( int j = 0; j < MAXSTUDIOMODELS; j++ ) + for( j = 0; j < MAXSTUDIOMODELS; j++ ) { if( m_tbnverts->submodels[j].submodel_offset == offset ) break; diff --git a/cl_dll/render/gl_studiodecal.h b/cl_dll/render/gl_studiodecal.h index cb119cc..5db1775 100644 --- a/cl_dll/render/gl_studiodecal.h +++ b/cl_dll/render/gl_studiodecal.h @@ -16,7 +16,7 @@ GNU General Public License for more details. #ifndef GL_STUDIODECAL_H #define GL_STUDIODECAL_H -typedef enum +enum { DECAL_CLIP_MINUSU = 0x1, DECAL_CLIP_MINUSV = 0x2, diff --git a/cl_dll/render/gl_world_new.cpp b/cl_dll/render/gl_world_new.cpp index d259db7..878ea33 100644 --- a/cl_dll/render/gl_world_new.cpp +++ b/cl_dll/render/gl_world_new.cpp @@ -304,9 +304,10 @@ void GL_LoadAndRebuildCubemaps( int refParams ) // now all the cubemaps are recreated, so we can starts to upload them if( world->loading_cubemaps ) { + int i; Mod_LoadCubemap( &world->defaultCubemap ); - for( int i = 0; i < world->num_cubemaps; i++ ) + for( i = 0; i < world->num_cubemaps; i++ ) { mcubemap_t *cm = &world->cubemaps[i]; Vector vecStart, vecEnd; diff --git a/cl_dll/render/vertex_fmt.h b/cl_dll/render/vertex_fmt.h index 81c36c2..53537db 100644 --- a/cl_dll/render/vertex_fmt.h +++ b/cl_dll/render/vertex_fmt.h @@ -17,8 +17,11 @@ GNU General Public License for more details. #ifndef VERTEX_FMT_H #define VERTEX_FMT_H +#ifdef _MSC_VER #define no_align __declspec(align(1)) - +#else +#define no_align +#endif // name specific: // fisrt letter is model type: B - BrushModel, G - Grass, D - Decal, S - StudioModel // next four letters is always equal "vert" for more readability @@ -48,6 +51,7 @@ typedef struct byte styles[MAXLIGHTMAPS]; // light styles } bvert_v0_gl21_t; +#pragma pack(1) // 84 bytes here no_align typedef struct { @@ -62,7 +66,7 @@ no_align typedef struct byte lights0[4]; // packed light numbers byte lights1[4]; // packed light numbers } bvert_v0_gl30_t; - +#pragma pack() /* ============================================================= @@ -128,7 +132,7 @@ typedef struct float normal[3]; // normal float boneid; // control bones } svert_v0_gl21_t; - +#pragma pack(1) // 24 bytes no_align typedef struct { @@ -137,7 +141,7 @@ no_align typedef struct char normal[3]; // normal char boneid; // control bones } svert_v0_gl30_t; - +#pragma pack() // version 1. have bump, no boneweights, no vertexlight // 68 bytes typedef struct @@ -150,6 +154,7 @@ typedef struct float boneid; // control bones } svert_v1_gl21_t; +#pragma pack(1) // 32 bytes no_align typedef struct { @@ -160,6 +165,7 @@ no_align typedef struct char binormal[3]; // binormal char boneid; // control bones } svert_v1_gl30_t; +#pragma pack() // version 2. no bump, single bone, has vertex lighting // 56 bytes @@ -170,6 +176,7 @@ typedef struct float normal[3]; // normal float light[MAXLIGHTMAPS]; // packed color } svert_v2_gl21_t; +#pragma pack(1) // 40 bytes no_align typedef struct @@ -179,6 +186,7 @@ no_align typedef struct char normal[3]; // normal float light[MAXLIGHTMAPS]; // packed color } svert_v2_gl30_t; +#pragma pack() // version 3. have bump, single bone, has vertex lighting // 96 bytes @@ -192,6 +200,7 @@ typedef struct float tangent[3]; // tangent float binormal[3]; // binormal } svert_v3_gl21_t; +#pragma pack(1) // 64 bytes no_align typedef struct @@ -204,6 +213,7 @@ no_align typedef struct char tangent[3]; // tangent char binormal[3]; // binormal } svert_v3_gl30_t; +#pragma pack() // version 4. no bump, have boneweights, no vertexlight // 72 bytes @@ -216,6 +226,8 @@ typedef struct float weight[4]; // boneweights } svert_v4_gl21_t; +#pragma pack(1) + // 32 bytes no_align typedef struct { @@ -225,6 +237,7 @@ no_align typedef struct char boneid[4]; // control bones byte weight[4]; // boneweights } svert_v4_gl30_t; +#pragma pack() // version 5. have bump, have boneweights, no vertexlight // 96 bytes @@ -239,6 +252,7 @@ typedef struct float weight[4]; // boneweights } svert_v5_gl21_t; +#pragma pack(1) // 40 bytes no_align typedef struct { @@ -250,6 +264,7 @@ no_align typedef struct char boneid[4]; // control bones byte weight[4]; // boneweights } svert_v5_gl30_t; +#pragma pack() // version 6. no bump, single bone, has lightmaps // 76 bytes @@ -263,6 +278,8 @@ typedef struct byte styles[MAXLIGHTMAPS]; // light styles } svert_v6_gl21_t; +#pragma pack(1) + // 60 bytes no_align typedef struct { @@ -273,6 +290,7 @@ no_align typedef struct char normal[3]; // normal byte styles[MAXLIGHTMAPS]; // light styles } svert_v6_gl30_t; +#pragma pack() // version 7. have bump, single bone, has lightmaps // 100 bytes @@ -288,6 +306,7 @@ typedef struct byte styles[MAXLIGHTMAPS]; // light styles } svert_v7_gl21_t; +#pragma pack(1) // 68 bytes no_align typedef struct { @@ -300,6 +319,7 @@ no_align typedef struct char binormal[3]; // binormal byte styles[MAXLIGHTMAPS]; // light styles } svert_v7_gl30_t; +#pragma pack() // version 8. includes all posible combination, slowest // 164 bytes here @@ -319,6 +339,8 @@ typedef struct byte styles[MAXLIGHTMAPS]; // light styles } svert_v8_gl21_t; +#pragma pack(1) + // 108 bytes here no_align typedef struct { @@ -335,5 +357,6 @@ no_align typedef struct float deluxe[MAXLIGHTMAPS]; // packed lightdir byte styles[MAXLIGHTMAPS]; // light styles } svert_v8_gl30_t; +#pragma pack() #endif//VERTEX_FMT_H \ No newline at end of file diff --git a/cl_dll/vgui_SpectatorPanel.cpp b/cl_dll/vgui_SpectatorPanel.cpp index 0ee1bb7..7194c06 100644 --- a/cl_dll/vgui_SpectatorPanel.cpp +++ b/cl_dll/vgui_SpectatorPanel.cpp @@ -17,7 +17,7 @@ #include "pm_shared.h" #include "vgui_TeamFortressViewport.h" #include "vgui_SpectatorPanel.h" -#include "vgui_scorepanel.h" +#include "vgui_ScorePanel.h" #define PANEL_HEIGHT 32 diff --git a/cl_dll/vgui_paranoiatext.cpp b/cl_dll/vgui_paranoiatext.cpp index 96f7994..8604256 100644 --- a/cl_dll/vgui_paranoiatext.cpp +++ b/cl_dll/vgui_paranoiatext.cpp @@ -6,7 +6,7 @@ #include "VGUI_TextImage.h" #include "../engine/keydefs.h" #include "triangleapi.h" -#include "../game_shared/vgui_LoadTGA.h" +#include "../game_shared/vgui_loadtga.h" #include "r_studioint.h" #include "com_model.h" #include "stringlib.h" diff --git a/cl_dll/vgui_pickup.h b/cl_dll/vgui_pickup.h index edc8eec..266b778 100644 --- a/cl_dll/vgui_pickup.h +++ b/cl_dll/vgui_pickup.h @@ -9,7 +9,7 @@ using namespace vgui; #include "vgui_shadowtext.h" #include "VGUI_TextImage.h" -Font* FontFromMessage(const char* &ptext); +Font* FontFromMessage(char* &ptext); void CheckPanel(); @@ -38,7 +38,7 @@ public: void SetMessage( client_textmessage_t *msg ) { setSize(ScreenWidth, 16); - const char *text = msg->pMessage; + char *text = (char*)msg->pMessage; Font *pFont = FontFromMessage(text); char buf[1024]; sprintf(buf, text, g_ammoAdded); // text message should contain %d substring diff --git a/cl_dll/vgui_subtitles.cpp b/cl_dll/vgui_subtitles.cpp index 09d5c73..328439a 100644 --- a/cl_dll/vgui_subtitles.cpp +++ b/cl_dll/vgui_subtitles.cpp @@ -20,7 +20,7 @@ cvar_t *scroll_speed; cvar_t *fade_speed; -Font* FontFromMessage(const char* &ptext) +Font* FontFromMessage(char* &ptext) { char fontname[64] = "Default Text"; if (ptext != NULL && ptext[0] != 0) @@ -154,7 +154,7 @@ void CSubtitle::AddMessage( client_textmessage_t *msg ) // SchemeHandle_t hTextScheme = pSchemes->getSchemeHandle( "Default Text" ); // Font *pFont = pSchemes->getFont( hTextScheme ); - const char *pText = msg->pMessage; + char *pText = (char*)msg->pMessage; client_textmessage_t *postMsg = NULL; if (pText[0] == '$') { @@ -244,7 +244,8 @@ void CSubtitle::paintBackground() // find oldest child to start fading int float mintime = 99999; - for (int i = 0; i < m_pLayer->getChildCount(); i++) + int i; + for (i = 0; i < m_pLayer->getChildCount(); i++) { CSubtitleTextPanel *chld = (CSubtitleTextPanel*)m_pLayer->getChild(i); if (chld->isVisible() && chld->m_fBirthTime < mintime) diff --git a/cl_dll/wscript b/cl_dll/wscript index 2fbf3ca..e0c388d 100644 --- a/cl_dll/wscript +++ b/cl_dll/wscript @@ -28,6 +28,7 @@ def build(bld): includes = [ '.', 'hl/', + 'render/', '../dlls', '../common', '../engine', diff --git a/common/port.h b/common/port.h index 6b9a351..b1af492 100644 --- a/common/port.h +++ b/common/port.h @@ -156,4 +156,8 @@ GNU General Public License for more details. #include #endif +#ifndef MAX_PATH +#define MAX_PATH PATH_MAX +#endif + #endif // PORT_H diff --git a/dlls/cbase.h b/dlls/cbase.h index 20cbf55..cf9c80d 100644 --- a/dlls/cbase.h +++ b/dlls/cbase.h @@ -66,13 +66,7 @@ CBaseEntity #include "meshdesc.h" // C functions for external declarations that call the appropriate C++ methods - -#ifdef _WIN32 -#define EXPORT _declspec( dllexport ) -#else -#define EXPORT /* */ -#endif - +#include "exportdef.h" extern "C" EXPORT int GetEntityAPI( DLL_FUNCTIONS *pFunctionTable, int interfaceVersion ); extern "C" EXPORT int GetEntityAPI2( DLL_FUNCTIONS *pFunctionTable, int *interfaceVersion ); extern "C" EXPORT int GetNewDLLFunctions( NEW_DLL_FUNCTIONS *pFunctionTable, int *interfaceVersion ); diff --git a/dlls/extdll.h b/dlls/extdll.h index 5f375be..00dcea8 100644 --- a/dlls/extdll.h +++ b/dlls/extdll.h @@ -14,7 +14,7 @@ ****/ #ifndef EXTDLL_H #define EXTDLL_H - +#include "port.h" // // Global header file for extension DLLs @@ -42,7 +42,7 @@ #else // _WIN32 #define FALSE 0 #define TRUE (!FALSE) -typedef unsigned long ULONG; +//typedef unsigned long ULONG; typedef unsigned char BYTE; typedef int BOOL; #define MAX_PATH PATH_MAX @@ -53,7 +53,7 @@ typedef int BOOL; #endif #ifndef max #define max(a,b) (((a) > (b)) ? (a) : (b)) -#define _vsnprintf(a,b,c,d) vsnprintf(a,b,c,d) +//#define _vsnprintf(a,b,c,d) vsnprintf(a,b,c,d) #endif #endif //_WIN32 diff --git a/dlls/util.h b/dlls/util.h index 42e87b4..4161a65 100644 --- a/dlls/util.h +++ b/dlls/util.h @@ -270,7 +270,7 @@ typedef enum { ignore_monsters=1, dont_ignore_monsters=0, missile=2 } IGNORE_MON typedef enum { ignore_glass=1, dont_ignore_glass=0 } IGNORE_GLASS; extern void UTIL_TraceLine (const Vector &vecStart, const Vector &vecEnd, IGNORE_MONSTERS igmon, edict_t *pentIgnore, TraceResult *ptr); extern void UTIL_TraceLine (const Vector &vecStart, const Vector &vecEnd, IGNORE_MONSTERS igmon, IGNORE_GLASS ignoreGlass, edict_t *pentIgnore, TraceResult *ptr); -typedef enum { point_hull=0, human_hull=1, large_hull=2, head_hull=3 }; +enum { point_hull=0, human_hull=1, large_hull=2, head_hull=3 }; extern void UTIL_TraceHull (const Vector &vecStart, const Vector &vecEnd, IGNORE_MONSTERS igmon, int hullNumber, edict_t *pentIgnore, TraceResult *ptr); extern TraceResult UTIL_GetGlobalTrace (void); extern void UTIL_TraceModel (const Vector &vecStart, const Vector &vecEnd, int hullNumber, edict_t *pentModel, TraceResult *ptr); diff --git a/engine/cdll_int.h b/engine/cdll_int.h index ea4803a..4ab543a 100644 --- a/engine/cdll_int.h +++ b/engine/cdll_int.h @@ -27,12 +27,23 @@ extern "C" { #endif #include "const.h" + +#define MAX_ALIAS_NAME 32 + +typedef struct cmdalias_s +{ + struct cmdalias_s *next; + char name[MAX_ALIAS_NAME]; + char *value; +} cmdalias_t; + #include #ifndef offsetof -#define offsetof(s,m) (size_t)&(((s *)0)->m) +#define offsetof(s,m) (size_t)&(((s *)0)->m) #endif + // this file is included by both the engine and the client-dll, // so make sure engine declarations aren't done twice diff --git a/engine/eiface.h b/engine/eiface.h index f2194a8..0da9e7f 100644 --- a/engine/eiface.h +++ b/engine/eiface.h @@ -88,7 +88,7 @@ typedef struct int fPlayTrack; } CDStatus; -typedef unsigned int CRC32_t; +//typedef unsigned int CRC32_t; // Engine hands this to DLLs for functionality callbacks typedef struct enginefuncs_s diff --git a/game_shared/bitvec.h b/game_shared/bitvec.h index 616f4c7..f1b780b 100644 --- a/game_shared/bitvec.h +++ b/game_shared/bitvec.h @@ -13,7 +13,7 @@ #include - +#include class CBitVecAccessor { diff --git a/game_shared/bone_setup.cpp b/game_shared/bone_setup.cpp index 950a4c0..bbaf7fa 100644 --- a/game_shared/bone_setup.cpp +++ b/game_shared/bone_setup.cpp @@ -1108,8 +1108,9 @@ float CStudioBoneSetup :: SetController( int iController, float flValue, float & mstudiobonecontroller_t *pbonecontroller = (mstudiobonecontroller_t *)((byte *)m_pStudioHeader + m_pStudioHeader->bonecontrollerindex); + int i; // find first controller that matches the index - for( int i = 0; i < m_pStudioHeader->numbonecontrollers; i++, pbonecontroller++ ) + for( i = 0; i < m_pStudioHeader->numbonecontrollers; i++, pbonecontroller++ ) { if( pbonecontroller->index == iController ) break; @@ -1170,8 +1171,9 @@ float CStudioBoneSetup :: GetController( int iController, float ctlValue ) mstudiobonecontroller_t *pbonecontroller = (mstudiobonecontroller_t *)((byte *)m_pStudioHeader + m_pStudioHeader->bonecontrollerindex); + int i; // find first controller that matches the index - for( int i = 0; i < m_pStudioHeader->numbonecontrollers; i++, pbonecontroller++ ) + for( i = 0; i < m_pStudioHeader->numbonecontrollers; i++, pbonecontroller++ ) { if( pbonecontroller->index == iController ) break; diff --git a/game_shared/common.cpp b/game_shared/common.cpp index 18cba57..1d2eb18 100644 --- a/game_shared/common.cpp +++ b/game_shared/common.cpp @@ -13,8 +13,8 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. */ -#define NOMINMAX -#include +//#define NOMINMAX +//#include #include #include #include @@ -23,7 +23,7 @@ GNU General Public License for more details. #include #include #include -#include +//#include /* ============ diff --git a/game_shared/material.cpp b/game_shared/material.cpp index 8cf4c73..a1e4d01 100644 --- a/game_shared/material.cpp +++ b/game_shared/material.cpp @@ -250,8 +250,9 @@ void COM_InitMatdef( void ) { if( !Q_strlen( token )) break; // end of line + int i; // find the free sound slot - for( int i = 0; mat->impact_parts[i] != NULL && i < MAX_MAT_SOUNDS; i++ ); + for( i = 0; mat->impact_parts[i] != NULL && i < MAX_MAT_SOUNDS; i++ ); if( i < MAX_MAT_SOUNDS ) { @@ -265,8 +266,9 @@ void COM_InitMatdef( void ) { if( !Q_strlen( token )) break; // end of line + int i; // find the free sound slot - for( int i = 0; mat->impact_sounds[i] != NULL && i < MAX_MAT_SOUNDS; i++ ); + for( i = 0; mat->impact_sounds[i] != NULL && i < MAX_MAT_SOUNDS; i++ ); if( i < MAX_MAT_SOUNDS ) { @@ -280,8 +282,9 @@ void COM_InitMatdef( void ) { if( !Q_strlen( token )) break; // end of line + int i; // find the free sound slot - for( int i = 0; mat->step_sounds[i] != NULL && i < MAX_MAT_SOUNDS; i++ ); + for( i = 0; mat->step_sounds[i] != NULL && i < MAX_MAT_SOUNDS; i++ ); if( i < MAX_MAT_SOUNDS ) { diff --git a/game_shared/mathlib.cpp b/game_shared/mathlib.cpp index 6982f9a..4062708 100644 --- a/game_shared/mathlib.cpp +++ b/game_shared/mathlib.cpp @@ -42,7 +42,9 @@ fast box on planeside test */ int SignbitsForPlane( const Vector &normal ) { - for( int bits = 0, i = 0; i < 3; i++ ) + int bits, i; + + for( bits = 0, i = 0; i < 3; i++ ) if( normal[i] < 0.0f ) bits |= 1<= 0 ? 1.0 : -1.0 ) +#define Q_abs( x ) ((x)<0?-(x):x) #define bound( min, num, max ) ((num) >= (min) ? ((num) < (max) ? (num) : (max)) : (min)) #define saturate( val ) ((val) >= 0 ? ((val) < 1 ? (val) : 1) : 0) diff --git a/game_shared/matrix.h b/game_shared/matrix.h index c44c25d..3da1b49 100644 --- a/game_shared/matrix.h +++ b/game_shared/matrix.h @@ -206,8 +206,8 @@ public: mat[0][2], mat[1][2], mat[2][2] ); } - Vector matrix3x3::VectorRotate( const Vector &v ) const; - Vector matrix3x3::VectorIRotate( const Vector &v ) const; + Vector VectorRotate( const Vector &v ) const; + Vector VectorIRotate( const Vector &v ) const; // copy as OpenGl matrix inline void CopyToArray( float *rgfl ) const diff --git a/game_shared/stringlib.cpp b/game_shared/stringlib.cpp index 31cc8b4..f906af9 100644 --- a/game_shared/stringlib.cpp +++ b/game_shared/stringlib.cpp @@ -3,12 +3,14 @@ // stringlib.cpp - safety string routines //======================================================================= -#define NOMINMAX -#include +//#define NOMINMAX +//#include #include +#include +#include #include -#include - +#include "stringlib.h" +#include #pragma warning(disable : 4244) // MIPS //============ diff --git a/game_shared/utlarray.h b/game_shared/utlarray.h index ad4b55b..944563d 100644 --- a/game_shared/utlarray.h +++ b/game_shared/utlarray.h @@ -171,7 +171,7 @@ public: CUtlBlockVector( int growSize = 0, int initSize = 0 ) : CUtlArray< T, CUtlBlockMemory< T, int > >( growSize, initSize ) {} }; - +#if 0 //----------------------------------------------------------------------------- // The CUtlArrayFixed class: // A array class with a fixed allocation scheme @@ -189,7 +189,7 @@ public: CUtlArrayMT( typename BaseClass::ElemType_t* pMemory, int numElements ) : BaseClass( pMemory, numElements ) {} }; - +#endif //----------------------------------------------------------------------------- // The CUtlArrayFixed class: // A array class with a fixed allocation scheme diff --git a/game_shared/utlmemory.h b/game_shared/utlmemory.h index 4d79a0e..f8f300a 100644 --- a/game_shared/utlmemory.h +++ b/game_shared/utlmemory.h @@ -16,10 +16,10 @@ #include #include -#include +#include #define ALIGN_VALUE( val, alignment ) (( val + alignment - 1 ) & ~( alignment - 1 )) -#define stackalloc( _size ) _alloca( ALIGN_VALUE( _size, 16 ) ) +#define stackalloc( _size ) alloca( ALIGN_VALUE( _size, 16 ) ) #define stackfree( _p ) 0 // Swap two of anything. diff --git a/game_shared/vector.h b/game_shared/vector.h index ef74658..e1e4a2e 100644 --- a/game_shared/vector.h +++ b/game_shared/vector.h @@ -4,7 +4,7 @@ //======================================================================= #ifndef VECTOR_H #define VECTOR_H - +#include #include #include #include @@ -31,15 +31,16 @@ #define vec2_t Vector2D #define vec3_t Vector #define vec4_t Vector4D - +#ifdef _MSC_VER #pragma warning( disable : 4244 ) // disable 'possible loss of data converting float to int' warning message #pragma warning( disable : 4305 ) // disable 'truncation from 'const double' to 'float' warning message - +#endif class NxVec3; class Radian; inline void SinCos( float angle, float *sine, float *cosine ) { +#if defined _MSC_VER && defined _M_I386 __asm { push ecx @@ -51,6 +52,10 @@ inline void SinCos( float angle, float *sine, float *cosine ) fstp dword ptr [ecx] pop ecx } +#else + *sine = sin(angle); + *cosine = cos(angle); +#endif } inline float Q_rsqrt( float number ) @@ -151,9 +156,9 @@ class NxVec3; //========================================================= // 3D Vector //========================================================= -class Vector // same data-layout as engine's vec3_t, +struct Vector // same data-layout as engine's vec3_t, { // which is a float[3] -public: +//public: // Construction/destruction inline Vector(void) { } inline Vector(float X, float Y, float Z) { x = X; y = Y; z = Z; } diff --git a/game_shared/vgui_grid.h b/game_shared/vgui_grid.h index 4c3a562..34d1064 100644 --- a/game_shared/vgui_grid.h +++ b/game_shared/vgui_grid.h @@ -12,7 +12,7 @@ #endif -#include "vgui_panel.h" +#include "VGUI_Panel.h" namespace vgui diff --git a/game_shared/vgui_helpers.h b/game_shared/vgui_helpers.h index 6ac46cf..2848b42 100644 --- a/game_shared/vgui_helpers.h +++ b/game_shared/vgui_helpers.h @@ -12,8 +12,8 @@ #endif -#include "vgui_panel.h" -#include "vgui_label.h" +#include "VGUI_Panel.h" +#include "VGUI_Label.h" inline int PanelTop(vgui::Panel *pPanel) {int x,y,w,h; pPanel->getBounds(x,y,w,h); return y;} diff --git a/game_shared/vgui_listbox.h b/game_shared/vgui_listbox.h index 19c86dc..fed2d48 100644 --- a/game_shared/vgui_listbox.h +++ b/game_shared/vgui_listbox.h @@ -15,8 +15,8 @@ #include "VGUI_Panel.h" #include "VGUI_IntChangeSignal.h" -#include "VGUI_Slider2.h" -#include "VGUI_ScrollBar2.h" +#include "vgui_slider2.h" +#include "vgui_scrollbar2.h" namespace vgui diff --git a/game_shared/vgui_loadtga.cpp b/game_shared/vgui_loadtga.cpp index 6c403d6..55b12ce 100644 --- a/game_shared/vgui_loadtga.cpp +++ b/game_shared/vgui_loadtga.cpp @@ -7,9 +7,9 @@ #include "wrect.h" #include "../cl_dll/cl_dll.h" -#include "vgui.h" +#include "VGUI.h" #include "vgui_loadtga.h" -#include "vgui_inputstream.h" +#include "VGUI_InputStream.h" // ---------------------------------------------------------------------- // diff --git a/game_shared/vgui_loadtga.h b/game_shared/vgui_loadtga.h index da85b5e..e62174b 100644 --- a/game_shared/vgui_loadtga.h +++ b/game_shared/vgui_loadtga.h @@ -12,7 +12,7 @@ #endif -#include "vgui_bitmaptga.h" +#include "VGUI_BitmapTGA.h" vgui::BitmapTGA* vgui_LoadTGA(char const *pFilename); diff --git a/game_shared/vgui_scrollbar2.cpp b/game_shared/vgui_scrollbar2.cpp index a18e804..2421cc0 100644 --- a/game_shared/vgui_scrollbar2.cpp +++ b/game_shared/vgui_scrollbar2.cpp @@ -6,8 +6,8 @@ //============================================================================= -#include "VGUI_ScrollBar2.h" -#include "VGUI_Slider2.h" +#include "vgui_scrollbar2.h" +#include "vgui_slider2.h" #include "vgui_loadtga.h" #include diff --git a/game_shared/vgui_slider2.cpp b/game_shared/vgui_slider2.cpp index 5e42fc7..1b3381e 100644 --- a/game_shared/vgui_slider2.cpp +++ b/game_shared/vgui_slider2.cpp @@ -5,7 +5,7 @@ // $NoKeywords: $ //============================================================================= -#include "VGUI_Slider2.h" +#include "vgui_slider2.h" #include #include diff --git a/game_shared/virtualfs.h b/game_shared/virtualfs.h index fba824f..5b6331f 100644 --- a/game_shared/virtualfs.h +++ b/game_shared/virtualfs.h @@ -6,7 +6,7 @@ #define VIRTUALFS_H #include - +#include #define FS_MEM_BLOCK 65535 #define FS_MSG_BLOCK 8192 @@ -169,7 +169,7 @@ _forceinline size_t CVirtualFS :: IPrint( const char *message ) return Insert( message, Q_strlen( message )); } -_forceinline size_t CVirtualFS :: Printf( const char *fmt, ... ) +size_t CVirtualFS :: Printf( const char *fmt, ... ) { size_t result; va_list args; @@ -181,7 +181,7 @@ _forceinline size_t CVirtualFS :: Printf( const char *fmt, ... ) return result; } -_forceinline size_t CVirtualFS :: IPrintf( const char *fmt, ... ) +size_t CVirtualFS :: IPrintf( const char *fmt, ... ) { size_t result; va_list args; diff --git a/game_shared/voice_status.cpp b/game_shared/voice_status.cpp index b065fcc..4d1d7fa 100644 --- a/game_shared/voice_status.cpp +++ b/game_shared/voice_status.cpp @@ -44,7 +44,7 @@ #include "VGUI_TextImage.h" #include "vgui_loadtga.h" #include "vgui_helpers.h" -#include "vgui_mousecode.h" +#include "VGUI_MouseCode.h" @@ -97,7 +97,9 @@ int __MsgFunc_ReqState(const char *pszName, int iSize, void *pbuf) return 1; } - +// Q_strupr +//#include "stringlib.h" +// TODO: fix stringlib in client int g_BannedPlayerPrintCount; void ForEachBannedPlayer(char id[16]) { @@ -109,7 +111,7 @@ void ForEachBannedPlayer(char id[16]) id[8], id[9], id[10], id[11], id[12], id[13], id[14], id[15] ); - strupr(str); +// Q_strupr(str, str); gEngfuncs.pfnConsolePrint(str); } diff --git a/game_shared/voice_vgui_tweakdlg.cpp b/game_shared/voice_vgui_tweakdlg.cpp index bbe6809..3a2444b 100644 --- a/game_shared/voice_vgui_tweakdlg.cpp +++ b/game_shared/voice_vgui_tweakdlg.cpp @@ -7,17 +7,17 @@ #include "../cl_dll/hud.h" #include "../cl_dll/cl_util.h" -#include "../cl_dll/vgui_teamfortressviewport.h" +#include "../cl_dll/vgui_TeamFortressViewport.h" -#include "vgui_actionsignal.h" +#include "VGUI_ActionSignal.h" #include "voice_vgui_tweakdlg.h" #include "voice_vgui_tweakdlg.h" -#include "vgui_panel.h" -#include "vgui_scrollbar.h" -#include "vgui_slider.h" +#include "VGUI_Panel.h" +#include "VGUI_ScrollBar.h" +#include "VGUI_Slider.h" #include "ivoicetweak.h" -#include "vgui_button.h" +#include "VGUI_Button.h" #include "vgui_checkbutton2.h" #include "vgui_helpers.h" diff --git a/pm_shared/meshdesc.cpp b/pm_shared/meshdesc.cpp index 280acb1..313addd 100644 --- a/pm_shared/meshdesc.cpp +++ b/pm_shared/meshdesc.cpp @@ -13,8 +13,8 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. */ -#define WIN32_LEAN_AND_MEAN -#include "windows.h" +//#define WIN32_LEAN_AND_MEAN +//#include "windows.h" #include #include "vector.h" #include "matrix.h" @@ -36,7 +36,7 @@ GNU General Public License for more details. #endif #include "enginecallback.h" - +#include // placement CMeshDesc *UTIL_GetCollisionMesh( int modelindex ) { model_t *mod = (model_t *)MODEL_HANDLE( modelindex ); @@ -52,10 +52,10 @@ CMeshDesc *UTIL_GetCollisionMesh( int modelindex ) if( !mod->cache.data ) return NULL; - CMeshDesc *bodyMesh = (CMeshDesc *)Mem_Alloc( sizeof( CMeshDesc )); + CMeshDesc *bodyMesh = new (Mem_Alloc( sizeof( CMeshDesc )) ) CMeshDesc(); if( !bodyMesh ) return NULL; - bodyMesh->CMeshDesc::CMeshDesc(); +// bodyMesh->CMeshDesc(); bodyMesh->SetDebugName( mod->name ); bodyMesh->SetModel( mod ); @@ -932,7 +932,8 @@ bool CMeshDesc :: StudioConstructMesh( void ) static Vector4D q[MAXSTUDIOBONES]; int totalVertSize = 0; - for( int i = 0; i < phdr->numbones; i++, pbone++, panim++ ) + int i; + for( i = 0; i < phdr->numbones; i++, pbone++, panim++ ) { StudioCalcBoneTransform( 0, pbone, panim, pos[i], q[i] ); } @@ -1151,7 +1152,8 @@ bool CMeshDesc :: FinishMeshBuild( void ) return false; } - for( int i = 0; i < 3; i++ ) + int i; + for( i = 0; i < 3; i++ ) { // spread the mins / maxs by a pixel m_mesh.mins[i] -= 1.0f; diff --git a/pm_shared/pm_math.cpp b/pm_shared/pm_math.cpp.unused similarity index 99% rename from pm_shared/pm_math.cpp rename to pm_shared/pm_math.cpp.unused index 6868619..82d001c 100644 --- a/pm_shared/pm_math.cpp +++ b/pm_shared/pm_math.cpp.unused @@ -27,7 +27,7 @@ #pragma warning(disable : 4244) -vec3_t vec3_origin = {0,0,0}; +vec3_t vec3_origin = Vector(0,0,0); #ifndef VECTOR_H #define DotProduct(x,y) ((x)[0]*(y)[0]+(x)[1]*(y)[1]+(x)[2]*(y)[2]) diff --git a/pm_shared/trace.cpp b/pm_shared/trace.cpp index 0d5526e..612a617 100644 --- a/pm_shared/trace.cpp +++ b/pm_shared/trace.cpp @@ -13,8 +13,7 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. */ -#define WIN32_LEAN_AND_MEAN -#include "windows.h" +//#include "windows.h" #include #include "vector.h" #include "matrix.h" diff --git a/scripts/waifulib/library_naming.pyc b/scripts/waifulib/library_naming.pyc deleted file mode 100644 index 7857556..0000000 Binary files a/scripts/waifulib/library_naming.pyc and /dev/null differ diff --git a/scripts/waifulib/xcompile.pyc b/scripts/waifulib/xcompile.pyc deleted file mode 100644 index 675e2c5..0000000 Binary files a/scripts/waifulib/xcompile.pyc and /dev/null differ diff --git a/wscript b/wscript index 13167ce..c515ac7 100644 --- a/wscript +++ b/wscript @@ -179,6 +179,12 @@ def configure(conf): '-Werror=bool-compare', '-Werror=bool-operation', '-Wstrict-aliasing', + '-Wno-attributes', + '-Wno-missing-pragmas', + '-Wno-overloaded-virtual', + '-Wno-unknown-pragmas', + '-Wno-write-strings', + '-std=gnu++98' ] c_compiler_optional_flags = [