Supported Types

Most custom types can be supported by creating an ES2Type for it, either automatically using Manage Types… or manually using a template.

For information on how to do this, please see the Adding Support for Other Types guide.

  • int
  • float
  • string
  • byte
  • bool
  • char
  • long
  • short
  • uint
  • ulong
  • ushort
  • Enum
  • DateTime

Note: Saving collections containing collections is not directly supported, but can be achieved with the ‘Saving Nested Collections’ guide.

  • Array [ ]
  • 2D Array [,]
  • 3D Array [,,]
  • Dictionary<TKey, TValue>
  • List<T>
  • Queue<T>
  • HashSet<T>
  • Stack<T>

Click a type to see what variables it saves.

 

Vector2
  • x
  • y
Vector3
  • x
  • y
  • z
Vector4
  • x
  • y
  • z
  • w
Quaternion
  • x
  • y
  • z
  • w
Color
  • r
  • g
  • b
  • a
Color32
  • r
  • g
  • b
  • a
Texture2D
  • pixels
  • filterMode
  • anisoLevel
  • wrapMode
  • mipMapBias
Sprite
  • texture
  • rect
  • bounds
  • textureRect
  • name
Material

Note: Textures are saved by value, not by reference.

  • Textures
  • shader
  • textureOffset
  • textureScale
Mesh

Note: Meshes are saved by value, not by reference.

  • submeshes
  • vertices
  • triangles
  • normals
  • uv
  • uv2
  • tangents
  • bindposes
  • boneWeights
  • colors32
AudioClip

Note: AudioClips are saved by value, not by reference.

Note 2: Data is saved in a raw format so this may not be suitable for long AudioClips.

  • name
  • samples
  • channels
  • frequency
Rect
  • x
  • y
  • width
  • height
Bounds
  • center
  • size
Matrix4x4
  • columns
BoneWeight
  • boneIndex0
  • boneIndex1
  • boneIndex2
  • boneIndex3
  • weight0
  • weight1
  • weight2
  • weight3

Click a type to see what variables it saves.

Transform

Note: Components are saved by value, not by reference.

  • position
  • rotation
  • localScale
  • tag
SphereCollider

Note: Components are saved by value, not by reference.

  • center
  • radius
  • isTrigger
BoxCollider

Note: Components are saved by value, not by reference.

  • center
  • size
  • isTrigger
CapsuleCollider

Note: Components are saved by value, not by reference.

  • center
  • radius
  • height
  • direction
  • isTrigger
MeshCollider

Note: Components are saved by value, not by reference.

  • sharedMesh
  • convex
  • smoothSphereCollisions
  • isTrigger

It’s not possible to save Collections which contain other collections due to limitations in C# / UnityScript.

However, an easy workaround is to create a wrapper class which contains your inner collection, and then add that as a supported type. You can then save a Collection of these wrapper classes.

For example, a wrapper class for an int array might look like this:

We can then use this to store a List of arrays as follows:

We’ve created an ES2Type for saving and loading GameObjects, but is also provided here as an example.

It saves a GameObject and it’s supported Components. Note that this will not save the children of the GameObject.

After creating the ES2Type file below, you will need to refresh the type list by going to Assets > Easy Save 2 > Manage Types and pressing the Refresh ES2Init button.