如何在Monogame Windows Phone 8 Game项目上设置xnb文件? [英] How to set xnb files on Monogame Windows Phone 8 Game project?
问题描述
我从未找到任何使xnb文件正常工作的教程.它们都使用非Windows Phone 8(Win 8 Metro等)方式.
有人可以指导我使我的xnb文件在MonoGame Windows Phone 8 Game项目中可用吗?因为我用谷歌搜索都无济于事.
此外,我可以使用XNA Windows游戏项目(与VS 2010)创建XNB还是将其作为Windows Phone游戏(我尚未安装WPhoneSDK 7.1,但已在VS2012中安装第八个)? >
到目前为止,我使用几种方法并不断导致Microsoft.Xna.Framework.ContentLoadException
谢谢
-
使用 XnaContentCompiler 将资产编译为xnb.
-
将文件放入使用MonoGame模板创建的内容文件夹中.
-
将属性更改为
Build Action = Content
,然后将其复制到Output Directory = Copy if Newer
. -
做正常的事
var t = Content.Load<Texture2D>(@"TextureName");
.
I never found any tutorial to make xnb files works. They are all using non Windows Phone 8 (Win 8 metro, etc) way.
Can someone guide me to make my xnb files workable at MonoGame Windows Phone 8 Game project? Because nothing I googled is doing any good.
Also, can I create an XNB using XNA Windows Game Project (with VS 2010) or does it need the project to be Windows Phone Game (I haven't Installed WPhoneSDK 7.1, but have installed the 8th in VS2012)
I so far use several ways and keep resulting in Microsoft.Xna.Framework.ContentLoadException
Thanks
Compile the assets into xnb's using the XnaContentCompiler.
Put the files in the content folder that is created with your MonoGame template.
Change the properties to
Build Action = Content
and Copy toOutput Directory = Copy if Newer
.Do your normal thing
var t = Content.Load<Texture2D>(@"TextureName");
.
这篇关于如何在Monogame Windows Phone 8 Game项目上设置xnb文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!