private AbstractScene CreateScene(string sceneName) { SceneTypes.TryGetValue(sceneName, out var typeScene); if (typeScene == null) { return(null); } var scene = (AbstractScene)Activator.CreateInstance(typeScene); return(scene); }