Fix compilation with VS2019

This commit is contained in:
momo5502 2019-01-26 21:37:46 +01:00
parent 26b6973c9c
commit 6c859bf1d0
4 changed files with 15 additions and 5 deletions

View File

@ -57,6 +57,7 @@ workspace "open-iw5"
editandcontinue "Off" editandcontinue "Off"
warnings "Extra" warnings "Extra"
characterset "ASCII" characterset "ASCII"
toolset "v142"
flags { flags {
"NoIncrementalLink", "NoIncrementalLink",

View File

@ -16,10 +16,10 @@ namespace game
class task final : public task_handle class task final : public task_handle
{ {
public: public:
std::chrono::steady_clock::time_point last_execution; std::chrono::steady_clock::time_point last_execution{};
std::function<void()> callback; std::function<void()> callback{};
std::chrono::milliseconds delay; std::chrono::milliseconds delay{};
bool is_volatile; bool is_volatile = false;
}; };
class scheduler final class scheduler final

View File

@ -79,7 +79,7 @@ void launcher::select_mode(const mode mode)
std::string launcher::load_content(const int res) std::string launcher::load_content(const int res)
{ {
const auto resource = FindResource(utils::nt::module(), MAKEINTRESOURCE(res), RT_RCDATA); const auto resource = FindResource(utils::nt::module(), MAKEINTRESOURCE(res), RT_RCDATA);
if (!res) return {}; if (!resource) return {};
const auto handle = LoadResource(nullptr, resource); const auto handle = LoadResource(nullptr, resource);
if (!handle) return {}; if (!handle) return {};

View File

@ -4,8 +4,17 @@
#define TLS_PAYLOAD_SIZE 0x2000 #define TLS_PAYLOAD_SIZE 0x2000
#pragma warning(push) #pragma warning(push)
#pragma warning(disable: 4244)
#pragma warning(disable: 4458) #pragma warning(disable: 4458)
#pragma warning(disable: 4702) #pragma warning(disable: 4702)
#pragma warning(disable: 6297)
#pragma warning(disable: 6385)
#pragma warning(disable: 6386)
#pragma warning(disable: 26451)
#pragma warning(disable: 26444)
#pragma warning(disable: 26451)
#pragma warning(disable: 26495)
#pragma warning(disable: 28020)
#define WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN