Hi All,
I've been trying to implement an XML-based map importer doobrey. However, when I think I've got it working, building my project causes Visual Studio to crash!
Any ideas?
| <?xml version="1.0" encoding="utf-8" ?> |
| <XnaContent> |
| <Asset Type="System.Collections.Generic.List[Prototype1.Tile]"> |
| <Item> |
| <BaseName>FlatGrass</BaseName> |
| <Position>0 0</Position> |
| </Item> |
| </Asset> |
| </XnaContent> |
| public class TileContentReader : ContentTypeReader<Tile> |
| { |
| protected override Tile Read(ContentReader input, Tile existingInstance) |
| { |
| String baseName = input.ReadString(); |
| Vector2 position = input.ReadVector2(); |
| Tile tile = new Tile(position, baseName); |
| tile.loadContent(input.ContentManager); |
| return tile; |
| } |
| } |
| [ContentTypeWriter] |
| public class TileContentTypeWriter : ContentTypeWriter<TWrite> |
| { |
| protected override void Write(ContentWriter output, Tile value) |
| { |
| output.Write(value.getBaseName()); |
| output.Write(value.getPosition()); |
| } |
| |
| public override string GetRuntimeReader(TargetPlatform targetPlatform) |
| { |
| return typeof(TileContentReader).AssemblyQualifiedName; |
| } |
| } |
Problem signature:
Problem Event Name: APPCRASH
Application Name: vcsexpress.exe
Application Version: 9.0.21022.8
Application Timestamp: 4731613f
Fault Module Name: unknown
Fault Module Version: 0.0.0.0
Fault Module Timestamp: 00000000
Exception Code: c00000fd
Exception Offset: 0c5c90c9
OS Version: 6.0.6001.2.1.0.768.3
Locale ID: 2057
Additional information about the problem:
LCID: 1033
Read our privacy statement:
http://go.microsoft.com/fwlink/?linkid=50163&clcid=0x0409
binarytweed.comNew games that're a bit like old games, but better.