public void SaveLoop <T>(T loop) { if (!Loops.ContainsKey(typeof(T))) { Loops[typeof(T)] = new List <object>(); } Loops[typeof(T)].Add(loop); }