Instantiating Custom Types
Introduction
Why use non-primitive types?
// EnemyInfo does not need to be manually defined if you're using Glue
public class EnemyInfo
{
public string Name;
public int HP;
public AttackInfo AttackInfo;
}
// AttackInfo *does* need to be manually defined if you're using Glue. See below for more info on this
public class AttackInfo
{
public int Damage;
public float AreaOfEffect;
}Creating the CSV
Creating Classes for Inheritance
Defining a CSV that supports inheritance
Using Existing Types
Boundaries (Microsoft.Xna.Framework.Rectangle)
Last updated
Was this helpful?