4
votes
1answer
250 views

How to store and parse story actions in XML

I been working on a game in Unity that reads its story (Actions, scene descriptions, NPC's, ect...) from an XML and have been wondering there was a better way to store actions based on player data ...
0
votes
1answer
404 views

How can I save an XML file with Unity on the Android platform?

I am writing a game that has a save function which looks like this public void Save() { System.Xml.Serialization.XmlSerializer ser = new ...
0
votes
1answer
105 views

Why is XmlSerializer adding junk to the end of my file?

I'm making a game and I am serializing the save game data. The data is simply a few lists of bools, ints and floats. But about 50% of the time I get an error when the data tries to save or load that ...
1
vote
1answer
98 views

ContentManager in XNA cant find any XML

Im making a game in XNA 4 and this is the first time I'm using the Content loader to initialize a simple class with a XML file, but no matter how many guide I follow, or how simple or complicated is ...
2
votes
2answers
308 views

Unlimited inventory system?

I am working on a small game, I need to add an unlimited inventory to the game but I am not sure how to do it. I have an inventory system with a specific amount of slots, here it is: <?xml ...
4
votes
3answers
2k views

Loading levels in XNA from XML

I'm trying to load levels in XNA from XML files. I have currently got a system to do this working, but it looks like it might get horribly complex as I add more objects later on. My world currently ...
-1
votes
1answer
765 views

Writing to XML issue Unity3D C#

I'm trying to create a tool using Unity to generate an XML file for use in another project. Now, please, before someone suggests I do it in something, the reason I am using Unity is that it allows me ...
1
vote
3answers
636 views

Opening an XML in Unity3D when the game is built

At the moment, my game can open up an XML file inside the editor when I run it. In my XMLReader.cs I'm loading in my file like so: _xmlDocument.Load(Application.dataPath + ...
3
votes
1answer
823 views

Loading class instance from XML with Texture2D

I'm having trouble with XML and XNA. I want to be able to load weapon settings through XML to make my weapons easier to make and to have less code in the actual project file. So I started out making a ...
3
votes
2answers
2k views

Using XNA's XML content pipeline to read arrays of objects with different subtypes

Using XNA's XML content importer, is it possible to read in an array of objects with different subtypes? For instance, assume these are my class definitions: public abstract class MyBaseClass { ...
1
vote
2answers
211 views

When should I be implementing XML documents

I often struggle with the question of when to use XML docs. Does anyone have a good rule of thumb when it comes to deciding to use them or deciding not to use them. At the moment I am working on a ...
2
votes
1answer
625 views

Building different game objects (EG Spells, Items,) for an rpg game

I believe the best way to manage item data would be to use xml? For spells would the best option be to create a class (EG Fireball) and define all of the parameters inside of that class? Like ...
1
vote
3answers
344 views

Help Reading this Data in XML as a List (ContentReader)

Edit: So i'm going to rephrase the question a bit, seeing as now i think know how i'm going to read this data. Looking at this example as my guide: ...
3
votes
2answers
318 views

Issue with loading XML

So recently i've been changing my XML files that i'm using in-game, to add in a bit more data to the files but i've also changed the way in which i load & save files, by now using the XDocument ...
2
votes
1answer
2k views

Xna, writing XML </Asset> end element

got another question here. Its not about actually writing/reading files in XML, i already know how to-do this. But rather something that has bugged me for awhile. Ok, so when i write out my files, ...
4
votes
2answers
2k views

Recommended method for XML level loading in XNA

I want to use Blender as my level designer tool for an XNA game. Using an existing plugin, I can export my levels to DotScene format which is basically an xml file like this one: <scene ...
1
vote
1answer
398 views

Deserialize inherited classes into the same list in XNA

I am writing a Gui for a game (for what else ...). Therefor I wrote a class GuiElement which has some serializeable fields. From this class I deflect a Class "Button" which has one serializeable field ...
9
votes
1answer
544 views

Organising levels / rooms in a MUD-style text based world

I'm thinking of writing a small text-based adventure game, but I'm not particularly sure how I should design the world from a technical standpoint. My first thought is to do it in XML, designed ...
11
votes
7answers
6k views

What is a good way to store tilemap data?

I'm developing a 2D platformer with some uni friends. We've based it upon the XNA Platformer Starter Kit which uses .txt files to store the tile map. While this is simple it does not give us enough ...
5
votes
1answer
475 views

How can I pass an external instance to the constructor of an object that's being created using the default XNA XML content loader?

I'm trying to understand how to use the XNA XML content importer to instantiate non-trivial objects that are more than a collection of basic properties (e.g., a class that inherits from ...