diff --git a/docs/rh-log.txt b/docs/rh-log.txt index baba0c1d8..5cf630cb7 100644 --- a/docs/rh-log.txt +++ b/docs/rh-log.txt @@ -1,4 +1,16 @@ -May 14, 2009 (Changes by Graf Zahl) +May 15, 2009 (Changes by Graf Zahl) +- Changed APlayerPawn::DamageFade to a PalEntry from 3 floats. +- Removed #pragma warnings from cmdlib.h and fixed the places where they were + still triggered. + These #pragmas were responsible for >90% of the GCC warnings that were not + listed in VC++. +- Fixed one bug in the process: DSeqNode::m_Atten was never adjusted when the + parameter handling of the sound functions for attenuation was changed. + Changed m_Atten to a float and fixed the SNDSEQ parser to set proper values. + Also added the option to specify attenuation with direct values in addition + to the predefined names. + +May 14, 2009 (Changes by Graf Zahl) - fixed a few Heretic actors: * The pod generator's attacksound was wrong * The teleglitter generators need different flags if they are supposed to work diff --git a/src/c_cmds.cpp b/src/c_cmds.cpp index 15c918d33..3eb49c261 100644 --- a/src/c_cmds.cpp +++ b/src/c_cmds.cpp @@ -623,7 +623,7 @@ CCMD (r_visibility) } else if (!netgame) { - R_SetVisibility (atof (argv[1])); + R_SetVisibility ((float)atof (argv[1])); } else { diff --git a/src/c_console.cpp b/src/c_console.cpp index 07f05fa32..f1552d7ba 100644 --- a/src/c_console.cpp +++ b/src/c_console.cpp @@ -620,7 +620,7 @@ static int FlushLines (const char *start, const char *stop) return i; } -static void AddLine (const char *text, bool more, int len) +static void AddLine (const char *text, bool more, size_t len) { if (BufferRover + len + 1 - ConsoleBuffer > CONSOLESIZE) { @@ -1401,7 +1401,7 @@ static bool C_HandleKey (event_t *ev, BYTE *buffer, int len) { if (buffer[1] == buffer[0]) { - buffer[buffer[0] + 2] = ev->data1; + buffer[buffer[0] + 2] = BYTE(ev->data1); } else { @@ -1413,7 +1413,7 @@ static bool C_HandleKey (event_t *ev, BYTE *buffer, int len) for (; e >= c; e--) *(e + 1) = *e; - *c = ev->data1; + *c = char(ev->data1); } buffer[0]++; buffer[1]++; diff --git a/src/c_cvars.cpp b/src/c_cvars.cpp index 244457027..d4e01128d 100644 --- a/src/c_cvars.cpp +++ b/src/c_cvars.cpp @@ -242,7 +242,7 @@ float FBaseCVar::ToFloat (UCVarValue value, ECVarType type) return value.Float; case CVAR_String: - return strtod (value.String, NULL); + return (float)strtod (value.String, NULL); case CVAR_GUID: return 0.f; @@ -498,8 +498,8 @@ UCVarValue FBaseCVar::FromString (const char *value, ECVarType type) if (i == 38 && value[i] == 0) { cGUID.Data1 = strtoul (value + 1, NULL, 16); - cGUID.Data2 = strtoul (value + 10, NULL, 16); - cGUID.Data3 = strtoul (value + 15, NULL, 16); + cGUID.Data2 = (WORD)strtoul (value + 10, NULL, 16); + cGUID.Data3 = (WORD)strtoul (value + 15, NULL, 16); cGUID.Data4[0] = HexToByte (value + 20); cGUID.Data4[1] = HexToByte (value + 22); cGUID.Data4[2] = HexToByte (value + 25); @@ -1288,7 +1288,7 @@ void C_BackupCVars (void) } cvar = cvar->m_Next; } - numbackedup = backup - CVarBackups; + numbackedup = int(backup - CVarBackups); } void C_RestoreCVars (void) diff --git a/src/c_dispatch.cpp b/src/c_dispatch.cpp index 3d9720d41..adb833357 100644 --- a/src/c_dispatch.cpp +++ b/src/c_dispatch.cpp @@ -543,7 +543,7 @@ void C_DoCommand (const char *cmd, int keynum) ; } - const int len = end - beg; + const size_t len = end - beg; if (ParsingKeyConf) { @@ -615,7 +615,7 @@ void C_DoCommand (const char *cmd, int keynum) } else { // Check for any console vars that match the command - FBaseCVar *var = FindCVarSub (beg, len); + FBaseCVar *var = FindCVarSub (beg, int(len)); if (var != NULL) { @@ -634,7 +634,7 @@ void C_DoCommand (const char *cmd, int keynum) else { // We don't know how to handle this command char cmdname[64]; - int minlen = MIN (len, 63); + size_t minlen = MIN (len, 63); memcpy (cmdname, beg, minlen); cmdname[len] = 0; @@ -801,7 +801,7 @@ static long ParseCommandLine (const char *args, int *argc, char **argv, bool no_ while (*args && *args > ' ' && *args != '\"') args++; - if (*start == '$' && (var = FindCVarSub (start+1, args-start-1))) + if (*start == '$' && (var = FindCVarSub (start+1, int(args-start-1)))) { val = var->GetGenericRep (CVAR_String); start = val.String; diff --git a/src/cmdlib.cpp b/src/cmdlib.cpp index 1ddba115f..e9924785d 100644 --- a/src/cmdlib.cpp +++ b/src/cmdlib.cpp @@ -498,7 +498,7 @@ int strbin (char *str) } } *str = 0; - return str - start; + return int(str - start); } // [RH] Replaces the escape sequences in a string with actual escaped characters. diff --git a/src/cmdlib.h b/src/cmdlib.h index 55b4a61e9..d42d2e5aa 100644 --- a/src/cmdlib.h +++ b/src/cmdlib.h @@ -3,14 +3,6 @@ #ifndef __CMDLIB__ #define __CMDLIB__ -#ifdef _MSC_VER -#pragma warning(disable : 4244) // MIPS -#pragma warning(disable : 4136) // X86 -#pragma warning(disable : 4051) // ALPHA - -#pragma warning(disable : 4018) // signed/unsigned mismatch -#pragma warning(disable : 4305) // truncate from double to float -#endif #include "doomtype.h" diff --git a/src/d_dehacked.cpp b/src/d_dehacked.cpp index 9df5935c2..8730444e5 100644 --- a/src/d_dehacked.cpp +++ b/src/d_dehacked.cpp @@ -641,7 +641,7 @@ static int PatchThing (int thingy) } else if (linelen == 11 && stricmp (Line1, "Pain chance") == 0) { - info->PainChance = val; + info->PainChance = (SWORD)val; } else if (linelen == 12 && stricmp (Line1, "Translucency") == 0) { @@ -882,7 +882,7 @@ static int PatchThing (int thingy) } else if (stricmp (Line1, "ID #") == 0) { - *ednum = val; + *ednum = (SWORD)val; } } else Printf (unknown_str, Line1, "Thing", thingy); diff --git a/src/d_net.cpp b/src/d_net.cpp index 8c45a5b33..74f10bb7c 100644 --- a/src/d_net.cpp +++ b/src/d_net.cpp @@ -353,7 +353,7 @@ int NetbufferSize () SkipTicCmd (&skipper, numtics); } } - return skipper - netbuffer; + return int(skipper - netbuffer); } // @@ -1232,7 +1232,7 @@ void NetUpdate (void) } } } - HSendPacket (i, cmddata - netbuffer); + HSendPacket (i, int(cmddata - netbuffer)); } else { @@ -1389,7 +1389,7 @@ bool DoArbitrate (void *userdata) netbuffer[9] = data->gotsetup[0]; stream = &netbuffer[10]; D_WriteUserInfoStrings (consoleplayer, &stream, true); - SendSetup (data->playersdetected, data->gotsetup, stream - netbuffer); + SendSetup (data->playersdetected, data->gotsetup, int(stream - netbuffer)); } else { // Send user info for all nodes @@ -1404,7 +1404,7 @@ bool DoArbitrate (void *userdata) netbuffer[1] = j; stream = &netbuffer[9]; D_WriteUserInfoStrings (j, &stream, true); - HSendPacket (i, stream - netbuffer); + HSendPacket (i, int(stream - netbuffer)); } } } @@ -1414,15 +1414,15 @@ bool DoArbitrate (void *userdata) if (consoleplayer == Net_Arbitrator) { netbuffer[0] = NCMD_SETUP+2; - netbuffer[1] = doomcom.ticdup; - netbuffer[2] = doomcom.extratics; + netbuffer[1] = (BYTE)doomcom.ticdup; + netbuffer[2] = (BYTE)doomcom.extratics; netbuffer[3] = NetMode; stream = &netbuffer[4]; WriteString (startmap, &stream); WriteLong (rngseed, &stream); C_WriteCVars (&stream, CVAR_SERVERINFO, true); - SendSetup (data->playersdetected, data->gotsetup, stream - netbuffer); + SendSetup (data->playersdetected, data->gotsetup, int(stream - netbuffer)); } return false; } @@ -1635,7 +1635,7 @@ void D_QuitNetGame (void) if (playeringame[i] && i != consoleplayer) WriteLong (resendto[nodeforplayer[i]], &foo); } - k = foo - netbuffer; + k = int(foo - netbuffer); } for (i = 0; i < 4; i++) diff --git a/src/d_player.h b/src/d_player.h index ba72c2d60..8a63c5789 100644 --- a/src/d_player.h +++ b/src/d_player.h @@ -132,9 +132,7 @@ public: fixed_t AttackZOffset; // attack height, relative to player center // [CW] Fades for when you are being damaged. - float RedDamageFade; - float GreenDamageFade; - float BlueDamageFade; + PalEntry DamageFade; bool UpdateWaterLevel (fixed_t oldz, bool splash); bool ResetAirSupply (bool playgasp = true); diff --git a/src/d_protocol.cpp b/src/d_protocol.cpp index 25008ca1e..3698e5696 100644 --- a/src/d_protocol.cpp +++ b/src/d_protocol.cpp @@ -194,7 +194,7 @@ int UnpackUserCmd (usercmd_t *ucmd, const usercmd_t *basis, BYTE **stream) ucmd->roll = ReadWord (stream); } - return *stream - start; + return int(*stream - start); } // Returns the number of bytes written @@ -284,7 +284,7 @@ int PackUserCmd (const usercmd_t *ucmd, const usercmd_t *basis, BYTE **stream) // Write the packing bits WriteByte (flags, &temp); - return *stream - start; + return int(*stream - start); } FArchive &operator<< (FArchive &arc, ticcmd_t &cmd) @@ -396,7 +396,7 @@ int SkipTicCmd (BYTE **stream, int count) } } - skip = flow - *stream; + skip = int(flow - *stream); *stream = flow; return skip; @@ -420,7 +420,7 @@ void ReadTicCmd (BYTE **stream, int player, int tic) while ((type = ReadByte (stream)) != DEM_USERCMD && type != DEM_EMPTYUSERCMD) Net_SkipCommand (type, stream); - NetSpecs[player][ticmod].SetData (start, *stream - start - 1); + NetSpecs[player][ticmod].SetData (start, int(*stream - start - 1)); if (type == DEM_USERCMD) { @@ -485,7 +485,7 @@ void FinishChunk (BYTE **stream) if (!lenspot) return; - len = *stream - lenspot - 4; + len = int(*stream - lenspot - 4); WriteLong (len, &lenspot); if (len & 1) WriteByte (0, stream); diff --git a/src/g_game.cpp b/src/g_game.cpp index 35aca1b1f..2f37e292b 100644 --- a/src/g_game.cpp +++ b/src/g_game.cpp @@ -748,7 +748,7 @@ static void ChangeSpy (bool forward) // Otherwise, cycle to the next player. bool checkTeam = !demoplayback && deathmatch; - int pnum = players[consoleplayer].camera->player - players; + int pnum = int(players[consoleplayer].camera->player - players); int step = forward ? 1 : -1; do @@ -2348,7 +2348,7 @@ bool G_ProcessIFFDemo (char *mapname) if (uncompSize > 0) { BYTE *uncompressed = new BYTE[uncompSize]; - int r = uncompress (uncompressed, &uncompSize, demo_p, zdembodyend - demo_p); + int r = uncompress (uncompressed, &uncompSize, demo_p, uLong(zdembodyend - demo_p)); if (r != Z_OK) { Printf ("Could not decompress demo!\n"); @@ -2522,7 +2522,7 @@ bool G_CheckDemoStatus (void) // a compressed version. If the BODY successfully compresses, the // contents of the COMP chunk will be changed to indicate the // uncompressed size of the BODY. - uLong len = demo_p - demobodyspot; + uLong len = uLong(demo_p - demobodyspot); uLong outlen = (len + len/100 + 12); Byte *compressed = new Byte[outlen]; int r = compress2 (compressed, &outlen, demobodyspot, len, 9); @@ -2537,9 +2537,9 @@ bool G_CheckDemoStatus (void) } FinishChunk (&demo_p); formlen = demobuffer + 4; - WriteLong (demo_p - demobuffer - 8, &formlen); + WriteLong (int(demo_p - demobuffer - 8), &formlen); - M_WriteFile (demoname, demobuffer, demo_p - demobuffer); + M_WriteFile (demoname, demobuffer, int(demo_p - demobuffer)); M_Free (demobuffer); demorecording = false; stoprecording = false; diff --git a/src/g_mapinfo.cpp b/src/g_mapinfo.cpp index 3bfb45c05..6f01aa73f 100644 --- a/src/g_mapinfo.cpp +++ b/src/g_mapinfo.cpp @@ -973,7 +973,7 @@ DEFINE_MAP_OPTION(sky1, true) { parse.sc.Float /= 256; } - info->skyspeed1 = parse.sc.Float * (35.f / 1000.f); + info->skyspeed1 = float(parse.sc.Float * (35. / 1000.)); } } @@ -987,7 +987,7 @@ DEFINE_MAP_OPTION(sky2, true) { parse.sc.Float /= 256; } - info->skyspeed2 = parse.sc.Float * (35.f / 1000.f); + info->skyspeed2 = float(parse.sc.Float * (35. / 1000.)); } } @@ -1096,14 +1096,14 @@ DEFINE_MAP_OPTION(gravity, true) { parse.ParseAssign(); parse.sc.MustGetFloat(); - info->gravity = parse.sc.Float; + info->gravity = float(parse.sc.Float); } DEFINE_MAP_OPTION(aircontrol, true) { parse.ParseAssign(); parse.sc.MustGetFloat(); - info->aircontrol = parse.sc.Float; + info->aircontrol = float(parse.sc.Float); } DEFINE_MAP_OPTION(airsupply, true) @@ -1212,7 +1212,7 @@ DEFINE_MAP_OPTION(teamdamage, true) { parse.ParseAssign(); parse.sc.MustGetFloat(); - info->teamdamage = parse.sc.Float; + info->teamdamage = float(parse.sc.Float); } DEFINE_MAP_OPTION(mapbackground, true) diff --git a/src/g_shared/shared_sbar.cpp b/src/g_shared/shared_sbar.cpp index 60fd77914..3fe74c7c1 100644 --- a/src/g_shared/shared_sbar.cpp +++ b/src/g_shared/shared_sbar.cpp @@ -1481,7 +1481,7 @@ void DBaseStatusBar::BlendView (float blend[4]) cnt = 228; APlayerPawn *mo = players[consoleplayer].mo; - AddBlend (mo->RedDamageFade / 255, mo->GreenDamageFade / 255, mo->BlueDamageFade / 255, cnt / 255.f, blend); + AddBlend (mo->DamageFade.r / 255.f, mo->DamageFade.g / 255.f, mo->DamageFade.b / 255.f, cnt / 255.f, blend); } // Unlike Doom, I did not have any utility source to look at to find the diff --git a/src/m_options.cpp b/src/m_options.cpp index 6e491b2c2..02d5fd822 100644 --- a/src/m_options.cpp +++ b/src/m_options.cpp @@ -255,14 +255,14 @@ static menuitem_t MouseItems[] = { { discrete, "Enable mouse", {&use_mouse}, {2.0}, {0.0}, {0.0}, {YesNo} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, - { slider, "Overall sensitivity", {&mouse_sensitivity}, {0.5}, {2.5}, {0.1}, {NULL} }, + { slider, "Overall sensitivity", {&mouse_sensitivity}, {0.5}, {2.5}, {0.1f}, {NULL} }, { discrete, "Prescale mouse movement",{&m_noprescale}, {2.0}, {0.0}, {0.0}, {NoYes} }, { discrete, "Smooth mouse movement",{&smooth_mouse}, {2.0}, {0.0}, {0.0}, {YesNo} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, - { slider, "Turning speed", {&m_yaw}, {0.5}, {2.5}, {0.1}, {NULL} }, - { slider, "Mouselook speed", {&m_pitch}, {0.5}, {2.5}, {0.1}, {NULL} }, - { slider, "Forward/Backward speed",{&m_forward}, {0.5}, {2.5}, {0.1}, {NULL} }, - { slider, "Strafing speed", {&m_side}, {0.5}, {2.5}, {0.1}, {NULL} }, + { slider, "Turning speed", {&m_yaw}, {0.5}, {2.5}, {0.1f}, {NULL} }, + { slider, "Mouselook speed", {&m_pitch}, {0.5}, {2.5}, {0.1f}, {NULL} }, + { slider, "Forward/Backward speed",{&m_forward}, {0.5}, {2.5}, {0.1f}, {NULL} }, + { slider, "Strafing speed", {&m_side}, {0.5}, {2.5}, {0.1f}, {NULL} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, { discrete, "Always Mouselook", {&freelook}, {2.0}, {0.0}, {0.0}, {OnOff} }, { discrete, "Invert Mouse", {&invertmouse}, {2.0}, {0.0}, {0.0}, {OnOff} }, @@ -330,7 +330,7 @@ static menuitem_t JoystickItems[] = { { discrete, "Enable joystick", {&use_joystick}, {2.0}, {0.0}, {0.0}, {YesNo} }, { discrete_guid,"Active joystick", {&joy_guid}, {0.0}, {0.0}, {0.0}, {NULL} }, - { slider, "Overall sensitivity", {&joy_speedmultiplier}, {0.9}, {2.0}, {0.2}, {NULL} }, + { slider, "Overall sensitivity", {&joy_speedmultiplier}, {0.9f}, {2.0}, {0.2f}, {NULL} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, { whitetext,"Axis Assignments", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, @@ -519,7 +519,7 @@ static menuitem_t VideoItems[] = { { more, "Scoreboard Options", {NULL}, {0.0}, {0.0}, {0.0}, {(value_t *)StartScoreboardMenu} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, { slider, "Screen size", {&screenblocks}, {3.0}, {12.0}, {1.0}, {NULL} }, - { slider, "Brightness", {&Gamma}, {1.0}, {3.0}, {0.1}, {NULL} }, + { slider, "Brightness", {&Gamma}, {1.0}, {3.0}, {0.1f}, {NULL} }, { discretes,"Crosshair", {&crosshair}, {8.0}, {0.0}, {0.0}, {NULL} }, { discrete, "Column render mode", {&r_columnmethod}, {2.0}, {0.0}, {0.0}, {ColumnMethods} }, { discrete, "Stretch short skies", {&r_stretchsky}, {2.0}, {0.0}, {0.0}, {OnOff} }, @@ -1030,7 +1030,7 @@ value_t DF_Crouch[3] = { static menuitem_t DMFlagsItems[] = { { discrete, "Teamplay", {&teamplay}, {2.0}, {0.0}, {0.0}, {OnOff} }, - { slider, "Team damage scalar", {&teamdamage}, {0.0}, {1.0}, {0.05},{NULL} }, + { slider, "Team damage scalar", {&teamdamage}, {0.0}, {1.0}, {0.05f},{NULL} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, { discrete, "Smart Autoaim", {&sv_smartaim}, {4.0}, {0.0}, {0.0}, {SmartAim} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, @@ -1260,8 +1260,8 @@ static valueenum_t Resamplers[] = static menuitem_t SoundItems[] = { - { slider, "Sounds volume", {&snd_sfxvolume}, {0.0}, {1.0}, {0.05}, {NULL} }, - { slider, "Music volume", {&snd_musicvolume}, {0.0}, {1.0}, {0.05}, {NULL} }, + { slider, "Sounds volume", {&snd_sfxvolume}, {0.0}, {1.0}, {0.05f}, {NULL} }, + { slider, "Music volume", {&snd_musicvolume}, {0.0}, {1.0}, {0.05f}, {NULL} }, { discrete, "MIDI device", {&snd_mididevice}, {0.0}, {0.0}, {0.0}, {NULL} }, { redtext, " ", {NULL}, {0.0}, {0.0}, {0.0}, {NULL} }, { discrete, "Underwater reverb", {&snd_waterreverb}, {2.0}, {0.0}, {0.0}, {OnOff} }, @@ -1797,7 +1797,7 @@ void M_OptDrawer () int v, vals; value = item->a.cvar->GetGenericRep (CVAR_Int); - value.Float = value.Int & int(item->c.max); + value.Float = float(value.Int & int(item->c.max)); vals = (int)item->b.numvalues; v = M_FindCurVal (value.Float, item->e.values, vals); @@ -2380,7 +2380,7 @@ void M_OptResponder (event_t *ev) numvals = (int)item->b.min; value = item->a.cvar->GetGenericRep (CVAR_Int); - cur = M_FindCurVal (value.Int & bmask, item->e.values, numvals); + cur = M_FindCurVal (float(value.Int & bmask), item->e.values, numvals); if (--cur < 0) cur = numvals - 1; @@ -2529,7 +2529,7 @@ void M_OptResponder (event_t *ev) numvals = (int)item->b.min; value = item->a.cvar->GetGenericRep (CVAR_Int); - cur = M_FindCurVal (value.Int & bmask, item->e.values, numvals); + cur = M_FindCurVal (float(value.Int & bmask), item->e.values, numvals); if (++cur >= numvals) cur = 0; @@ -2871,9 +2871,9 @@ static void ColorPickerDrawer () static void SetColorPickerSliders () { FColorCVar *cvar = ColorPickerItems[0].a.colorcvar; - ColorPickerItems[2].a.fval = RPART(DWORD(*cvar)); - ColorPickerItems[3].a.fval = GPART(DWORD(*cvar)); - ColorPickerItems[4].a.fval = BPART(DWORD(*cvar)); + ColorPickerItems[2].a.fval = float(RPART(DWORD(*cvar))); + ColorPickerItems[3].a.fval = float(GPART(DWORD(*cvar))); + ColorPickerItems[4].a.fval = float(BPART(DWORD(*cvar))); CurrColorIndex = cvar->GetIndex(); } @@ -3029,7 +3029,7 @@ void UpdateJoystickMenu () JoystickItems[line].a.cvar = cvars2[i]; JoystickItems[line].b.min = 0.0; JoystickItems[line].c.max = 4.0; - JoystickItems[line].d.step = 0.2; + JoystickItems[line].d.step = 0.2f; line++; JoystickItems[line].type = inverter; @@ -3055,8 +3055,8 @@ void UpdateJoystickMenu () JoystickItems[line].type = slider; JoystickItems[line].a.cvar = cvars3[i]; JoystickItems[line].b.min = 0.0; - JoystickItems[line].c.max = 0.9; - JoystickItems[line].d.step = 0.05; + JoystickItems[line].c.max = 0.9f; + JoystickItems[line].d.step = 0.05f; line++; } } diff --git a/src/p_acs.cpp b/src/p_acs.cpp index a8fcbd9b2..de71852f7 100644 --- a/src/p_acs.cpp +++ b/src/p_acs.cpp @@ -1435,7 +1435,7 @@ void FBehavior::LoadScriptsDirectory () ScriptPtr *ptr2 = &Scripts[i]; ptr2->Number = LittleShort(ptr1->Number); - ptr2->Type = LittleShort(ptr1->Type); + ptr2->Type = BYTE(LittleShort(ptr1->Type)); ptr2->ArgCount = LittleLong(ptr1->ArgCount); ptr2->Address = LittleLong(ptr1->Address); } @@ -3275,7 +3275,7 @@ int DLevelScript::RunScript () } sp -= sizeof(CallReturn)/sizeof(int); retsp = &Stack[sp]; - sp = locals - Stack; + sp = int(locals - Stack); pc = ret->ReturnModule->Ofs2PC(ret->ReturnAddress); activeFunction = ret->ReturnFunction; activeBehavior = ret->ReturnModule; @@ -5493,7 +5493,7 @@ int DLevelScript::RunScript () } else { - PushToStack (activator->player - players); + PushToStack (int(activator->player - players)); } break; @@ -6181,7 +6181,7 @@ static void addDefered (level_info_t *i, acsdefered_t::EType type, int script, i def->arg2 = arg2; if (who != NULL && who->player != NULL) { - def->playernum = who->player - players; + def->playernum = int(who->player - players); } else { diff --git a/src/p_doors.cpp b/src/p_doors.cpp index 7401e3d1b..1166d47f0 100644 --- a/src/p_doors.cpp +++ b/src/p_doors.cpp @@ -391,7 +391,7 @@ bool EV_DoDoor (DDoor::EVlDoor type, line_t *line, AActor *thing, // get the sector on the second side of activating linedef sec = sides[line->sidenum[1]].sector; - secnum = sec-sectors; + secnum = int(sec-sectors); // if door already has a thinker, use it if (sec->ceilingdata) diff --git a/src/p_mobj.cpp b/src/p_mobj.cpp index 50368f48c..eb4036925 100644 --- a/src/p_mobj.cpp +++ b/src/p_mobj.cpp @@ -289,12 +289,8 @@ void AActor::Serialize (FArchive &arc) << master << smokecounter << BlockingMobj - << BlockingLine; - - if (SaveVersion >= 1573) - { - arc << Species; - } + << BlockingLine + << Species; if (arc.IsStoring ()) { diff --git a/src/p_saveg.cpp b/src/p_saveg.cpp index ca443b3df..15f3e7fcf 100644 --- a/src/p_saveg.cpp +++ b/src/p_saveg.cpp @@ -381,9 +381,8 @@ void P_SerializeWorld (FArchive &arc) << si->Light << si->Flags << si->LeftSide - << si->RightSide; - if (SaveVersion >= 1575) - arc << si->Index; + << si->RightSide + << si->Index; DBaseDecal::SerializeChain (arc, &si->AttachedDecals); } } diff --git a/src/p_setup.cpp b/src/p_setup.cpp index 85a6fee5b..816c153e0 100644 --- a/src/p_setup.cpp +++ b/src/p_setup.cpp @@ -1318,7 +1318,7 @@ void P_LoadSectors (MapData * map) ss->ceilingplane.ic = -FRACUNIT; SetTexture(ss, i, sector_t::floor, ms->floorpic); SetTexture(ss, i, sector_t::ceiling, ms->ceilingpic); - ss->lightlevel = clamp (LittleShort(ms->lightlevel), (short)0, (short)255); + ss->lightlevel = (BYTE)clamp (LittleShort(ms->lightlevel), (short)0, (short)255); if (map->HasBehavior) ss->special = LittleShort(ms->special); else // [RH] Translate to new sector special @@ -1743,7 +1743,7 @@ void P_FinishLoadingLineDef(line_t *ld, int alpha) ld->backsector = ld->sidenum[1]!=NO_SIDE ? sides[ld->sidenum[1]].sector : 0; float dx = FIXED2FLOAT(ld->v2->x - ld->v1->x); float dy = FIXED2FLOAT(ld->v2->y - ld->v1->y); - int linenum = ld-lines; + int linenum = int(ld-lines); if (ld->frontsector == NULL) { @@ -2058,7 +2058,7 @@ static void P_LoopSidedefs () // as their left edge. line_t *line = &lines[sides[i].linenum]; int lineside = (line->sidenum[0] != (DWORD)i); - int vert = (lineside ? line->v2 : line->v1) - vertexes; + int vert = int((lineside ? line->v2 : line->v1) - vertexes); sidetemp[i].b.lineside = lineside; sidetemp[i].b.next = sidetemp[vert].b.first; @@ -2088,18 +2088,18 @@ static void P_LoopSidedefs () { if (sidetemp[i].b.lineside) { - right = line->v1 - vertexes; + right = int(line->v1 - vertexes); } else { - right = line->v2 - vertexes; + right = int(line->v2 - vertexes); } right = sidetemp[right].b.first; if (right == NO_SIDE) { // There is no right side! - Printf ("Line %d's right edge is unconnected\n", linemap[line-lines]); + Printf ("Line %d's right edge is unconnected\n", linemap[unsigned(line-lines)]); continue; } diff --git a/src/p_slopes.cpp b/src/p_slopes.cpp index 0859b5f95..9375b3667 100644 --- a/src/p_slopes.cpp +++ b/src/p_slopes.cpp @@ -315,10 +315,10 @@ static void P_SetSlopesFromVertexHeights(FMapThing *firstmt, FMapThing *lastmt) FVector3 vec1, vec2; int vi1, vi2, vi3; - vi1 = sec->lines[0]->v1 - vertexes; - vi2 = sec->lines[0]->v2 - vertexes; + vi1 = int(sec->lines[0]->v1 - vertexes); + vi2 = int(sec->lines[0]->v2 - vertexes); vi3 = (sec->lines[1]->v1 == sec->lines[0]->v1 || sec->lines[1]->v1 == sec->lines[0]->v2)? - sec->lines[1]->v2 - vertexes : sec->lines[1]->v1 - vertexes; + int(sec->lines[1]->v2 - vertexes) : int(sec->lines[1]->v1 - vertexes); vt1.X = FIXED2FLOAT(vertexes[vi1].x); vt1.Y = FIXED2FLOAT(vertexes[vi1].y); diff --git a/src/p_switch.cpp b/src/p_switch.cpp index a011df11e..584e893c8 100644 --- a/src/p_switch.cpp +++ b/src/p_switch.cpp @@ -629,7 +629,7 @@ void DActiveButton::Serialize (FArchive &arc) Super::Serialize (arc); if (arc.IsStoring ()) { - sidenum = m_Side ? m_Side - sides : -1; + sidenum = m_Side ? SDWORD(m_Side - sides) : -1; } arc << sidenum << m_Part << m_SwitchDef << m_Frame << m_Timer << bFlippable << m_X << m_Y; if (arc.IsLoading ()) diff --git a/src/p_terrain.cpp b/src/p_terrain.cpp index 595e95976..dbb187530 100644 --- a/src/p_terrain.cpp +++ b/src/p_terrain.cpp @@ -626,7 +626,7 @@ static void GenericParse (FScanner &sc, FGenericParse *parser, const char **keyw case GEN_Float: sc.MustGetFloat (); - SET_FIELD (float, sc.Float); + SET_FIELD (float, float(sc.Float)); break; case GEN_Time: diff --git a/src/p_user.cpp b/src/p_user.cpp index 647c1e982..e1149b002 100644 --- a/src/p_user.cpp +++ b/src/p_user.cpp @@ -424,9 +424,7 @@ void APlayerPawn::Serialize (FArchive &arc) << InvFirst << InvSel << MorphWeapon - << RedDamageFade - << GreenDamageFade - << BlueDamageFade; + << DamageFade; } //=========================================================================== diff --git a/src/r_anim.cpp b/src/r_anim.cpp index b20f1cd8d..f3a9d67db 100644 --- a/src/r_anim.cpp +++ b/src/r_anim.cpp @@ -344,7 +344,7 @@ static void R_InitAnimDefs () if (sc.CheckFloat()) { - static_cast(warper)->SetSpeed(sc.Float); + static_cast(warper)->SetSpeed(float(sc.Float)); } // No decals on warping textures, by default. diff --git a/src/r_plane.cpp b/src/r_plane.cpp index 13221b9e5..c67dbe288 100644 --- a/src/r_plane.cpp +++ b/src/r_plane.cpp @@ -57,6 +57,10 @@ #include "r_segs.h" #include "v_palette.h" +#ifdef _MSC_VER +#pragma warning(disable:4244) +#endif + //EXTERN_CVAR (Int, tx) //EXTERN_CVAR (Int, ty) diff --git a/src/r_things.cpp b/src/r_things.cpp index ef300d422..765e7a20e 100644 --- a/src/r_things.cpp +++ b/src/r_things.cpp @@ -2284,7 +2284,7 @@ void R_FindParticleSubsectors () for (WORD i = ActiveParticles; i != NO_PARTICLE; i = Particles[i].tnext) { subsector_t *ssec = R_PointInSubsector (Particles[i].x, Particles[i].y); - int ssnum = ssec-subsectors; + int ssnum = int(ssec-subsectors); Particles[i].subsector = ssec; Particles[i].snext = ParticlesInSubsec[ssnum]; ParticlesInSubsec[ssnum] = i; diff --git a/src/resourcefiles/file_7z.cpp b/src/resourcefiles/file_7z.cpp index bb340970c..46f55f844 100644 --- a/src/resourcefiles/file_7z.cpp +++ b/src/resourcefiles/file_7z.cpp @@ -283,7 +283,7 @@ bool F7ZFile::Open() strlwr(name); lump_p->LumpNameSetup(name); - lump_p->LumpSize = file->Size; + lump_p->LumpSize = int(file->Size); lump_p->Owner = this; lump_p->Flags = LUMPF_ZIPFILE; lump_p->Position = i; diff --git a/src/resourcefiles/file_zip.cpp b/src/resourcefiles/file_zip.cpp index a37ae2890..cef452557 100644 --- a/src/resourcefiles/file_zip.cpp +++ b/src/resourcefiles/file_zip.cpp @@ -256,7 +256,7 @@ bool FZipFile::Open() lump_p->Owner = this; // The start of the Reader will be determined the first time it is accessed. lump_p->Flags = LUMPF_ZIPFILE | LUMPFZIP_NEEDFILESTART; - lump_p->Method = zip_fh->Method; + lump_p->Method = BYTE(zip_fh->Method); lump_p->GPFlags = zip_fh->Flags; lump_p->CompressedSize = LittleLong(zip_fh->CompressedSize); lump_p->Position = LittleLong(zip_fh->LocalHeaderOffset); diff --git a/src/s_advsound.cpp b/src/s_advsound.cpp index 1f09e277f..31d2d94f2 100644 --- a/src/s_advsound.cpp +++ b/src/s_advsound.cpp @@ -1005,7 +1005,7 @@ static void S_AddSNDINFO (int lump) if (IsFloat (sc.String)) { - attenuation = atof (sc.String); + attenuation = (float)atof (sc.String); sc.MustGetString (); if (attenuation > 0) { @@ -1059,7 +1059,7 @@ static void S_AddSNDINFO (int lump) } sc.MustGetFloat (); - ambient->volume = sc.Float; + ambient->volume = (float)sc.Float; if (ambient->volume > 1) ambient->volume = 1; else if (ambient->volume < 0) @@ -1168,7 +1168,7 @@ static void S_AddSNDINFO (int lump) S_sfx[sfx].NearLimit = MIN(MAX(sc.Number, 0), 255); if (sc.CheckFloat()) { - S_sfx[sfx].LimitRange = sc.Float * sc.Float; + S_sfx[sfx].LimitRange = float(sc.Float * sc.Float); } } break; @@ -1207,7 +1207,7 @@ static void S_AddSNDINFO (int lump) sc.MustGetString(); sfx = S_FindSoundTentative(sc.String); sc.MustGetFloat(); - S_sfx[sfx].Volume = sc.Float; + S_sfx[sfx].Volume = (float)sc.Float; } break; @@ -1251,9 +1251,9 @@ static void S_AddSNDINFO (int lump) } sc.MustGetFloat(); } - rolloff->MinDistance = sc.Float; + rolloff->MinDistance = (float)sc.Float; sc.MustGetFloat(); - rolloff->MaxDistance = sc.Float; + rolloff->MaxDistance = (float)sc.Float; break; } @@ -1297,7 +1297,7 @@ static void S_AddSNDINFO (int lump) FString musname (sc.String); sc.MustGetFloat(); FMusicVolume *mv = (FMusicVolume *)M_Malloc (sizeof(*mv) + musname.Len()); - mv->Volume = sc.Float; + mv->Volume = (float)sc.Float; strcpy (mv->MusicName, musname); mv->Next = MusicVolumes; MusicVolumes = mv; diff --git a/src/s_environment.cpp b/src/s_environment.cpp index 03bad0e3d..d59d1c043 100644 --- a/src/s_environment.cpp +++ b/src/s_environment.cpp @@ -506,7 +506,7 @@ static void ReadReverbDef (int lump) if (ReverbFields[i].Float) { sc.MustGetFloat (); - props.*ReverbFields[i].Float = clamp (sc.Float, + props.*ReverbFields[i].Float = (float)clamp (sc.Float, double(ReverbFields[i].Min)/1000, double(ReverbFields[i].Max)/1000); } diff --git a/src/s_sndseq.cpp b/src/s_sndseq.cpp index 98f16d34b..ecfed1246 100644 --- a/src/s_sndseq.cpp +++ b/src/s_sndseq.cpp @@ -236,14 +236,22 @@ static const char *SSStrings[] = { "environment", NULL }; -static const char *Attenuations[] = { - "none", - "normal", - "idle", - "static", - "surround", - NULL + +struct SSAttenuation +{ + const char *name; + float value; }; + +static const SSAttenuation Attenuations[] = { + { "none", ATTN_NONE }, + { "normal", ATTN_NORM }, + { "idle", ATTN_IDLE }, + { "static", ATTN_STATIC }, + { "surround", ATTN_NONE }, + { NULL, 0} +}; + static const hexenseq_t HexenSequences[] = { { NAME_Platform, { HexenPlatSeq(0), HexenPlatSeq(1), HexenPlatSeq(3), HexenLastSeq } }, { NAME_PlatformMetal, { HexenPlatSeq(2), HexenLastSeq } }, @@ -294,7 +302,7 @@ void DSeqNode::Serialize (FArchive &arc) Super::Serialize (arc); if (arc.IsStoring ()) { - seqOffset = SN_GetSequenceOffset (m_Sequence, m_SequencePtr); + seqOffset = (int)SN_GetSequenceOffset (m_Sequence, m_SequencePtr); arc << seqOffset << m_DelayUntilTic << m_Volume @@ -319,7 +327,7 @@ void DSeqNode::Serialize (FArchive &arc) int delayTics = 0; FSoundID id; float volume; - int atten = ATTN_NORM; + float atten = ATTN_NORM; int seqnum; unsigned int numchoices; @@ -510,6 +518,7 @@ void S_ParseSndSeq (int levellump) int delaybase; float volumebase; int curseq = -1; + fixed_t val; // First free the old SNDSEQ data. This allows us to reload this for each level // and specify a level specific SNDSEQ lump! @@ -662,7 +671,7 @@ void S_ParseSndSeq (int levellump) case SS_STRING_VOLUMERAND: sc.MustGetFloat (); - volumebase = sc.Float; + volumebase = float(sc.Float); ScriptTemp.Push(MakeCommand(SS_CMD_VOLUMERAND, int(sc.Float * (FRACUNIT/100.f)))); sc.MustGetFloat (); ScriptTemp.Push(int((sc.Float - volumebase) * (256/100.f))); @@ -680,8 +689,16 @@ void S_ParseSndSeq (int levellump) break; case SS_STRING_ATTENUATION: - sc.MustGetString (); - ScriptTemp.Push(MakeCommand(SS_CMD_ATTENUATION, sc.MustMatchString(Attenuations))); + if (sc.CheckFloat()) + { + val = FLOAT2FIXED(sc.Float); + } + else + { + sc.MustGetString (); + val = sc.MustMatchString(&Attenuations[0].name, sizeof(Attenuations[0])) << FRACBITS; + } + ScriptTemp.Push(MakeCommand(SS_CMD_ATTENUATION, val)); break; case SS_STRING_RANDOMSEQUENCE: @@ -1143,7 +1160,7 @@ void DSeqNode::Tick () return; case SS_CMD_ATTENUATION: - m_Atten = GetData(*m_SequencePtr); + m_Atten = FIXED2FLOAT(GetData(*m_SequencePtr)); m_SequencePtr++; break; diff --git a/src/s_sndseq.h b/src/s_sndseq.h index b80e3e817..e54010075 100644 --- a/src/s_sndseq.h +++ b/src/s_sndseq.h @@ -50,7 +50,7 @@ protected: int m_StopSound; int m_DelayUntilTic; float m_Volume; - int m_Atten; + float m_Atten; int m_ModeNum; TArray m_SequenceChoices; diff --git a/src/sc_man.cpp b/src/sc_man.cpp index dfd202004..e8bcffdb5 100644 --- a/src/sc_man.cpp +++ b/src/sc_man.cpp @@ -753,7 +753,7 @@ void FScanner::UnGet () // //========================================================================== -int FScanner::MatchString (const char **strings, size_t stride) +int FScanner::MatchString (const char * const *strings, size_t stride) { int i; @@ -778,7 +778,7 @@ int FScanner::MatchString (const char **strings, size_t stride) // //========================================================================== -int FScanner::MustMatchString (const char **strings, size_t stride) +int FScanner::MustMatchString (const char * const *strings, size_t stride) { int i; diff --git a/src/sc_man.h b/src/sc_man.h index 28d035346..ed348f5d5 100644 --- a/src/sc_man.h +++ b/src/sc_man.h @@ -54,8 +54,8 @@ public: void UnGet(); bool Compare(const char *text); - int MatchString(const char **strings, size_t stride = sizeof(char*)); - int MustMatchString(const char **strings, size_t stride = sizeof(char*)); + int MatchString(const char * const *strings, size_t stride = sizeof(char*)); + int MustMatchString(const char * const *strings, size_t stride = sizeof(char*)); int GetMessageLine(); void ScriptError(const char *message, ...); diff --git a/src/thingdef/thingdef.h b/src/thingdef/thingdef.h index 42e683810..d150cd0df 100644 --- a/src/thingdef/thingdef.h +++ b/src/thingdef/thingdef.h @@ -391,7 +391,7 @@ FName EvalExpressionName (DWORD x, AActor *self); #define ACTION_PARAM_FIXED(var,i) \ fixed_t var = EvalExpressionFix(ParameterIndex+i, self); #define ACTION_PARAM_FLOAT(var,i) \ - float var = EvalExpressionF(ParameterIndex+i, self); + float var = float(EvalExpressionF(ParameterIndex+i, self)); #define ACTION_PARAM_CLASS(var,i) \ const PClass *var = EvalExpressionClass(ParameterIndex+i, self); #define ACTION_PARAM_STATE(var,i) \ diff --git a/src/thingdef/thingdef_codeptr.cpp b/src/thingdef/thingdef_codeptr.cpp index 6cb6ea009..16aa8f0e4 100644 --- a/src/thingdef/thingdef_codeptr.cpp +++ b/src/thingdef/thingdef_codeptr.cpp @@ -297,7 +297,7 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_PlaySoundEx) ACTION_PARAM_BOOL(looping, 2); ACTION_PARAM_INT(attenuation_raw, 3); - int attenuation; + float attenuation; switch (attenuation_raw) { case -1: attenuation = ATTN_STATIC; break; // drop off rapidly @@ -1341,7 +1341,7 @@ static bool InitSpawnedItem(AActor *self, AActor *mo, int flags) { // A player always spawns a monster friendly to him mo->flags|=MF_FRIENDLY; - mo->FriendPlayer = originator->player-players+1; + mo->FriendPlayer = int(originator->player-players+1); AActor * attacker=originator->player->attacker; if (attacker) diff --git a/src/thingdef/thingdef_expression.cpp b/src/thingdef/thingdef_expression.cpp index e1e8a60e1..4a4ab3cb9 100644 --- a/src/thingdef/thingdef_expression.cpp +++ b/src/thingdef/thingdef_expression.cpp @@ -2807,7 +2807,7 @@ int FStateExpressions::ResolveAll() if (expressions[i].cloned) { // Now that everything coming before has been resolved we may copy the actual pointer. - intptr_t ii = ((intptr_t)expressions[i].expr); + unsigned ii = unsigned((intptr_t)expressions[i].expr); expressions[i].expr = expressions[ii].expr; } else if (expressions[i].expr != NULL) diff --git a/src/thingdef/thingdef_parse.cpp b/src/thingdef/thingdef_parse.cpp index f58cc492f..bfe1023ee 100644 --- a/src/thingdef/thingdef_parse.cpp +++ b/src/thingdef/thingdef_parse.cpp @@ -539,7 +539,7 @@ static bool ParsePropertyParams(FScanner &sc, FPropertyInfo *prop, AActor *defau case 'F': sc.MustGetFloat(); - conv.f = sc.Float; + conv.f = float(sc.Float); break; case 'Z': // an optional string. Does not allow any numerical value. diff --git a/src/thingdef/thingdef_properties.cpp b/src/thingdef/thingdef_properties.cpp index f71b0afdf..7622d8ca7 100644 --- a/src/thingdef/thingdef_properties.cpp +++ b/src/thingdef/thingdef_properties.cpp @@ -1805,9 +1805,7 @@ DEFINE_CLASS_PROPERTY_PREFIX(player, crouchsprite, S, PlayerPawn) DEFINE_CLASS_PROPERTY_PREFIX(player, damagescreencolor, C, PlayerPawn) { PROP_COLOR_PARM(c, 0); - defaults->RedDamageFade = RPART (c); - defaults->GreenDamageFade = GPART (c); - defaults->BlueDamageFade = BPART (c); + defaults->DamageFade = c; } //========================================================================== diff --git a/src/v_font.cpp b/src/v_font.cpp index bfc95fc31..e36bd1cac 100644 --- a/src/v_font.cpp +++ b/src/v_font.cpp @@ -1018,7 +1018,7 @@ void FSingleLumpFont::LoadFON2 (int lump, const BYTE *data) } else { - Chars[i].Pic = new FFontChar2 (lump, NULL, data_p - data, widths2[i], FontHeight); + Chars[i].Pic = new FFontChar2 (lump, NULL, int(data_p - data), widths2[i], FontHeight); do { SBYTE code = *data_p++; @@ -1068,7 +1068,7 @@ void FSingleLumpFont::CheckFON1Chars (int lump, const BYTE *data, double *lumino { int destSize = SpaceWidth * FontHeight; - Chars[i].Pic = new FFontChar2 (lump, PatchRemap, data_p - data, SpaceWidth, FontHeight); + Chars[i].Pic = new FFontChar2 (lump, PatchRemap, int(data_p - data), SpaceWidth, FontHeight); // Advance to next char's data and count the used colors. do diff --git a/src/version.h b/src/version.h index ee925536a..ab9724686 100644 --- a/src/version.h +++ b/src/version.h @@ -75,7 +75,7 @@ // SAVESIG should match SAVEVER. // MINSAVEVER is the minimum level snapshot version that can be loaded. -#define MINSAVEVER 1507 +#define MINSAVEVER 1583 #if SVN_REVISION_NUMBER < MINSAVEVER // Never write a savegame with a version lower than what we need diff --git a/src/w_wad.cpp b/src/w_wad.cpp index 24a5ae121..1db4639cb 100644 --- a/src/w_wad.cpp +++ b/src/w_wad.cpp @@ -831,7 +831,7 @@ int FWadCollection::FindLump (const char *name, int *lastlump, bool anyns) if ((anyns || lump->Namespace == ns_global) && *(QWORD *)&lump->Name == *(QWORD *)&name8) { - int lump = lump_p - &LumpInfo[0]; + int lump = int(lump_p - &LumpInfo[0]); *lastlump = lump + 1; return lump; } diff --git a/src/win32/eaxedit.cpp b/src/win32/eaxedit.cpp index fa73ce4bf..db1fd470d 100644 --- a/src/win32/eaxedit.cpp +++ b/src/win32/eaxedit.cpp @@ -18,6 +18,10 @@ #include "c_cvars.h" #include "doomstat.h" +#ifdef _MSC_VER +#pragma warning(disable:4244) +#endif + // More w32api lackings #ifndef TTM_SETTITLE #define TTM_SETTITLEA (WM_USER+32) diff --git a/src/win32/i_input.cpp b/src/win32/i_input.cpp index d5d79ffc7..1a122e876 100644 --- a/src/win32/i_input.cpp +++ b/src/win32/i_input.cpp @@ -55,6 +55,10 @@ #include #include +#ifdef _MSC_VER +#pragma warning(disable:4244) +#endif + // Compensate for w32api's lack #ifndef GET_XBUTTON_WPARAM #define GET_XBUTTON_WPARAM(wParam) (HIWORD(wParam)) diff --git a/src/win32/i_main.cpp b/src/win32/i_main.cpp index f69de57e5..a1264c000 100644 --- a/src/win32/i_main.cpp +++ b/src/win32/i_main.cpp @@ -42,6 +42,10 @@ #include #include +#ifdef _MSC_VER +#pragma warning(disable:4244) +#endif + //#include #define NOTIFY_FOR_THIS_SESSION 0 diff --git a/src/win32/i_system.cpp b/src/win32/i_system.cpp index 6f300446f..8db15225b 100644 --- a/src/win32/i_system.cpp +++ b/src/win32/i_system.cpp @@ -39,6 +39,10 @@ #include #include +#ifdef _MSC_VER +#pragma warning(disable:4244) +#endif + #define USE_WINDOWS_DWORD #include "hardware.h" #include "doomerrors.h"