Feel like I'm hoping for an unrealistic expectation, but is it possible to have multiple types in a params without casting to avoid GC?
eg...
public void DoSomething(params object[] objs) { for (int i = 0; i < objs.Length; i++) { if (i % 2 == 0) Debug.Log((int)objs[i]); else Debug.Log((string)objs[i]); } }
public void DoSomething(params object[] objs) { for (int i = 0; i < objs.Length; i++) { if (i % 2 == 0) Debug.Log((int)objs[i]); else Debug.Log((string)objs[i]); } }