#pragma once
#include "Deer/Components.h"

namespace Deer {
	// RELATIONSHIP COMPONENT
	template <class Archive>
	void serialize(Archive& archive, RelationshipComponent& relationship) {
		archive(cereal::make_nvp("parentId", relationship.parent_id));

		archive(cereal::make_size_tag(
		    static_cast<cereal::size_type>(relationship.getChildCount())));
		for (int i = 0; i < relationship.getChildCount(); i++)
			archive(relationship.getChildId(i));
	}
} // namespace Deer