Pinned Source Code v2.1 (BETA)

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Source Code v2.1

      Here is the latest source code for the book!

      Note that it is pretty fresh out of the oven - there might be some lingering issues.

      Some of the things that are in this release:
      1. Fixed the min/max compile issue.
      2. It works with DirectX 9.0 October 2005 Release
      3. Boost C++ and Ogg/Vorbis Audio are included
      4. Novodex 2.2 is supported, but optional
      5. A number of other minor tweaks and fixes
      Mr.Mike
      Author, Programmer, Brewer, Patriot
    • RE: Source Code v2.1 (BETA)

      Awesome job mr. Mike! It's good to know that even with yoru busy schedule you still have time to deal with the issues that we faced in 2.0.

      It compiled super easy this time (once i got all teh libaries and includes right) but i'm still having problems running it. It's giving me some weird unexpected error and no information to go on. I'll get back to you with any news.
      .Code
      push you ; haha!
    • RE: Source Code v2.1 (BETA)

      I'm assuming it is a crash of some kind?

      If you are running the Debug, Profile, or Release builds you have to copy NxPhysics.dll and NxCooking.dll into the Bin directory from your Novodex SDK....

      You can also try to run in Release mode, without the debugger, and the Minidumper should write out a DMP file that you can send me - I can then debug the problem and get it fixed.
      Mr.Mike
      Author, Programmer, Brewer, Patriot
    • I'm getting an "unexpected error" as well, and the dmp tracks it to the initialization of the physics engine. Apparently somehow it's not able to call gamePhysics->VInitialize() on 1169 of Physics.cpp.

      The dmp file is here:
      braggingrightsproductions.com/Downloads/327.aspx

      It's from a release build, but I have one from a debug build last night. Same error, though.
      "Your job is not to die for your country. Your job is to make some other poor sod die for his."

      The post was edited 1 time, last by Nebuchadnezzar ().

    • Neb - you are definitely missing the Novodex DLLs. Maybe it would be better if there was a dialog box or something instead of a crash....now I'm sure I read that somewhere in a programming book....a good one too....
      Mr.Mike
      Author, Programmer, Brewer, Patriot
    • ROFL!

      Is that what it is? I knew I was forgetting something....

      I'm having hell getting their Max exporter working as well, but that might be the same problem since the linker is puking all this nonsense at me about unresolved externals....
      "Your job is not to die for your country. Your job is to make some other poor sod die for his."
    • Yeah, I'm thinking it's a library I haven't built or something - I've added all of the Novodex lib directories to my paths and no go. I'll keep digging....

      Of course, it did help when I moved those .dll's into the bin directory - like the instructions said....
      "Your job is not to die for your country. Your job is to make some other poor sod die for his."
    • Weird... those libs should have already been in your path if you're using the latest Beta. The only build config that doesn't include the NovodeX libs and headers is the DebugNoPhysics config.

      In addition to the libs, you'll also need to make sure the headers are in your include path as well.
    • Originally posted by Nebuchadnezzar
      I'm having hell getting their Max exporter working as well...

      You talking about that PML exporter? Let me know how that works out for you, I never played with that. From what I understand, NovodeX still doesn't supply a means of parsing those PML files in its API.
    • Yes - ATLTYPES.H is used to grab CSize, CPoint, and CRect. They are all inline, so if people don't want the ATLTYPES dependancy you'll have to rewrite those classes in your own header.
      Mr.Mike
      Author, Programmer, Brewer, Patriot
    • Sure - attach a text file to your post, eh?
      Mr.Mike
      Author, Programmer, Brewer, Patriot
    • Hiya mrmike

      Excellent book.
      I've just installed the Novodex SDK and followed all the instructions in the readme file for Gamecode v2.1 source code.

      It all compiles fine except for the following errors below. Could you please point out hot I could resolve these.

      Thanks.


      ===============
      ------ Build started: Project: DXUT, Configuration: Debug Win32 ------

      DXUT - up-to-date.


      ------ Build started: Project: GameCode2, Configuration: Debug Win32 ------

      GameCode2 - up-to-date.


      ------ Build started: Project: Lang, Configuration: Debug Win32 ------

      Lang - up-to-date.


      ------ Build started: Project: TeapotWars, Configuration: Debug Win32 ------

      Linking...
      TeapotWarsView.obj : error LNK2019: unresolved external symbol __imp__wsprintfW referenced in function "public: virtual void __thiscall TeapotWarsGameView::VRenderText(class CDXUTTextHelper &)" (?VRenderText@TeapotWarsGameView@@UAEXAAVCDXUTTextHelper@@@Z)
      gamecode2d.lib(Network.obj) : error LNK2001: unresolved external symbol __imp__wsprintfW
      gamecode2d.lib(MiniDump.obj) : error LNK2001: unresolved external symbol __imp__wsprintfW
      gamecode2d.lib(Font.obj) : error LNK2001: unresolved external symbol __imp__wsprintfW
      gamecode2d.lib(DirectSoundAudio.obj) : error LNK2019: unresolved external symbol _DirectSoundCreate8@12 referenced in function "public: virtual bool __thiscall CDirectSoundAudio::VInitialize(struct HWND__ *)" (?VInitialize@CDirectSoundAudio@@UAE_NPAUHWND__@@@Z)
      gamecode2d.lib(DirectSoundAudio.obj) : error LNK2001: unresolved external symbol _GUID_NULL
      ..\..\Test/TeapotWarsd.exe : fatal error LNK1120: 3 unresolved externals

      Build log was saved at "file://d:\GameCode v2.1\Obj\Debug\TeapotWars\BuildLog.htm"
      TeapotWars - 7 error(s), 0 warning(s)


      ---------------------- Done ----------------------

      Build: 3 succeeded, 1 failed, 0 skipped



      P.S: This is using VS 2003.NET.
      I get loads of errors under VS 2005 but I'm yet to do all the necessary adjustments such as copying the NxPhysics.dll file, etc. I'll do these and let you know how it goes. However, could you help sort this current probelm out. Cheers.
    • First of all, I am fairly new to game programming. I do have some knowledge of C/C++ and Java. I have one game to my credit written in Java but I want to do games in C++. My question is, the code I downloaded from your site mrmike is it a framework of the architecture you are talking about in chapter 2?

      Thanks
      tweakman
    • logan, you might be missing some libs in your path. Can you zip up your TeapotWars.proj file and post it on this thread?

      tweakman, the answer to your question is no... that code you downloaded is not just a framework, but a full working sample that uses the framework.