An approach is to use an interface:
interface ICollision
{
object PropertyOfType1{get;}
object PropertyOfType2{get;}
}
and then a generic class that inherits from that interface:
class Collision<type1,type2>:ICollision
{
public type1 PropertyOfType1 {get;set;}
public type2 PropertyOfType2 {get;set;}
object ICollision.PropertyOfType1
{
get{return PropertyOfType1;}
}
object ICollision.PropertyOfType2
{
get{return PropertyOfType2;}
}
}
then you can create your linked list using the interface:
LinkedList<ICollision> collisionList = new LinkedList<ICollision>();
collisionList.AddLast(new Collision<int,int>());
collisionList.AddLast(new Collision<double,double>());