Matan Shahar
Matan Shahar

Reputation: 3240

Publish XNA Game Content as Game Content Refrence

I'm making game engine (Game Library) that have his own content. The game engine is a number of references (.dlls) which can be included in basic xna game and provide set of tools for the game. the problem is that the engine have some effects that have to included also as content reference. My question is how I can build the content as a dll / game content project and not like a folder.

Upvotes: 1

Views: 109

Answers (1)

Justin Skiles
Justin Skiles

Reputation: 9503

This is just a guess based on my anecdotal experience with XNA. The content pipeline runs as an extension of the Visual Studio build process which translates your assets into .xnb files. In the case of referencing your game library which has its own content references, you cannot rely on that content being built because you aren't actually building the game library from your game project.

You might have to open the project containing the game library and its associated content project, build that, and then copy the game library .dll and its associated content to the correct location in the project that references the game library.

Alternatively, you could include the game library project and its content project as part of your game project. This might allow the build process to build both content projects.

Sorry, I haven't actually tried this, so I'm just making a guess.

Upvotes: 1

Related Questions