From now you can use whatever component data layout you want while it's blittable. Previously NSprites was able to only use 1 field components with prefefined set of formats. Now component can contain any set of field you need.
For example:
using NSprites;
using Unity.Entities;
using UnityEngine;
[assembly: InstancedPropertyComponent(typeof(SpriteColor), "_colorBuffer")]
namespace NSprites
{
public struct SpriteColor : IComponentData
{
public Color color;
public float intensity;
}
}
Upgraid guide:
There is no more PropertyFormat so all your
InstancedPropertyComponent should be used without PropertyFormat parameter. So for example [assembly: InstancedPropertyComponent(typeof(SpriteColor), "_color", PropertyFormat.Float4)] becomes [assembly: InstancedPropertyComponent(typeof(SpriteColor), "_color")]
From now you can use whatever component data layout you want while it's blittable. Previously NSprites was able to only use 1 field components with prefefined set of formats. Now component can contain any set of field you need.
For example:
Upgraid guide: There is no more
PropertyFormat
so all yourInstancedPropertyComponent
should be used withoutPropertyFormat
parameter. So for example[assembly: InstancedPropertyComponent(typeof(SpriteColor), "_color", PropertyFormat.Float4)]
becomes[assembly: InstancedPropertyComponent(typeof(SpriteColor), "_color")]