error LNK2019: unresolved external symbol “” referenced in function

Most likely cause is that you’re not linking in the object created from Agent.cpp.

You should check to ensure that it’s part of the project and that you’re using the correct version, compiled with this current compiler as well (since you state you haven’t touched it in a while, it may be that the objects were built with an earlier compiler version, potentially making them incompatible – different name mangling methods, for example).

The first thing to try (once you’ve established all correct files are in the project) is a full clean-and-build.

On a few other points:

  1. The error is occurring in World::processMouse meaning that the source for GLView::processMouse is probably irrelevant.
  2. I find your mixing of printf and cout slightly … disturbing. You should probably avoid printf for serious C++ programming. It works, but it’s mostly intended for legacy C support.

Leave a Comment