Marleys Ghost Posted January 10, 2010 Share Posted January 10, 2010 Seem to get these errors: 1>d:\game development\leadwerks sdk 2.3\cpp\engine.cpp(1598) : error C2062: type 'int' unexpected 1>d:\game development\leadwerks sdk 2.3\cpp\engine.cpp(1599) : error C2143: syntax error : missing ';' before '{' 1>d:\game development\leadwerks sdk 2.3\cpp\engine.cpp(1599) : error C2447: '{' : missing function header (old-style formal list?) I did a sync this morning: Downloading "CPP/LEO/leoLayer.h"... Downloading "Maps/deserthighway_alpha.dds"... Downloading "Maps/deserthighway.sbx"... Just 3 files updated, but some code that worked now throws up the above errors. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 10, 2010 Share Posted January 10, 2010 The compiler error tries to tell you that it's missing some type definitions. So you probably didn't include some header file. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 The compiler error tries to tell you that it's missing some type definitions. So you probably didn't include some header file. Well I had not changed the code only tried to recompile as I had altered the start co-ordinates for the controller. I just deleted the engine.cpp and resync'd to replace and now it works... guess I'll file it under "one of those things" Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 I was hoping that was the problem with setting up Gamelib which still throws up these errors: 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glDisable@4 referenced in function "public: void __thiscall TGame::DrawCrosshair(int,int)" (?DrawCrosshair@TGame@@QAEXHH@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glEnable@4 referenced in function "public: void __thiscall TGame::DrawCrosshair(int,int)" (?DrawCrosshair@TGame@@QAEXHH@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glColor4f@16 referenced in function "void __cdecl Color(double,double,double,double)" (?Color@@YAXNNNN@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glEnd@0 referenced in function "void __cdecl Line(int,int,int,int)" (?Line@@YAXHHHH@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glVertex2i@8 referenced in function "void __cdecl Line(int,int,int,int)" (?Line@@YAXHHHH@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glBegin@4 referenced in function "void __cdecl Line(int,int,int,int)" (?Line@@YAXHHHH@Z) but looking at them, it seems it can't find some functions. seems not to be linking to opengl32.lib and glu32.lib ? Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 10, 2010 Share Posted January 10, 2010 Ah, then the reason is clear: You need to install Windows Platform SDK, since gamelib needs raw OpenGL commands also: http://www.microsoft.com/downloads/details.aspx?familyid=C17BA869-9671-4330-A63E-1FD44E0E2505&displaylang=en This will install additional C++ headers to your Visual Studio 2008 C++, including the OpenGL headers. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 Ah, then the reason is clear: You need to install Windows Platform SDK, since gamelib needs raw OpenGL commands also: http://www.microsoft.com/downloads/details.aspx?familyid=C17BA869-9671-4330-A63E-1FD44E0E2505&displaylang=en This will install additional C++ headers to your Visual Studio 2008 C++, including the OpenGL headers. I actually did that this morning, but it seems it may be broken and the web install is throwing up a missing .cab file so am just downloading the .iso and will repair that way. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 Still getting 3 errors after all that: 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glEnd@0 referenced in function "void __cdecl Line(int,int,int,int)" (?Line@@YAXHHHH@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glVertex2i@8 referenced in function "void __cdecl Line(int,int,int,int)" (?Line@@YAXHHHH@Z) 1>Gamelib.obj : error LNK2019: unresolved external symbol __imp__glBegin@4 referenced in function "void __cdecl Line(int,int,int,int)" (?Line@@YAXHHHH@Z) My Windows SDK now has 6.0 6.0a 6.1 and 7.0 ... can't seem to shift these last three errors. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 10, 2010 Share Posted January 10, 2010 Did you do a Clean Build? Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 yep it had a good scrub (deleted and re-done the whole proj.) Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 10, 2010 Share Posted January 10, 2010 Maybe the new Platform SDK is buggy then, I still use the Windows SDK from August 2007. In gamelib there is the line "#include <gl/glut.h>" that should correctly bind the opengl .lib files, and you don't need to do anything else to use glBegin, glEnd and such commands then. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 got past that now seems my glut.h file was "incorrect" ..all compiles ok but now I am getting a run error. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 10, 2010 Share Posted January 10, 2010 Try to uninstall the Windows SDK and install the "last known good" one: http://www.microsoft.com/downloads/details.aspx?FamilyId=484269E2-3B89-47E3-8EB7-1F2BE6D7123A&displaylang=en Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 10, 2010 Author Share Posted January 10, 2010 Try to uninstall the Windows SDK and install the "last known good" one: http://www.microsoft.com/downloads/details.aspx?FamilyId=484269E2-3B89-47E3-8EB7-1F2BE6D7123A&displaylang=en Just trying that now ... but the novelty of windows SDK installation has worn off a tad lol Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 11, 2010 Author Share Posted January 11, 2010 Well after unistalling 6.0 6.0a 6.1 and 7.0 and then re-installing 6.1 adding the glut.h to the gl include folder ect... it will compile but still gets the error as per above pic. when running. but I dont have an f: drive .. thats a HDD Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 11, 2010 Share Posted January 11, 2010 Have you tried to make a new project? Maybe you have some wierd settings in your project which you are compiling. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 11, 2010 Author Share Posted January 11, 2010 Have you tried to make a new project? Maybe you have some wierd settings in your project which you are compiling. Will try a new proj. now. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 11, 2010 Author Share Posted January 11, 2010 nope same error. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 11, 2010 Share Posted January 11, 2010 You shouldn't get the same error when you make a new project with nothing in it. Just make a simple test program and don't use the old gamelib demo. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 11, 2010 Author Share Posted January 11, 2010 I was using the new gamelib files and this code. main.sbx was not the one from the old demo. #include "gamelib.h" int main() { TGame game; Engine engine; engine.Create(); game.Initialize( 800, 600 ); Engine::SetFilters(); Collisions::Set(); game.scene.LoadMap( "abstract::main.sbx" ); //Game loop while( !Keyboard::I****() && !Engine::IsTerminated() ) { if( !Engine::IsSuspended() ) //We are not in focus! { // Render game.scene.Update(); game.scene.Render(); // Send to screen Engine::Flip(0); } } // Done return engine.Free(); } Xtra tests: If I just set up a new Leo VS2008 console project and run it I get a whole load of error LNK2019: unresolved external symbol errors. If I just set up a new C++ VS2008 console project and run it , it runs as expected with the demo cube. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Canardia Posted January 11, 2010 Share Posted January 11, 2010 When you make the leo project, does it have engine.cpp and leo.cpp in the source list? And when using gamelib, you need only gamelib.cpp in the source list. gamelib project: #include "gamelib.h" source list: gamelib.cpp leo project: #include "leo.h" source list: engine.cpp, leo.cpp procedural project: #include "engine.h" source list: engine.cpp Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 11, 2010 Author Share Posted January 11, 2010 When you make the leo project, does it have engine.cpp and leo.cpp in the source list? No just leo.cpp and the test.cpp (project code) And when using gamelib, you need only gamelib.cpp in the source list. Thats all there was and of course the test.cpp (project code) Will try a leo project again and add the engine.cpp Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Marleys Ghost Posted January 11, 2010 Author Share Posted January 11, 2010 ok adding engine.cpp manually allowed the standard example template for a leo proj. to work. Have since reinstalled Visual studio and winSDK 6.1 (again lost count now lol) .. setup glut.h and ... it now works .. well the basic gamelib code from the PT does .. so somewhere along the line its fixed Thanks for your patience Lumooja. Quote AMD Bulldozer FX-4 Quad Core 4100 Black Edition 2 x 4GB DDR3 1333Mhz Memory Gigabyte GeForce GTX 550 Ti OC 1024MB GDDR5 Windows 7 Home 64 bit BlitzMax 1.50 • Lua 5.1 • MaxGUI 1.41 • UU3D Pro • MessiahStudio Pro • Silo Pro 3D Coat • ShaderMap Pro • Hexagon 2 • Photoshop, Gimp & Paint.NET LE 2.5/3.4 • Skyline • UE4 • CE3 SDK • Unity 5 • Esenthel Engine 2.0 Marleys Ghost's YouTube Channel • Marleys Ghost's Blog "I used to be alive like you .... then I took an arrow to the head" Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.