public static object CreateGameObject(GameObjectSave save) { string typename = save.TypeName; Type type = GetModelType(typename); var method = type.GetMethod("CreateGameObject").MakeGenericMethod(type); return method.Invoke(null, new object[] {"dani", save}); // return CreateGameObject<Unit>("some obj"); // CreateGameObject<type>("some obj"); }