Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

A small XNA tip

Sign in to follow this  


I've been playing with the content pipeline stuff, particularly with regards to processing and loading my own custom objects. To make it easy I'm using XM.

One of the things that was bugging me was that one of my objects contained a dictionary of subobjects, and the XML for it wasn't very pretty:


After much mucking around with Reflector and the documentation, I found Microsoft.Xna.Framework.Content.ContentSerializerAttribute, which has a number of properties, including 'CollectionItemName.' Changing my dictionary to a list and applying this attribute has produced a much nicer result:

On a related note, this is the first time I've actually used Reflector, and I'm amazed. It's a truly awesome tool if you're doing .NET work.
Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!