- 博客(0)
- 资源 (2)
- 问答 (2)
- 收藏
- 关注
Tiled for C#
How to
1.) Download Tiled.rar
2.) Copy the dlls to somewhere you can use them, or take a look at the Visual Studio project.
3.) Add a reference to Tiled.dll to your game, and a reference to TMXProcessorLib.dll to your gamecontent.
4.) Create a map using Tiled.
5.) Add the .tmx-file and tilesets to your gamecontent.
6.) Choose TMX Importer and TMX Processor for .tmx-files.
7.) Write your LoadContent-method:
protected override void LoadContent()
{
spriteBatch = new SpriteBatch(GraphicsDevice);
device = graphics.GraphicsDevice;
map = Content.Load("map"); // name of the .tmx-file without ".tmx"
TilesetManager.LoadTextures(Content);
}
8.) Let it be drawn:
protected override void Draw(GameTime gameTime)
{
GraphicsDevice.Clear(Color.Blue);
spriteBatch.Begin();
spriteBatch.Draw(map, new Vector2());
spriteBatch.End();
base.Draw(gameTime);
}
9.) Start!
2013-01-31
最简单的7Z SDK用法 DEMO
最简单的7Z SDK用法 DEMO
API:
Zip(Stream inStream, Stream outStream)
Unzip(Stream inStream, Stream outStream)
包括全部源代码, visual studio 2010, 打开就可以用!100%
这是我测试的结果:
Input length 100000
Output length 268
Ziped rate 0.268%
Input length 268
Output length 100000
UnZiped rate 37313.4328358209%
2012-05-19
设计3智冠三国一样的东西.以数据库为中心作为架构,如何?
2014-12-06
如何开发一个类似csdn问答的网站?
2014-11-15
TA创建的收藏夹 TA关注的收藏夹
TA关注的人