Ly 1.24 cannot build - Warning as Errors

Suddenly this is happening not sure why, I rebuild and now I cannot get rid of:

e:\Amazon\Lumberyard\1.24.0.0\dev\Code\CryEngine\CryCommon\ILevelSystem.h(94): error C2220: the following warning is treated as an error
e:\Amazon\Lumberyard\1.24.0.0\dev\Code\CryEngine\CryCommon\ILevelSystem.h(94): warning C5208: unnamed class used in typedef name cannot declare members other than non-static data members, member enumerations, or member classes
e:\Amazon\Lumberyard\1.24.0.0\dev\Code\CryEngine\CryCommon\ILevelSystem.h(94): note: to simplify migration, consider the temporary use of /Wv:18 flag with the version of the compiler with which you used to build without warnings

In the meantime I’ll reinstall everything… coz I’m blocked.

The code that creates problems is:

typedef struct
{
string name;
string xmlFile;
int cgfCount;
void GetMemoryUsage(ICrySizer* pSizer) const
{
pSizer->AddObject(name);
pSizer->AddObject(xmlFile);
}
} TGameTypeInfo;

In C++ you don’t need typedef… Solution:

struct TGameTypeInfo
{
    string  name;
    string  xmlFile;
    int         cgfCount;
    void GetMemoryUsage(ICrySizer* pSizer) const
    {
        pSizer->AddObject(name);
        pSizer->AddObject(xmlFile);
    }
};
1 Like

I also added in ObjectManager.cpp:
#include

I’m using VS2019 btw.

A lot of people are saying VS2019 is not working for them, if you can try 2017 and see if that fixes any issues. :+1:

They used std::runtime_error in Sandbox’s code.
Another error for " std::runtime_error " can be solved by add this line in StdAfx.h of Editor module:
[Lumberyard_Root]\dev\Code\Sandbox\Editor\StdAfx.h

#include <stdexcept>

VS2019 works well, just they have few little errors.

@GameInstitute also true, another options.

vs2019_fix.patch (3.3 KB)

FYI, here is my unofficial fix up for VS2019 16.6 on my local system. We will fix it in the next release.

1 Like

hello
Thanks …I did, but there is another problem for me
Can you help?

lmbr_create2.txt (3.8 KB)

The @GameInstitute solution + struct fix helped to me, but I needed to re-install whole 1.24

@Itachi999 can you post your issue?

Looks like you didn’t check VS2017 or VS2019 in SetupAssistant.