This is an old revision of the document!


What is MDF?

MDF stands for Mars Data Format. It's a JSON-esque file format that's used to define almost all user-accessible data for the Mars Engine.

Properties

A property is any string of characters followed by an = sign, and then some further text. Properties are made up of 3 main parts; the Name, an optional Inheritance Option, and the Value.

	Name = Value
	Name = "Value"

*Name* and *Value* must be made out of Valid Identifier Characters, or be surrounded by double quote marks.

Valid Identifier Characters

Names and Values can only contain these characters (Excluding spaces):

 A-Z a-z 0-9 _!+-.

Optionally, you can also surround the Name or Value with double quotes to include otherwise illegal characters, such as spaces, colons, and so on.

	✅ ThisIsAValidIdentifier
	❌ This is NOT a valid identifier
	❌ This:is, ALSO not a valid * identifier
	✅ "This is a valid identifier, now with spaces and commas!"

You can also escape quotes if needed in the identifier.

	"This identifier has \"escaped\" double quotes in it!"

Elements

An MDF is made up of sections collectively referred to as *Elements*. There are three major types of element; Values, Chunks, and Arrays.

Value

A *Value* element is just a string of characters that will be assigned to the property.

	MyValue = "This is MyValue!"

Chunk

TODO

Array

TODO