This line gives "Null pointer access" :
Vector2 targetAnchor = _cameraDef[Level.cameraID - 1]._targetCameraWeight <= 0.0f ? Vector2(Level.camera.lookAt) : _cameraDef[Level.cameraID - 1]._targetCameraAncor;
(Also, the cast to Vector2 is there in the first place to avoid "Both sides of the expression must be of the same type".)
However, this equivalent code is fine (when placed at the same line in the same file) :
Vector2 targetAnchor;
if (_cameraDef[Level.cameraID - 1]._targetCameraWeight <= 0.0f)
{
targetAnchor = Vector2(Level.camera.lookAt);
}
else
{
targetAnchor = _cameraDef[Level.cameraID - 1]._targetCameraAncor;
}
Remi Gillig