use of org.terasology.persistence.typeHandling.extensionTypes.ColorTypeHandler in project Terasology by MovingBlocks.
the class TypeSerializationLibrary method createDefaultLibrary.
public static TypeSerializationLibrary createDefaultLibrary(ReflectFactory factory, CopyStrategyLibrary copyStrategies) {
TypeSerializationLibrary serializationLibrary = new TypeSerializationLibrary(factory, copyStrategies);
serializationLibrary.add(Color.class, new ColorTypeHandler());
serializationLibrary.add(Quat4f.class, new Quat4fTypeHandler());
serializationLibrary.add(Texture.class, new AssetTypeHandler<>(Texture.class));
serializationLibrary.add(UIElement.class, new AssetTypeHandler<>(UIElement.class));
serializationLibrary.add(Mesh.class, new AssetTypeHandler<>(Mesh.class));
serializationLibrary.add(StaticSound.class, new AssetTypeHandler<>(StaticSound.class));
serializationLibrary.add(StreamingSound.class, new AssetTypeHandler<>(StreamingSound.class));
serializationLibrary.add(Material.class, new AssetTypeHandler<>(Material.class));
serializationLibrary.add(Name.class, new NameTypeHandler());
serializationLibrary.add(SkeletalMesh.class, new AssetTypeHandler<>(SkeletalMesh.class));
serializationLibrary.add(MeshAnimation.class, new AssetTypeHandler<>(MeshAnimation.class));
serializationLibrary.add(TextureRegion.class, new TextureRegionTypeHandler());
serializationLibrary.add(TextureRegionAsset.class, new TextureRegionTypeHandler());
serializationLibrary.add(Vector4f.class, new Vector4fTypeHandler());
serializationLibrary.add(Vector3f.class, new Vector3fTypeHandler());
serializationLibrary.add(Vector2f.class, new Vector2fTypeHandler());
serializationLibrary.add(Vector3i.class, new Vector3iTypeHandler());
serializationLibrary.add(Vector2i.class, new Vector2iTypeHandler());
serializationLibrary.add(Rect2i.class, new Rect2iTypeHandler());
serializationLibrary.add(Rect2f.class, new Rect2fTypeHandler());
serializationLibrary.add(Region3i.class, new Region3iTypeHandler());
serializationLibrary.add(Prefab.class, new PrefabTypeHandler());
serializationLibrary.add(BehaviorTree.class, new AssetTypeHandler<>(BehaviorTree.class));
serializationLibrary.add(IntegerRange.class, new IntegerRangeHandler());
return serializationLibrary;
}
Aggregations