I called this file Classes.yaml and put it inside the Assets/Resources.

Note: Quotes are optional in yaml and arrays are created with a simple -.
Also ensure you do not mix tabs and spaces or your yaml file will have trouble
loading. It's best to display tabs in your editor to catch the problem as it
happens.

Loading The Yaml File

I created a Datastore class that acts as a central place to load all yaml files.
Once loaded the data is stored in a method called AddItems(), that will be
explained in a minute.

The ClassList class defines the structure of the yaml file.
The parser will actually create Class
instances with the yaml data and store them in the array, no messy string names to deal with.
This is all a Yamldotnet feature, once again great library.

Each class has a corresponding enum which is like an index to find all items in
the game. Usually a plain string or number is used to, but that only works for so long
until items get renamed or removed and subtle bugs are created. I enums are much
cleaner.

Each class also extends from Datastore, this class adds instance variables id, name and
description but more importantly it adds static methods -- AddItems(),
Clear() -- for finding and
registering global data.

Note: When loading yaml data, ensure each property on the class has an
attribute accessor-- { get; set; } -- or else an error will occur.